heating problem - L7805C [duplicate]

I'm using a L7805C voltage regulator , to power an SMPS circuit. But its getting heated after 10 min or so , even if I've put a heat sync.

SMPS IC is used to convert +5V to -9V.

• What current is being taken by the SMPS? What dc voltage is fed to the 7805 input? Apr 23, 2015 at 10:12
• Voltage input to the Voltage regulator - 12V (two wheeler battery). Voltage input to SMPS - 5.08V Apr 23, 2015 at 10:14
• Current to SMPS is required. Clearly the voltage will be 5V because it's a 5V regulator. Apr 23, 2015 at 10:15
• Why are you powering a switchmode with a linear regulator? Apr 23, 2015 at 10:31
• I used to power it the same way earlier, without any problems. Apr 23, 2015 at 11:06

Power dissipated by 7805 = $(V_{IN} - 5V)\times I_{OUT}$