linux-4.4.1/poll_schedule_timeout()
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
検索
|
最終更新
|
ヘルプ
|
ログイン
]
開始行:
*参照元 [#e79c5ecb]
#backlinks
*説明 [#e11d9040]
-パス: [[linux-4.4.1/fs/select.c]]
-FIXME: これは何?
--説明
**引数 [#ac14862f]
-struct poll_wqueues *pwq
--
--[[linux-4.4.1/poll_wqueues]]
-int state
--
-ktime_t *expires
--
--[[linux-4.4.1/ktime_t]]
-unsigned long slack
--
**返り値 [#ee448218]
-int
--
**参考 [#i606a6a7]
*実装 [#u75a85c0]
int poll_schedule_timeout(struct poll_wqueues *pwq, int ...
ktime_t *expires, unsigned long slack)
{
int rc = -EINTR;
set_current_state(state);
if (!pwq->triggered)
rc = schedule_hrtimeout_range(expires, slack, HRTIMER_...
__set_current_state(TASK_RUNNING);
-
--[[linux-4.4.1/set_current_state()]]
--[[linux-4.4.1/schedule_hrtimeout_range()]]
--[[linux-4.4.1/__set_current_state()]]
/*
* Prepare for the next iteration.
*
* The following smp_store_mb() serves two purposes. F...
* the counterpart rmb of the wmb in pollwake() such th...
* written before wake up is always visible after wake ...
* Second, the full barrier guarantees that triggered c...
* doesn't pass event check of the next iteration. Not...
* this problem doesn't exist for the first iteration as
* add_wait_queue() has full barrier semantics.
*/
smp_store_mb(pwq->triggered, 0);
-
--[[linux-4.4.1/smp_store_mb()]]
return rc;
}
*コメント [#y27be3a4]
終了行:
*参照元 [#e79c5ecb]
#backlinks
*説明 [#e11d9040]
-パス: [[linux-4.4.1/fs/select.c]]
-FIXME: これは何?
--説明
**引数 [#ac14862f]
-struct poll_wqueues *pwq
--
--[[linux-4.4.1/poll_wqueues]]
-int state
--
-ktime_t *expires
--
--[[linux-4.4.1/ktime_t]]
-unsigned long slack
--
**返り値 [#ee448218]
-int
--
**参考 [#i606a6a7]
*実装 [#u75a85c0]
int poll_schedule_timeout(struct poll_wqueues *pwq, int ...
ktime_t *expires, unsigned long slack)
{
int rc = -EINTR;
set_current_state(state);
if (!pwq->triggered)
rc = schedule_hrtimeout_range(expires, slack, HRTIMER_...
__set_current_state(TASK_RUNNING);
-
--[[linux-4.4.1/set_current_state()]]
--[[linux-4.4.1/schedule_hrtimeout_range()]]
--[[linux-4.4.1/__set_current_state()]]
/*
* Prepare for the next iteration.
*
* The following smp_store_mb() serves two purposes. F...
* the counterpart rmb of the wmb in pollwake() such th...
* written before wake up is always visible after wake ...
* Second, the full barrier guarantees that triggered c...
* doesn't pass event check of the next iteration. Not...
* this problem doesn't exist for the first iteration as
* add_wait_queue() has full barrier semantics.
*/
smp_store_mb(pwq->triggered, 0);
-
--[[linux-4.4.1/smp_store_mb()]]
return rc;
}
*コメント [#y27be3a4]
ページ名: