Before you upgrade your process, you'd need to update your power supply as (HP branded) 220W would be awful and could barely survive an upgrade let alone let you max out either of the CPU's you've mentioned.
If you're looking at upgrading an OEM branded box you need to go through a few things first.
1. Will your PSU handle an upgrade? At 220W yours will not.
These things are hardly 80+ efficiency tested, so you'd be lucky to get 180W peak out of it, which would barely power your existing box under pressure.
2. Can you upgrade your PSU? (IE: is it the standard ATX size PSU, or is it a proprietary sized power supply. (This is typical usually of the really small HP machines, the bigger desktop sized ones usually do have usual ATX Powersupply connection points.)
3. Are your other components going to bottleneck any upgrade?
Bear in mind that these things are designed for a price point. If you have an entry level box, you're also going to get the likes of onboard graphics, and minimal amount of RAM, so updating the CPU when you're running integrated anyway, or you're on a small (2-4GB) of RAM, you may find that the CPU upgrade doesn't provide you with the power you need.
So with all that it mind..
What do you want to do with your box?
Can we have the HP model number?
Furthermore, as HP motherboards will have locked down bios's so you can't get a spec sheet from the manafacturer, we need a part number to look up.