Lock abstraction, init ordering fixes, WM cursor
* Add lock.h with generic lock()/unlock() helpers, replace all
open-coded spinloops in ws, scheduler, exec, pty, tty, input,
keyboard, mouse, and syscall
* Fix destroy_thread and user_exec to free regions before
destroying the vm_space, fixing use-after-free on exec
* Separate subsystem state init from devfs registration in ws,
tty, and input; register_devfs now checks ready instead of
calling init itself
* Add wm_cursor.c/wm_file.c: load cursor from /etc/cursor.ppm
and replace the hardcoded 5x5 white square