- Include LK_INTERLOCK in LK_EXTFLG_MASK so that it makes its way into

acquire.
 - Correct the condition that causes us to skip apause() to only require
   the presence of LK_INTERLOCK.

Sponsored by:	Isilon Systems, Inc.
This commit is contained in:
Jeff Roberson 2005-01-25 16:06:05 +00:00
parent b58e7b4cc5
commit 04186764a4
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=140824
2 changed files with 2 additions and 2 deletions

View File

@ -148,7 +148,7 @@ acquire(struct lock **lkpp, int extflags, int wanted)
return EBUSY;
}
if (((lkp->lk_flags | extflags) & (LK_NOPAUSE|LK_INTERLOCK)) == 0) {
if ((extflags & LK_INTERLOCK) == 0) {
error = apause(lkp, wanted);
if (error == 0)
return 0;

View File

@ -117,7 +117,7 @@ struct lock {
* or passed in as arguments to the lock manager. The LK_REENABLE flag may be
* set only at the release of a lock obtained by drain.
*/
#define LK_EXTFLG_MASK 0x03000070 /* mask of external flags */
#define LK_EXTFLG_MASK 0x03010070 /* mask of external flags */
#define LK_NOWAIT 0x00000010 /* do not sleep to await lock */
#define LK_SLEEPFAIL 0x00000020 /* sleep, then return failure */
#define LK_CANRECURSE 0x00000040 /* allow recursive exclusive lock */