diff options
author | Justus Winter <4winter@informatik.uni-hamburg.de> | 2015-07-18 01:26:22 +0200 |
---|---|---|
committer | Justus Winter <4winter@informatik.uni-hamburg.de> | 2015-08-15 12:43:26 +0200 |
commit | fff012df46942c355a705b91a342923b7680002c (patch) | |
tree | 039b5af20aab520af439ab42f6f2cb387d13b223 /kern/lock.h | |
parent | c2b24d5189dc2e7faac2e7df490298dad79985d8 (diff) |
kern/lock: add lock_taken
* kern/lock.h (lock_taken): New macro.
Diffstat (limited to 'kern/lock.h')
-rw-r--r-- | kern/lock.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/kern/lock.h b/kern/lock.h index 435ee1d..ca7b1db 100644 --- a/kern/lock.h +++ b/kern/lock.h @@ -182,6 +182,7 @@ extern boolean_t lock_try_read_to_write(lock_t); #define lock_read_done(l) lock_done(l) #define lock_write_done(l) lock_done(l) +#define lock_taken(l) ((l)->want_write || (l)->read_count) extern void lock_set_recursive(lock_t); extern void lock_clear_recursive(lock_t); |