Fixes vmm_struct_cleanup
Cleanup is called from __proc_free, and I don't want to sleep in there.
Running the existing code with the lock debugger will flip out. Even
attempting to qlock while holding a spinlock will panic, rightly so.
The lock held happens to be the parent's child lock, which it holds when
it decrefs the child. Regardless, proc_decref is called all over the
place, and I'd rather not sleep in the release method.
I considered removing the qlock and having a multi-state atomic_t that
we CAS on, solving the issue of multiple potential initializers and
cleanup not checking the lock. But that's a bit of overkill.
3 files changed