Specifications

Data Structures
1.18 Spinlock Data Structure (SPL)
Table 1–20 Contents of the Spinlock Data Structure
Field Contents
SPL$B_SPINLOCK* The following fields are defined within SPL$B_SPINLOCK:
SPL$V_INTERLOCK Spinlock access interlock. When set, this bit
signifies that the spinlock is owned.
<7:1> Reserved to Digital.
SPL$B_IPL* IPL required for spinlock acquisition.
SPL$B_RANK* Spinlock rank. Note that the internal value of a spinlock’s rank, as stored
in this field, is the inverse of the spin lock’s logical rank, as displayed by the
System Dump Analyzer. For instance, the spinlock structure with a logical
rank of 0 contains the value 31 in this field.
SPL$B_VEC_INX* Index of the next entry to be written in the spinlock PC vector index
(SPL$L_OWN_PCVEC). SPL$B_VEC_INX is updated upon each successful
acquisition or release of the spinlock.
SPL$W_OWN_CNT* Ownership count. This field is –1 if the spinlock is unowned, zero or positive
if owned. When a processor initially acquires a spinlock, this field goes from
–1 to zero. A positive ownership count signifies concurrent acquisitions by a
single processor.
SPL$W_WAIT_CPUS* Number of processors waiting to obtain the spinlock.
SPL$W_SIZE* Size of spinlock data structure (SPL$C_LENGTH).
SPL$B_TYPE* Type of data structure. The operating system writes the value DYN$C_SPL
in this field when it creates the SPL data structure.
SPL$B_SUBTYPE* Spinlock subtype. This field can contain the following values:
SPL$C_SPL_SPINLOCK Static system spinlock
SPL$C_SPL_FORKLOCK Fork lock
SPL$C_SPL_DEVICELOCK Device lock (dynamic spinlock)
SPL$L_OWN_CPU* Address of the per-CPU data structure of the processor that has acquired
the spinlock. The field is cleared when a processor releases its last nested
acquisition of the lock.
SPL$L_OWN_PC_VEC* Last eight calling PCs of acquirers and releasers of the spinlock. SPL$B_
VEC_INX serves as the index of the next vector to be written in this array.
SPL$L_WAIT_PC* Last busy-wait PC.
SPL$Q_ACQ_COUNT* Count of successful acquisitions.
SPL$L_BUSY_WAITS* Count of failed acquisitions.
SPL$Q_SPINS* Count of number of spins.
SPL$L_TIMO_INT* Timeout interval before a spinlock acquisition attempt fails.
SPL$L_RLS_PC* PC of the last unconditional release of a set of nested acquisitions of the
spinlock.
1–82