Sahih Muslim Book 015, Hadith Number 4088.
Chapter : How should the masters treat their slaves and expiation if they show high-handedness.
Abu Mas'ud al-Ansari reported: When I was beating my servant, I heard a voice behind me (saying): Abu Mas'ud, bear in mind Allah has more dominance over you than you have upon him. I turned and (found him) to be Allah's Messenger (may peace be upon him). I said: Allah's Messenger, I set him free for the sake of Allah. Thereupon he said: Had you not done that, (the gates of) Hell would have opened for you, or the fire would have burnt you.