kernel - Fix devfs bitmap races for pty and other devices
* Use an internal lock to protect the integrity of bitmap
operations for devfs_clone_bitmap_*() functions, allowing
devices to use the functions without having to lock themselves.
* Devices which use devfs_clone_bitmap_chk() + devfs_clone_bitmap_set()
sequences have to be more careful, either having their own covering
lock or checking the return code from devfs_clone_bitmap_set() and
looping.
* This fixes serious /dev/ptmx pty allocation races which become obvious
when pty's are allocated concurrently at a high rate, such as by the
dsynth code.
UnifiedSplitRaw