Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 98644
b: refs/heads/master
c: ee3ece8
h: refs/heads/master
v: v3
  • Loading branch information
Steven Rostedt authored and Linus Torvalds committed Jul 3, 2008
1 parent 04cb85a commit 7478213
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6beef7eb0c16b5216814148b04838cfa963d2cb4
refs/heads/master: ee3ece830f6db9837f7ac67008f532a8c1e755f4
8 changes: 8 additions & 0 deletions trunk/kernel/hrtimer.c
Original file line number Diff line number Diff line change
Expand Up @@ -1003,10 +1003,18 @@ hrtimer_start(struct hrtimer *timer, ktime_t tim, const enum hrtimer_mode mode)
*/
raise = timer->state == HRTIMER_STATE_PENDING;

/*
* We use preempt_disable to prevent this task from migrating after
* setting up the softirq and raising it. Otherwise, if me migrate
* we will raise the softirq on the wrong CPU.
*/
preempt_disable();

unlock_hrtimer_base(timer, &flags);

if (raise)
hrtimer_raise_softirq();
preempt_enable();

return ret;
}
Expand Down

0 comments on commit 7478213

Please sign in to comment.