diff options
author | Ingo Molnar <mingo@kernel.org> | 2014-06-18 12:47:03 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2014-06-18 12:47:03 -0400 |
commit | d490b3e2c23369c6adfa183d18d9a24ced247797 (patch) | |
tree | 3355c2173228ad1986299c84d22d40ce24764390 /kernel/sched/sched.h | |
parent | ebe06187bf2aec10d537ce4595e416035367d703 (diff) | |
parent | 3882ec643997757824cd5f25180cd8a787b9dbe1 (diff) |
Merge branch 'timers/nohz-irq-work-v7' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks into timers/nohz
Pull nohz updates from Frederic Weisbecker:
" This set moves the nohz kick, used to notify a full dynticks CPU when
events require tick rescheduling, out of the scheduler tick to a
dedicated IPI.
This debloats a bit the scheduler IPI from off-topic work that was
abusing that scheduler fast path for its convenient asynchronous
properties. Now the nohz kick uses irq-work for its own needs.
Of course this implied quite some background infrastructure rework,
including:
* Clean up some irq-work internals
* Implement remote irq-work
* Implement nohz kick on top of remote irq-work
* Move full dynticks timer enqueue notification to new kick
* Move multi-task notification to new kick
* Remove unecessary barriers on multi-task notification
"
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/sched/sched.h')
-rw-r--r-- | kernel/sched/sched.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/kernel/sched/sched.h b/kernel/sched/sched.h index 31cc02ebc54e..eb8567610295 100644 --- a/kernel/sched/sched.h +++ b/kernel/sched/sched.h | |||
@@ -1221,9 +1221,15 @@ static inline void add_nr_running(struct rq *rq, unsigned count) | |||
1221 | #ifdef CONFIG_NO_HZ_FULL | 1221 | #ifdef CONFIG_NO_HZ_FULL |
1222 | if (prev_nr < 2 && rq->nr_running >= 2) { | 1222 | if (prev_nr < 2 && rq->nr_running >= 2) { |
1223 | if (tick_nohz_full_cpu(rq->cpu)) { | 1223 | if (tick_nohz_full_cpu(rq->cpu)) { |
1224 | /* Order rq->nr_running write against the IPI */ | 1224 | /* |
1225 | smp_wmb(); | 1225 | * Tick is needed if more than one task runs on a CPU. |
1226 | smp_send_reschedule(rq->cpu); | 1226 | * Send the target an IPI to kick it out of nohz mode. |
1227 | * | ||
1228 | * We assume that IPI implies full memory barrier and the | ||
1229 | * new value of rq->nr_running is visible on reception | ||
1230 | * from the target. | ||
1231 | */ | ||
1232 | tick_nohz_full_kick_cpu(rq->cpu); | ||
1227 | } | 1233 | } |
1228 | } | 1234 | } |
1229 | #endif | 1235 | #endif |