Commit e5de3dfc authored by Kulikov Vasiliy's avatar Kulikov Vasiliy Committed by Takashi Iwai

sound: oss: waveartist: simplify waveartist_sleep()

waveartist_sleep() uses loop with schedule_timeout() to unconditionally
wait for msec. Use schedule_timeout_uninteruptible() instead.
Signed-off-by: default avatarKulikov Vasiliy <segooon@gmail.com>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 2232e238
......@@ -184,14 +184,8 @@ waveartist_iack(wavnc_info *devc)
static inline int
waveartist_sleep(int timeout_ms)
{
unsigned int timeout = timeout_ms * 10 * HZ / 100;
do {
set_current_state(TASK_INTERRUPTIBLE);
timeout = schedule_timeout(timeout);
} while (timeout);
return 0;
unsigned int timeout = msecs_to_jiffies(timeout_ms*100);
return schedule_timeout_interruptible(timeout);
}
static int
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment