Move user switch code into a separate module

* Move user switch code from main.c into a separate module (usrsw)
* Add usrsw.c to Makefile