diff options
| author | manuel <manuel@mausz.at> | 2012-05-07 18:01:20 +0200 |
|---|---|---|
| committer | manuel <manuel@mausz.at> | 2012-05-07 18:01:20 +0200 |
| commit | 158ea87fba909161a084c29feff29a168725fe4e (patch) | |
| tree | ce580f0fec9f4d5105e817ae11fded8015817574 /threads/synch.h | |
| parent | 3d1e18466b44b2de06dd7c00a85e78ed9340906d (diff) | |
| download | progos-158ea87fba909161a084c29feff29a168725fe4e.tar.gz progos-158ea87fba909161a084c29feff29a168725fe4e.tar.bz2 progos-158ea87fba909161a084c29feff29a168725fe4e.zip | |
first priority donation implementation
Diffstat (limited to 'threads/synch.h')
| -rw-r--r-- | threads/synch.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/threads/synch.h b/threads/synch.h index a19e88b..cdf415c 100644 --- a/threads/synch.h +++ b/threads/synch.h | |||
| @@ -22,6 +22,8 @@ struct lock | |||
| 22 | { | 22 | { |
| 23 | struct thread *holder; /* Thread holding lock (for debugging). */ | 23 | struct thread *holder; /* Thread holding lock (for debugging). */ |
| 24 | struct semaphore semaphore; /* Binary semaphore controlling access. */ | 24 | struct semaphore semaphore; /* Binary semaphore controlling access. */ |
| 25 | int priority; /* the priority of the thread with the highest priority currently acquiring the lock */ | ||
| 26 | struct list_elem elem; /* list element for (struct thread)->locks */ | ||
| 25 | }; | 27 | }; |
| 26 | 28 | ||
| 27 | void lock_init (struct lock *); | 29 | void lock_init (struct lock *); |
