diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2010-09-07 10:32:43 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-10-22 13:21:31 -0400 |
commit | 5014b5e33a5485ab669ce536078c957ec221ade3 (patch) | |
tree | f66b407711bdd09e85cfd3bc052324d28b97106b /drivers/usb/misc/ftdi-elan.c | |
parent | a1df4e45c81ec9ae6b537f845db48b82ab40ac4f (diff) |
usb: ftdi-elan: Convert "mutex" to semaphore
The "mutex" ftdi->sw_lock is used as a lock and a completion. Convert
it to a real semaphore which allows both.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/misc/ftdi-elan.c')
-rw-r--r-- | drivers/usb/misc/ftdi-elan.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/misc/ftdi-elan.c b/drivers/usb/misc/ftdi-elan.c index aecf380f6ecc..c8eec9c2d89e 100644 --- a/drivers/usb/misc/ftdi-elan.c +++ b/drivers/usb/misc/ftdi-elan.c | |||
@@ -2769,7 +2769,7 @@ static int ftdi_elan_probe(struct usb_interface *interface, | |||
2769 | ftdi->sequence_num = ++ftdi_instances; | 2769 | ftdi->sequence_num = ++ftdi_instances; |
2770 | mutex_unlock(&ftdi_module_lock); | 2770 | mutex_unlock(&ftdi_module_lock); |
2771 | ftdi_elan_init_kref(ftdi); | 2771 | ftdi_elan_init_kref(ftdi); |
2772 | init_MUTEX(&ftdi->sw_lock); | 2772 | sema_init(&ftdi->sw_lock, 1); |
2773 | ftdi->udev = usb_get_dev(interface_to_usbdev(interface)); | 2773 | ftdi->udev = usb_get_dev(interface_to_usbdev(interface)); |
2774 | ftdi->interface = interface; | 2774 | ftdi->interface = interface; |
2775 | mutex_init(&ftdi->u132_lock); | 2775 | mutex_init(&ftdi->u132_lock); |