No child can compensate his father
The Messenger of Allah (sal Allahu alaihi wa sallam) said: “No child can compensate his father unless he finds him a slave, buys him and sets him free.”
[Ibn Majah - Hadith Sahih]
This Hadith shows the virtue of one buying their father if he is a slave and setting him free whereby the messenger (sal Allahu alaihi wa sallam) mentioned that no child can compensate their father unless he finds him as a slave, buys him and sets him free.
The reason why this is considered to be compensation is because when the slave is freed by a person, it is as though that person brought them into existence because while they were slaves, their benefit was for others (their masters) and not for themselves and they were denied high status.
So just as the person who frees a slave is as though he brought him into existence, it is like the father who is a reason for bringing his child into existence and that is the compensation.
The majority of scholars agree that once a person buys their father, the father is considered free even if the child does not utter his freedom because Islam refuses to have a parent be a slave towards their child and serve them but rather it is the opposite whereby the child is the one that serves his/her parents and this is from the rights and favours which Islam has granted the parents.
And Allah Knows Best!