]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
sched/core: Move the get_preempt_disable_ip() inline to sched/core.c
authorIngo Molnar <mingo@kernel.org>
Fri, 3 Feb 2017 22:37:48 +0000 (23:37 +0100)
committerIngo Molnar <mingo@kernel.org>
Thu, 2 Mar 2017 07:42:23 +0000 (08:42 +0100)
It's defined in <linux/sched.h>, but nothing outside the scheduler
uses it - so move it to the sched/core.c usage site.

Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
include/linux/sched.h
kernel/sched/core.c

index c204613396cd3cb53b06b0a3e897ab7ae8a1e215..df42cac04243f22c03e897b62ca80c7e3ffac66e 100644 (file)
@@ -3419,15 +3419,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,
index 7d76ccb79e91e462532c86b21302d90574ef6762..2acdf19c5f7c2a91665640d0c08e13834da1eddd 100644 (file)
@@ -3211,6 +3211,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:
  */