diff options
author | Arjan van de Ven <arjan@infradead.org> | 2006-01-12 13:42:23 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2006-01-12 13:42:23 -0500 |
commit | 00431707be0cc1236ee08459367872b57da5be29 (patch) | |
tree | 0a57cbf54f1fcc9ef2852e68e96c3b99e1b903d8 /arch/arm/kernel/ecard.c | |
parent | f4619025a51747a3788fd1bb6bdc46e368a889a7 (diff) |
[ARM] Convert some arm semaphores to mutexes
The arm clock semaphores are strict mutexes, convert them to the new
mutex implementation
Signed-off-by: Arjan van de Ven <arjan@infradead.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/kernel/ecard.c')
-rw-r--r-- | arch/arm/kernel/ecard.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/arm/kernel/ecard.c b/arch/arm/kernel/ecard.c index dceb826bd216..96fd91926c9b 100644 --- a/arch/arm/kernel/ecard.c +++ b/arch/arm/kernel/ecard.c | |||
@@ -40,6 +40,7 @@ | |||
40 | #include <linux/proc_fs.h> | 40 | #include <linux/proc_fs.h> |
41 | #include <linux/device.h> | 41 | #include <linux/device.h> |
42 | #include <linux/init.h> | 42 | #include <linux/init.h> |
43 | #include <linux/mutex.h> | ||
43 | 44 | ||
44 | #include <asm/dma.h> | 45 | #include <asm/dma.h> |
45 | #include <asm/ecard.h> | 46 | #include <asm/ecard.h> |
@@ -206,7 +207,7 @@ static void ecard_task_readbytes(struct ecard_request *req) | |||
206 | 207 | ||
207 | static DECLARE_WAIT_QUEUE_HEAD(ecard_wait); | 208 | static DECLARE_WAIT_QUEUE_HEAD(ecard_wait); |
208 | static struct ecard_request *ecard_req; | 209 | static struct ecard_request *ecard_req; |
209 | static DECLARE_MUTEX(ecard_sem); | 210 | static DEFINE_MUTEX(ecard_mutex); |
210 | 211 | ||
211 | /* | 212 | /* |
212 | * Set up the expansion card daemon's page tables. | 213 | * Set up the expansion card daemon's page tables. |
@@ -299,7 +300,7 @@ static void ecard_call(struct ecard_request *req) | |||
299 | 300 | ||
300 | req->complete = &completion; | 301 | req->complete = &completion; |
301 | 302 | ||
302 | down(&ecard_sem); | 303 | mutex_lock(&ecard_mutex); |
303 | ecard_req = req; | 304 | ecard_req = req; |
304 | wake_up(&ecard_wait); | 305 | wake_up(&ecard_wait); |
305 | 306 | ||
@@ -307,7 +308,7 @@ static void ecard_call(struct ecard_request *req) | |||
307 | * Now wait for kecardd to run. | 308 | * Now wait for kecardd to run. |
308 | */ | 309 | */ |
309 | wait_for_completion(&completion); | 310 | wait_for_completion(&completion); |
310 | up(&ecard_sem); | 311 | mutex_unlock(&ecard_mutex); |
311 | } | 312 | } |
312 | 313 | ||
313 | /* ======================= Mid-level card control ===================== */ | 314 | /* ======================= Mid-level card control ===================== */ |