Sayyiduna Abdullah bin Abbas (may Allah be pleased with them both) says that on the day of al-Ta'if the Messenger of Allah (peace and blessings be upon him) set free all the slaves of the polytheists who came to him.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الجزية / 18840