lockmgr: unlock interlock (if requested) when dealing with upgrade/downgrade

requests for LK_NOSHARE locks, just like for shared locks.

PR:		kern/174969
Reviewed by:	attilio
MFC after:	1 week
This commit is contained in:
mjg 2013-01-06 21:47:59 +00:00
parent dd684091d3
commit 10b2623aac

View File

@ -498,6 +498,8 @@ __lockmgr_args(struct lock *lk, u_int flags, struct lock_object *ilk,
case LK_DOWNGRADE:
_lockmgr_assert(lk, KA_XLOCKED | KA_NOTRECURSED,
file, line);
if (flags & LK_INTERLOCK)
class->lc_unlock(ilk);
return (0);
}
}