-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sound: oss: remove last sleep_on users
There are three files in oss for which I could not find an easy way to replace interruptible_sleep_on_timeout with a non-racy version. This patch instead just adds a private implementation of the function, now named oss_broken_sleep_on, and changes over the remaining users in sound/oss/ so we can remove the global interface. [fixed coding style warnings by tiwai] Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
- Loading branch information
Arnd Bergmann
authored and
Takashi Iwai
committed
Jan 14, 2014
1 parent
1a1e0a8
commit cdef2e5
Showing
4 changed files
with
39 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#include <linux/wait.h> | ||
|
||
/* | ||
* Do not use. This is a replacement for the old | ||
* "interruptible_sleep_on_timeout" function that has been | ||
* deprecated for ages. All users should instead try to use | ||
* wait_event_interruptible_timeout. | ||
*/ | ||
|
||
static inline long | ||
oss_broken_sleep_on(wait_queue_head_t *q, long timeout) | ||
{ | ||
DEFINE_WAIT(wait); | ||
prepare_to_wait(q, &wait, TASK_INTERRUPTIBLE); | ||
timeout = schedule_timeout(timeout); | ||
finish_wait(q, &wait); | ||
return timeout; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters