If you repeatedly get an error while upgrading your iPhone’s firmware that says something like:
the iphone could not be restored an unkown error occured 1604
Try restarting iTunes and plugging the iPhone into a different USB port. Failing that you might need to try restoring the phone on another machine before syncing your settings from the original machine.