.TH lkinfo "" "" "DDI/DKI Data Structure"
.PC "DDI/DKI structure for a lock"
.B "#include <sys/ksynch.h>"
.PP
Structure
.B lkinfo
describes a lock.
Basic and read/write locks can share a
.BR lkinfo ;
however, a basic lock may not share a
.B lkinfo
with a sleep lock, or vice versa.
A driver allocates this structure on its own.
.PP
The following fields within
.B lkinfo
are available to a driver:
.IP "\fBchar *lk_name\fR" 1.25i
The address of the lock's name.
The driver must initialize this field.
The name should begin with the driver's prefix.
.IP "\fBint lk_flags\fR
Flags.
As of this writing,
the \*(CO implementation of \*(ST recognizes no flags.
.\"the only recognized flag is
.\".BR LK_NOSTATS ,
.\"which, when passed to the routine
.\".BR SLEEP_ALLOC() ,
.\"specifies that statistics are not to be collected for this lock under the
.\"compiler option
.\".BR _MPSTATS .
The driver must initialize this field to zero.
.B LOCK_ALLOC()
or
.BR RW_ALLOC() .
.IP "\fBlong lk_pad[2]\fR"
This field is reserved for future use.
The driver must initialize both array members to zero.
.SH "See Also"
.B
DDI/DKI data structures,
LOCK_ALLOC(),
RW_ALLOC(),
SLEEP_ALLOC()
.R
.SH Notes
The structure
.B lkinfo
is defined as type
.BR lkinfo_t .
