To put the iPhone into recovery mode so you can do an iTunes firmware restore follow these steps.
UPDATE:
Apple has introduced a new method to entering Recovery Mode. You can find instructions and a video demonstrating the new method here.
Step One
Open iTunes and connect the iPhone to your Mac.
Step Two
Press and hold the Home button and the Sleep/Wake button at the same time.
Step Three
As soon as the screen goes black release the Sleep/Wake button. Continue holding the home button until you iTunes pops up a message telling you that it has detected an iPhone in recovery mode.
The iPhone will look like this:
UPDATE:
Apple has introduced a new method to entering Recovery Mode. You can find instructions and a video demonstrating the new method here.
Step One
Open iTunes and connect the iPhone to your Mac.
Step Two
Press and hold the Home button and the Sleep/Wake button at the same time.
Step Three
As soon as the screen goes black release the Sleep/Wake button. Continue holding the home button until you iTunes pops up a message telling you that it has detected an iPhone in recovery mode.
The iPhone will look like this: