From: Andrew Morton CONFIG_SMP=n: kernel/sched.c:191: warning: 'struct sched_domain' declared inside parameter list kernel/sched.c:191: warning: its scope is only this definition or declaration, which is probably not what you want kernel/sched.c: In function 'task_hot': kernel/sched.c:193: error: dereferencing pointer to incomplete type Cc: Ingo Molnar Signed-off-by: Andrew Morton --- kernel/sched.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff -puN kernel/sched.c~sched-clean-up-fallout-of-recent-changes-fix kernel/sched.c --- a/kernel/sched.c~sched-clean-up-fallout-of-recent-changes-fix +++ a/kernel/sched.c @@ -185,15 +185,6 @@ static inline unsigned int task_timeslic } /* - * Is this task likely cache-hot: - */ -static inline int -task_hot(struct task_struct *p, unsigned long long now, struct sched_domain *sd) -{ - return (long long)(now - p->last_ran) < (long long)sd->cache_hot_time; -} - -/* * These are the runqueue data structures: */ @@ -1893,6 +1884,15 @@ unsigned long nr_active(void) #ifdef CONFIG_SMP /* + * Is this task likely cache-hot: + */ +static inline int +task_hot(struct task_struct *p, unsigned long long now, struct sched_domain *sd) +{ + return (long long)(now - p->last_ran) < (long long)sd->cache_hot_time; +} + +/* * double_rq_lock - safely lock two runqueues * * Note this does not disable interrupts like task_rq_lock, _