Re: 2.6.38.3 and 2.6.39-rc4 hangs after "Booting the kernel" on quadPentium Pro system

From: Yinghai Lu
Date: Fri Apr 22 2011 - 15:47:21 EST


On 04/22/2011 12:29 PM, Ingo Molnar wrote:
>
> * Yinghai Lu <yinghai@xxxxxxxxxx> wrote:
>
>> with Chris's config for 2.6.39-rc4, current tip tree says:
>>
>> kernel/sched.c: In function âsched_initâ:
>> kernel/sched.c:7845:28: error: âload_balance_tmpmaskâ undeclared
>> (first use in this function)
>> kernel/sched.c:7845:28: note: each undeclared identifier is reported
>> only once for each function it appears in
>> kernel/sched.c:7845:3: warning: type defaults to âintâ in type name
>> kernel/sched.c:7845:28: warning: initialization makes pointer from
>> integer without a cast
>> kernel/sched.c:7845:3: warning: type defaults to âintâ in type name
>
> Which sha1? It builds fine here on:
>
> ae1e16c: Merge branch 'perf/urgent'
>

one local patch caused the problem.

Index: linux-2.6/kernel/sched.c
===================================================================
--- linux-2.6.orig/kernel/sched.c
+++ linux-2.6/kernel/sched.c
@@ -7808,9 +7808,6 @@ void __init sched_init(void)
#ifdef CONFIG_RT_GROUP_SCHED
alloc_size += 2 * nr_cpu_ids * sizeof(void **);
#endif
-#ifdef CONFIG_CPUMASK_OFFSTACK
- alloc_size += num_possible_cpus() * cpumask_size();
-#endif
if (alloc_size) {
ptr = (unsigned long)kzalloc(alloc_size, GFP_NOWAIT);

@@ -7830,14 +7827,12 @@ void __init sched_init(void)
ptr += nr_cpu_ids * sizeof(void **);

#endif /* CONFIG_RT_GROUP_SCHED */
-#ifdef CONFIG_CPUMASK_OFFSTACK
- for_each_possible_cpu(i) {
- per_cpu(load_balance_tmpmask, i) = (void *)ptr;
- ptr += cpumask_size();
- }
-#endif /* CONFIG_CPUMASK_OFFSTACK */
}

+ for_each_possible_cpu(i)
+ zalloc_cpumask_var_node(&per_cpu(load_balance_tmpmask, i),
+ GFP_NOWAIT, cpu_to_node(i));
+
#ifdef CONFIG_SMP
init_defrootdomain();
#endif


Sorry for noisy.

Thanks

Yinghai
--
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/