What would be the motivation for an arahant to perform generous deeds? In the early stages of the gradual training, the instructions point out to perform generous deeds out of compassion. Knowing that a arahant has no more any trace of desire or self-identification and that compassion is a desire to other beings be happy, what would be the motivation underliyng generous deeds performed by a arahant?
"Compassion is characterized as promoting the aspect of allaying suffering. Its function resides in not [enduring] others' suffering. It is manifested as non-cruelty. Its proximate cause is to see helplessness in those overwhelmed by suffering. It succeeds when it makes cruelty subside, and it fails when it produces sorrow." -Visuddhimagga

Compassion is a wholesome quality of the mind. It's not eliminated when one attains enlightenment. So when an Arahath's mind focuses on the suffering of a being, compassion arises naturally.

Craving is what is eleminated when one attains enlightenment. Craving is of 3 kinds.


Desire for sensual pleasure
Desire for becoming
Desire for non-becoming