Call exit_thread automatically when a thread returns

Also, tidied up thread switching with ldm/stm and made it pass the
thread's user data argument through to the thread.
Fixed HYPERVISOR_shutdown

Don't know what "low_shutdown" was supposed to do, but it doesn't exist.
Merge pull request #3 from talex5/next

Some threading cleanups for Mini-OS/ARM