xv6-riscv-kernel/kernel/sleeplock.h
2019-06-11 09:57:14 -04:00

10 lines
265 B
C

// Long-term locks for processes
struct sleeplock {
uint locked; // Is the lock held?
struct spinlock lk; // spinlock protecting this sleep lock
// For debugging:
char *name; // Name of lock.
int pid; // Process holding lock
};