[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1437669735-8786-11-git-send-email-fweisbec@gmail.com>
Date: Thu, 23 Jul 2015 18:42:15 +0200
From: Frederic Weisbecker <fweisbec@...il.com>
To: LKML <linux-kernel@...r.kernel.org>
Cc: Frederic Weisbecker <fweisbec@...il.com>,
Peter Zijlstra <peterz@...radead.org>,
Thomas Gleixner <tglx@...utronix.de>,
Preeti U Murthy <preeti@...ux.vnet.ibm.com>,
Christoph Lameter <cl@...ux.com>,
Ingo Molnar <mingo@...nel.org>,
Viresh Kumar <viresh.kumar@...aro.org>,
Rik van Riel <riel@...hat.com>
Subject: [PATCH 10/10] nohz: Remove task switch obsolete tick dependency check
The task switch check was there to evaluate task level tick dependencies.
Now all of them have been converted to the new CPU or system wide tick
dependency masks that are toggled by the concerned subsystems. We can
safely remove it.
Cc: Christoph Lameter <cl@...ux.com>
Cc: Ingo Molnar <mingo@...nel.org>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Preeti U Murthy <preeti@...ux.vnet.ibm.com>
Cc: Rik van Riel <riel@...hat.com>
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: Viresh Kumar <viresh.kumar@...aro.org>
Signed-off-by: Frederic Weisbecker <fweisbec@...il.com>
---
include/linux/tick.h | 8 --------
kernel/sched/core.c | 2 +-
kernel/time/tick-sched.c | 23 -----------------------
3 files changed, 1 insertion(+), 32 deletions(-)
diff --git a/include/linux/tick.h b/include/linux/tick.h
index daafcce..609f769 100644
--- a/include/linux/tick.h
+++ b/include/linux/tick.h
@@ -170,7 +170,6 @@ extern void tick_nohz_clear_tick_dependency_this_cpu(enum tick_dependency_bit bi
extern void tick_nohz_full_kick(void);
extern void tick_nohz_full_kick_cpu(int cpu);
extern void tick_nohz_full_kick_all(void);
-extern void __tick_nohz_task_switch(void);
#else
static inline bool tick_nohz_full_enabled(void) { return false; }
static inline bool tick_nohz_full_cpu(int cpu) { return false; }
@@ -178,7 +177,6 @@ static inline void tick_nohz_full_add_cpus_to(struct cpumask *mask) { }
static inline void tick_nohz_full_kick_cpu(int cpu) { }
static inline void tick_nohz_full_kick(void) { }
static inline void tick_nohz_full_kick_all(void) { }
-static inline void __tick_nohz_task_switch(void) { }
#endif
static inline const struct cpumask *housekeeping_cpumask(void)
@@ -208,10 +206,4 @@ static inline void housekeeping_affine(struct task_struct *t)
#endif
}
-static inline void tick_nohz_task_switch(void)
-{
- if (tick_nohz_full_enabled())
- __tick_nohz_task_switch();
-}
-
#endif
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 6c3db36..eb926bb 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -2491,7 +2491,7 @@ static struct rq *finish_task_switch(struct task_struct *prev)
}
sched_update_tick_dependency(rq);
- tick_nohz_task_switch();
+
return rq;
}
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c
index 7b74b93..f7391a6 100644
--- a/kernel/time/tick-sched.c
+++ b/kernel/time/tick-sched.c
@@ -353,29 +353,6 @@ void tick_nohz_clear_tick_dependency_this_cpu(enum tick_dependency_bit bit)
__tick_nohz_clear_tick_dependency(bit, &ts->tick_dependency);
}
-/*
- * Re-evaluate the need for the tick as we switch the current task.
- * It might need the tick due to per task/process properties:
- * perf events, posix cpu timers, ...
- */
-void __tick_nohz_task_switch(void)
-{
- unsigned long flags;
- struct tick_sched *ts;
-
- local_irq_save(flags);
-
- if (!tick_nohz_full_cpu(smp_processor_id()))
- goto out;
-
- ts = this_cpu_ptr(&tick_cpu_sched);
-
- if (ts->tick_stopped && !can_stop_full_tick(ts))
- tick_nohz_full_kick();
-out:
- local_irq_restore(flags);
-}
-
/* Parse the boot-time nohz CPU list from the kernel parameters. */
static int __init tick_nohz_full_setup(char *str)
{
--
2.1.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists