lkml.org 
[lkml]   [1999]   [Nov]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subject{interruptible_,}sleep_on question
Is it correct that drivers which call {interruptible_,}sleep_on can miss
wakeup events unless they either own the big kernel lock or the
global-cli lock before calling sleep_on()?

Normally, I would use the sequence
* add_wait_queue
* set_current_state(TASK_UNINTERRUPTIBLE)
* check that you must wait, and that someone will wake you up.
* schedule().

If you use sleep_on(), then the sequence is
* check that you must wait, and that someone will wake you up.
* within sleep_on:
add_wait_queue
set_current_state(TASK_UNINTERRUPTIBLE)
schedule().

If this is really a problem, then (AFAICS) the DAC960 driver could lock
up.

--
Manfred

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.124 / U:1.364 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site