diff options
author | Arnd Bergmann <arnd@arndb.de> | 2014-01-02 13:07:50 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2014-01-14 16:12:07 +0100 |
commit | 1a1e0a80ceb766852e8abd5d4c3d9475611a7d85 (patch) | |
tree | 0efe9224215eca736bbf6a06538651eb54b9516f /sound/oss/dmasound/dmasound.h | |
parent | 76439c2ac686c547ca2f53bfe964c100e697ff4a (diff) | |
download | blackbird-op-linux-1a1e0a80ceb766852e8abd5d4c3d9475611a7d85.tar.gz blackbird-op-linux-1a1e0a80ceb766852e8abd5d4c3d9475611a7d85.zip |
sound: oss: dmasound: kill SLEEP() macro to avoid race
The use of interruptible_sleep_on_timeout in the dmasound driver
is questionable and we want to kill off all sleep_on variants.
This replaces the calls with wait_event_interruptible_timeout
where possible, to wait for a particular event instead of blocking
in a racy way. In the sq_write function, the easiest solution is
an open-coded prepare_to_wait loop.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/oss/dmasound/dmasound.h')
-rw-r--r-- | sound/oss/dmasound/dmasound.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/sound/oss/dmasound/dmasound.h b/sound/oss/dmasound/dmasound.h index 1308d8d34186..01019f06fa91 100644 --- a/sound/oss/dmasound/dmasound.h +++ b/sound/oss/dmasound/dmasound.h @@ -239,7 +239,6 @@ struct sound_queue { int busy, syncing, xruns, died; }; -#define SLEEP(queue) interruptible_sleep_on_timeout(&queue, HZ) #define WAKE_UP(queue) (wake_up_interruptible(&queue)) extern struct sound_queue dmasound_write_sq; |