Adding a few things to what vuzedome said.
If you can actually get your computer to show anything, your CPU is fine. If it overheats, yes, it'll shut off (well, most will). You said you get stuck on the XP loading screen. In that case, there's probably something wrong with your installation, not with the hardware, especially if it did work in the past and you haven't changed any of the hardware. And note there's a difference between turning a computer on and booting into your OS.
If there's a fan or two not working, you should replace it/them. If it's the CPU fan that's not working, you better do it ASAP.
Note there are other chips on the board that can get hot too if they aren't cooled properly. This can also cause auto-shutdown. Try feeling the heatsinks on your board right after an auto-shutdown. If you reflexively jerk your hand back because it's too hot, that chip is probably your problem.
And finally, what you have is a cable modem + router combo.