diff options
author | Tilman Schmidt <tilman@imap.cc> | 2006-04-10 22:55:12 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-04-11 06:18:50 -0700 |
commit | abfd1dc7c18e4be89715071a524324c7b2515565 (patch) | |
tree | 84109f661246b66b2a7503164ec41e4382e37812 /drivers/isdn/gigaset/proc.c | |
parent | 01371500b245ae63f542d74140a3d8ccb74d0318 (diff) | |
download | blackbird-op-linux-abfd1dc7c18e4be89715071a524324c7b2515565.tar.gz blackbird-op-linux-abfd1dc7c18e4be89715071a524324c7b2515565.zip |
[PATCH] isdn4linux: Siemens Gigaset drivers: mutex conversion
With Hansjoerg Lipp <hjlipp@web.de>
Convert the semaphores used by the Gigaset drivers to mutexes.
Signed-off-by: Hansjoerg Lipp <hjlipp@web.de>
Signed-off-by: Tilman Schmidt <tilman@imap.cc>
Cc: Karsten Keil <kkeil@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/isdn/gigaset/proc.c')
-rw-r--r-- | drivers/isdn/gigaset/proc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/isdn/gigaset/proc.c b/drivers/isdn/gigaset/proc.c index 912fed670742..8f124e8e604b 100644 --- a/drivers/isdn/gigaset/proc.c +++ b/drivers/isdn/gigaset/proc.c @@ -37,14 +37,14 @@ static ssize_t set_cidmode(struct device *dev, struct device_attribute *attr, if (value < 0 || value > 1) return -EINVAL; - if (down_interruptible(&cs->sem)) + if (mutex_lock_interruptible(&cs->mutex)) return -ERESTARTSYS; // FIXME -EINTR? cs->waiting = 1; if (!gigaset_add_event(cs, &cs->at_state, EV_PROC_CIDMODE, NULL, value, NULL)) { cs->waiting = 0; - up(&cs->sem); + mutex_unlock(&cs->mutex); return -ENOMEM; } @@ -53,7 +53,7 @@ static ssize_t set_cidmode(struct device *dev, struct device_attribute *attr, wait_event(cs->waitqueue, !cs->waiting); - up(&cs->sem); + mutex_unlock(&cs->mutex); return count; } |