Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1588250
| From | Geliang Tang <geliangtang@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] workqueue: use setup_deferrable_timer |
| Date | 2017-02-26 02:00 +0100 |
| Message-ID | <teVlT-7sy-3@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Use setup_deferrable_timer() instead of init_timer_deferrable() to simplify the code. Signed-off-by: Geliang Tang <geliangtang@gmail.com> --- kernel/workqueue.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/kernel/workqueue.c b/kernel/workqueue.c index 072cbc9..54a8fff 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -3208,9 +3208,8 @@ static int init_worker_pool(struct worker_pool *pool) INIT_LIST_HEAD(&pool->idle_list); hash_init(pool->busy_hash); - init_timer_deferrable(&pool->idle_timer); - pool->idle_timer.function = idle_worker_timeout; - pool->idle_timer.data = (unsigned long)pool; + setup_deferrable_timer(&pool->idle_timer, idle_worker_timeout, + (unsigned long)pool); setup_timer(&pool->mayday_timer, pool_mayday_timeout, (unsigned long)pool); -- 2.9.3
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] workqueue: use setup_deferrable_timer Geliang Tang <geliangtang@gmail.com> - 2017-02-26 02:00 +0100 [PATCH] writeback: use setup_deferrable_timer Geliang Tang <geliangtang@gmail.com> - 2017-02-26 02:00 +0100
csiph-web