mirror of
https://github.com/SmallPond/MIT6.828_OS.git
synced 2026-04-26 11:49:51 +08:00
11 lines
265 B
C
11 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
|
|
};
|
|
|