Set pins back to original functions on cleanup

Like a typical SOC, BCM2835 has multiple possible functions for each
GPIO pin, selectable via "GPIO Function Select N" registers
(equivalent of "pinmux" registers on other processors).

Until now, RPi.GPIO was happy to take control of a pin away
from an SOC peripheral by changing the function select field
if needed. As long as warnings were not disabled, it would
display a relevant warning,
"This channel is already in use, continuing anyway."
but failed to ever change the function select back.

Now the original function for a pin will be remembered,
so that cleanup() can put the pin back to original function
rather than pretending that all pins were GPIO inputs.

This new cleanup() policy should be useful for certain evil hacks,
for instance talking to a sensor stick
http://embeddedday.com/projects/sensor-stick/
which has both I2C devices and an SHT10 connected to the same pins.
As long as nothing tries to do I2C while raw GPIO is being done for the
SHT10, the normal I2C driver should be none the wiser and continue to work.
(Prior to this change, I2C controller did not manage to do much useful
after SH10 code stole its pins and *kept* them).