diff options
author | Ingo Molnar <mingo@elte.hu> | 2009-07-03 08:29:34 -0500 |
---|---|---|
committer | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2018-08-07 16:20:18 +0200 |
commit | d68a9def89d23a885a7551fd4ab2698f40f3e2ed (patch) | |
tree | c1c2e2ecf5fe9309a9efefaf4458793ad5312d9b /fs | |
parent | 57e08943ff176d235b5767c092f326cc6e13d8fa (diff) | |
download | linux-rt-d68a9def89d23a885a7551fd4ab2698f40f3e2ed.tar.gz |
hrtimers: Prepare full preemption
Make cancellation of a running callback in softirq context safe
against preemption.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/timerfd.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/timerfd.c b/fs/timerfd.c index cdad49da3ff7..1b304f2f1d08 100644 --- a/fs/timerfd.c +++ b/fs/timerfd.c @@ -471,7 +471,10 @@ static int do_timerfd_settime(int ufd, int flags, break; } spin_unlock_irq(&ctx->wqh.lock); - cpu_relax(); + if (isalarm(ctx)) + hrtimer_wait_for_timer(&ctx->t.alarm.timer); + else + hrtimer_wait_for_timer(&ctx->t.tmr); } /* |