Re: [PATCH 1/2 v2] kernel/{sched,smp}.c: fix static decl prior tostruct declaration

From: Ingo Molnar
Date: Mon May 11 2009 - 16:52:40 EST



* Jeff Garzik <jeff@xxxxxxxxxx> wrote:

> Ingo Molnar wrote:
>> -tip testing found this build bug:
>>
>> kernel/sched.c: In function âroot_task_group_emptyâ:
>> kernel/sched.c:312: error: âroot_task_groupâ undeclared (first use in this function)
>> kernel/sched.c:312: error: (Each undeclared identifier is reported only once
>> kernel/sched.c:312: error: for each function it appears in.)
>>
>> config attached.
>
> Fixed and resent.

Thanks.

> What a rat's nest of ifdefs! [...]

I warned you :)

> [...] root_task_group is outside CONFIG_USER_SCHED, and so I kept
> that property in patch v3.
>
> However, its definition in kernel/sched.h is conditional on
> CONFIG_USER_SCHED, even though root_task_group_empty() may exist
> outside of CONFIG_USER_SCHED, and root_task_group is referenced vi
> CONFIG_FAIR_GROUP_SCHED || CONFIG_RT_GROUP_SCHED.
>
> Starting to wish I had never patched this code in the first place
> (that barb is directed at the code, not you...)

How would you fix it? People dont like the idea of unconditional
group scheduler, so we cannot remove the variability really.

Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/