"Messenger of Allah, what do you think if a son is born to me after you, may I name him Muhammad and give him your kunya?"He replied, "Yes."He said, "So it was a special permission granted to me."This is a hasan sahih hadith.
حدثنا محمد بن بشار حدثنا يحيى بن سعيد القطان حدثنا فطر بن خليفة حدثني منذر وهو الثوري عن محمد ابن الحنفية
يا رسول الله أرأيت إن ولد لي بعدك أسميه محمدا وأكنيه بكنيتك قال نعم قال فكانت رخصة لي هذا حديث حسن صحيح
[Its chain of transmission is hasan]. Abu Dawud narrated it in the Book of Manners, chapter on the permission to combine the two, hadith no. 4967, from the hadith of Fitr, with the same chain, and Hakim graded it sahih according to the criteria of the two sheikhs, 4/278, and Dhahabi agreed with him.