Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1574699 > unrolled thread
| Started by | Ingo Molnar <mingo@kernel.org> |
|---|---|
| First post | 2017-02-06 14:40 +0100 |
| Last post | 2017-02-06 14:40 +0100 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 59/89] sched/core: Move the get_preempt_disable_ip() inline to sched/core.c Ingo Molnar <mingo@kernel.org> - 2017-02-06 14:40 +0100
| From | Ingo Molnar <mingo@kernel.org> |
|---|---|
| Date | 2017-02-06 14:40 +0100 |
| Subject | [PATCH 59/89] sched/core: Move the get_preempt_disable_ip() inline to sched/core.c |
| Message-ID | <t7RGr-5x6-51@gated-at.bofh.it> |
It's defined in <linux/sched.h>, but nothing outside the scheduler
uses it - so move it to the sched/core.c usage site.
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
include/linux/sched.h | 9 ---------
kernel/sched/core.c | 9 +++++++++
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/include/linux/sched.h b/include/linux/sched.h
index eed8d9148b23..c53bb89bfef7 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -1623,15 +1623,6 @@ static inline void cond_resched_rcu(void)
#endif
}
-static inline unsigned long get_preempt_disable_ip(struct task_struct *p)
-{
-#ifdef CONFIG_DEBUG_PREEMPT
- return p->preempt_disable_ip;
-#else
- return 0;
-#endif
-}
-
/*
* Does a critical section need to be broken due to another
* task waiting?: (technically does not depend on CONFIG_PREEMPT,
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index e37d2097dd87..bf2448b4dd98 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -3212,6 +3212,15 @@ static inline void preempt_latency_start(int val) { }
static inline void preempt_latency_stop(int val) { }
#endif
+static inline unsigned long get_preempt_disable_ip(struct task_struct *p)
+{
+#ifdef CONFIG_DEBUG_PREEMPT
+ return p->preempt_disable_ip;
+#else
+ return 0;
+#endif
+}
+
/*
* Print scheduling while atomic bug:
*/
--
2.7.4
Back to top | Article view | linux.kernel
csiph-web