diff options
author | John M. Calandrino <jmc@jupiter-cs.cs.unc.edu> | 2007-04-23 23:19:19 -0400 |
---|---|---|
committer | John M. Calandrino <jmc@jupiter-cs.cs.unc.edu> | 2007-04-23 23:19:19 -0400 |
commit | 7bf3583ed15c745f295099a0d1ac4b087a2ddcf6 (patch) | |
tree | b1fc1500539d13158b8def4e31a0f20fb6581298 /arch | |
parent | a1e68e80591e11cc6c3404304d2fa13bd515390d (diff) |
Reverted back to spinlocks, added code to higher priority code in
edf-common.c, left other stubs untouched until tomorrow.
Diffstat (limited to 'arch')
-rw-r--r-- | arch/i386/kernel/pi_sem_syscalls.c | 5 | ||||
-rw-r--r-- | arch/i386/kernel/sem_syscalls.c | 5 |
2 files changed, 4 insertions, 6 deletions
diff --git a/arch/i386/kernel/pi_sem_syscalls.c b/arch/i386/kernel/pi_sem_syscalls.c index 04584a12fb..f7a66da110 100644 --- a/arch/i386/kernel/pi_sem_syscalls.c +++ b/arch/i386/kernel/pi_sem_syscalls.c | |||
@@ -8,7 +8,6 @@ | |||
8 | #include <asm/atomic.h> | 8 | #include <asm/atomic.h> |
9 | #include <linux/sched.h> | 9 | #include <linux/sched.h> |
10 | #include <linux/wait.h> | 10 | #include <linux/wait.h> |
11 | #include <linux/queuelock.h> | ||
12 | 11 | ||
13 | #define MAX_PI_SEMAPHORES 256 | 12 | #define MAX_PI_SEMAPHORES 256 |
14 | 13 | ||
@@ -111,14 +110,14 @@ asmlinkage long sys_pi_sema_free(pi_sema_id sem_id) | |||
111 | struct list_head *tmp, *next; | 110 | struct list_head *tmp, *next; |
112 | unsigned long flags; | 111 | unsigned long flags; |
113 | 112 | ||
114 | queue_lock_irqsave(&pi_sems[sem_id].wait.lock, flags); | 113 | spin_lock_irqsave(&pi_sems[sem_id].wait.lock, flags); |
115 | list_for_each_safe(tmp, next, &pi_sems[sem_id].wait.task_list) { | 114 | list_for_each_safe(tmp, next, &pi_sems[sem_id].wait.task_list) { |
116 | wait_queue_t *curr = list_entry(tmp, wait_queue_t, task_list); | 115 | wait_queue_t *curr = list_entry(tmp, wait_queue_t, task_list); |
117 | list_del(tmp); | 116 | list_del(tmp); |
118 | curr->func(curr, TASK_UNINTERRUPTIBLE | TASK_INTERRUPTIBLE, | 117 | curr->func(curr, TASK_UNINTERRUPTIBLE | TASK_INTERRUPTIBLE, |
119 | 0, NULL); | 118 | 0, NULL); |
120 | } | 119 | } |
121 | queue_unlock_irqrestore(&pi_sems[sem_id].wait.lock, flags); | 120 | spin_unlock_irqrestore(&pi_sems[sem_id].wait.lock, flags); |
122 | pi_sems[sem_id].used = 0; | 121 | pi_sems[sem_id].used = 0; |
123 | 122 | ||
124 | return 0; | 123 | return 0; |
diff --git a/arch/i386/kernel/sem_syscalls.c b/arch/i386/kernel/sem_syscalls.c index 03713f41e6..2bdbc5fd96 100644 --- a/arch/i386/kernel/sem_syscalls.c +++ b/arch/i386/kernel/sem_syscalls.c | |||
@@ -6,7 +6,6 @@ | |||
6 | 6 | ||
7 | #include <asm/semaphore.h> | 7 | #include <asm/semaphore.h> |
8 | #include <linux/sched.h> | 8 | #include <linux/sched.h> |
9 | #include <linux/queuelock.h> | ||
10 | 9 | ||
11 | #define MAX_SEMAPHORES 256 | 10 | #define MAX_SEMAPHORES 256 |
12 | 11 | ||
@@ -64,14 +63,14 @@ asmlinkage long sys_sema_free(sema_id sem_id) | |||
64 | struct list_head *tmp, *next; | 63 | struct list_head *tmp, *next; |
65 | unsigned long flags; | 64 | unsigned long flags; |
66 | 65 | ||
67 | queue_lock_irqsave(&sems[sem_id].wait.lock, flags); | 66 | spin_lock_irqsave(&sems[sem_id].wait.lock, flags); |
68 | list_for_each_safe(tmp, next, &sems[sem_id].wait.task_list) { | 67 | list_for_each_safe(tmp, next, &sems[sem_id].wait.task_list) { |
69 | wait_queue_t *curr = list_entry(tmp, wait_queue_t, task_list); | 68 | wait_queue_t *curr = list_entry(tmp, wait_queue_t, task_list); |
70 | list_del(tmp); | 69 | list_del(tmp); |
71 | curr->func(curr, TASK_UNINTERRUPTIBLE | TASK_INTERRUPTIBLE, | 70 | curr->func(curr, TASK_UNINTERRUPTIBLE | TASK_INTERRUPTIBLE, |
72 | 0, NULL); | 71 | 0, NULL); |
73 | } | 72 | } |
74 | queue_unlock_irqrestore(&sems[sem_id].wait.lock, flags); | 73 | spin_unlock_irqrestore(&sems[sem_id].wait.lock, flags); |
75 | sems[sem_id].used = 0; | 74 | sems[sem_id].used = 0; |
76 | 75 | ||
77 | return 0; | 76 | return 0; |