*参照元 [#t551c9a5] #backlinks *説明 [#qe401ffe] -パス: [[linux-2.6.33/kernel/wait.c]] -FIXME: これは何? --説明 **引数 [#e1171186] -wait_queue_head_t *wq --[[linux-2.6.33/wait_queue_head_t]] -struct wait_bit_queue *q --[[linux-2.6.33/wait_bit_queue]] -int (*action)(void *) -- -unsigned mode -- **返り値 [#w5455480] -int -- **参考 [#a186c22e] *実装 [#t2b8d1d0] /* * To allow interruptible waiting and asynchronous (i.e. nonblocking) * waiting, the actions of __wait_on_bit() and __wait_on_bit_lock() are * permitted return codes. Nonzero return codes halt waiting and return. */ int __sched __wait_on_bit(wait_queue_head_t *wq, struct wait_bit_queue *q, int (*action)(void *), unsigned mode) { int ret = 0; do { prepare_to_wait(wq, &q->wait, mode); - --[[linux-2.6.33/prepare_to_wait()]] if (test_bit(q->key.bit_nr, q->key.flags)) ret = (*action)(q->key.flags); - --[[linux-2.6.33/test_bit()]] } while (test_bit(q->key.bit_nr, q->key.flags) && !ret); finish_wait(wq, &q->wait); - --[[linux-2.6.33/finish_wait()]] return ret; } EXPORT_SYMBOL(__wait_on_bit); - -特にライセンスを区別せずにシンボルをエクスポートする。 --[[linux-2.6.33/EXPORT_SYMBOL()]] *コメント [#n70592ed]