Tests whether a complex lock is locked.
#include <sys/lock_def.h>
int lock_islocked ( lock_addr)
complex_lock_t lock_addr;
| Item | Description |
|---|---|
| lock_addr | Specifies the address of the lock word to test. |
The lock_islocked kernel service determines whether the specified complex lock is free, or is locked in either shared-read or exclusive-write mode.
The lock_islocked kernel service can be called from the process environment only.
| Item | Description |
|---|---|
| TRUE | Indicates that the lock was locked. |
| FALSE | Indicates that the lock was free. |