diff options
author | Arnd Bergmann <arnd@arndb.de> | 2014-01-02 13:07:34 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-01-09 10:41:44 -0800 |
commit | 4b266e5fbc715e81c616ea122700475333fd3749 (patch) | |
tree | f357dd78838b690f0da98cfebf4dd0bc1c7c2f53 /drivers/staging | |
parent | d6f5250000f68d8c389b829bf11dd5c9d55c8438 (diff) |
staging: gdm72xx: fix interruptible_sleep_on race
interruptible_sleep_on is racy and going away. This replaces the
use in the gdm72xx driver with the appropriate
wait_event_interruptible_lock_irq.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: devel@driverdev.osuosl.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/gdm72xx/gdm_usb.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/staging/gdm72xx/gdm_usb.c b/drivers/staging/gdm72xx/gdm_usb.c index e0cb2ffb41be..f8788bf0a7d3 100644 --- a/drivers/staging/gdm72xx/gdm_usb.c +++ b/drivers/staging/gdm72xx/gdm_usb.c @@ -780,9 +780,10 @@ static int k_mode_thread(void *arg) spin_lock_irqsave(&k_lock, flags2); } + wait_event_interruptible_lock_irq(k_wait, + !list_empty(&k_list) || k_mode_stop, + k_lock); spin_unlock_irqrestore(&k_lock, flags2); - - interruptible_sleep_on(&k_wait); } return 0; } |