MFC r277649:

vmspace_release() may sleep if the last reference is being released,
   so add a WITNESS_WARN() to catch cases where it is called with a
   non-sleepable lock held.

   MFC after:    1 month
   Sponsored by: Sandvine Inc.
This commit is contained in:
rstone 2015-03-01 04:39:07 +00:00
parent 6d2b81bc2b
commit a206bae4b5

View File

@ -342,6 +342,9 @@ void
vmspace_free(struct vmspace *vm)
{
WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL,
"vmspace_free() called with non-sleepable lock held");
if (vm->vm_refcnt == 0)
panic("vmspace_free: attempt to free already freed vmspace");