Actually, and use this only if a simple hard-reboot (press and hold the power button until the device turns off) won't help you, you can do so from the bootloader (but if you do this, prepare for a few headaches along the way, along with the neccessity of a prepared computer and sending out a few commands, in a similiar vein to, yet much simpler than, computers from thirty years ago).