diff --git a/include/linux/sched.h b/include/linux/sched.h index ee800e7a70de427ae9ce46e34c27ac659d04336b..ac3d496fbd20266ad6ef88848f967eb8a550047a 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -282,6 +282,10 @@ static inline void touch_all_softlockup_watchdogs(void) /* Attach to any functions which should be ignored in wchan output. */ #define __sched __attribute__((__section__(".sched.text"))) + +/* Linker adds these: start and end of __sched functions */ +extern char __sched_text_start[], __sched_text_end[]; + /* Is this address in the __sched functions? */ extern int in_sched_functions(unsigned long addr); diff --git a/kernel/sched.c b/kernel/sched.c index 89cb2dac8bfd2a033106d0a00b948f11793b8dd6..98dcdf272db373c8459a552f1db46687a1600987 100644 --- a/kernel/sched.c +++ b/kernel/sched.c @@ -6708,9 +6708,6 @@ void __init sched_init_smp(void) int in_sched_functions(unsigned long addr) { - /* Linker adds these: start and end of __sched functions */ - extern char __sched_text_start[], __sched_text_end[]; - return in_lock_functions(addr) || (addr >= (unsigned long)__sched_text_start && addr < (unsigned long)__sched_text_end);