Re: [BUG] i386 2.6.18 cpu_up: attempt to bring up CPU 4 failed : kernel BUG at mm/slab.c:2698!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 22 Sep 2006 12:44:18 -0700
keith mannthey <[email protected]> wrote:

> 3. Flat mode i386 numa on a real numa system is broken.  If there is
> only 1 node in the system cpus should think they are apart of some other
> node.     Patch below.  
> 
> 
> 
>   If cases where a real numa system boots the Flat numa option make sure
> the cpus don't claim to be apart on a non-existent node.
> 
> 
> Signed-off-by: Keith Mannthey <[email protected]>
> 
> --- linux-2.6.18/arch/i386/kernel/smpboot.c	2006-09-19
> 20:42:06.000000000 -0700
> +++ linux-2.6.18-workes/arch/i386/kernel/smpboot.c	2006-09-21
> 21:57:55.000000000 -0700
> @@ -642,9 +642,13 @@
>  {
>  	int cpu = smp_processor_id();
>  	int apicid = logical_smp_processor_id();
> -
> +	int node = apicid_to_node(apicid);
> +	
> +	if (!node_online(node))
> +		node = first_online_node;
> +	
>  	cpu_2_logical_apicid[cpu] = apicid;
> -	map_cpu_to_node(cpu, apicid_to_node(apicid));
> +	map_cpu_to_node(cpu, node);
>  }
>  
>  static void unmap_cpu_to_logical_apicid(int cpu)

This clashes with your
convert-i386-summit-subarch-to-use-srat-info-for-apicid_to_node-calls.patch.

I fixed it thusly:

static void map_cpu_to_logical_apicid(void)
{
	int cpu = smp_processor_id();
	int apicid = logical_smp_processor_id();
	int node = apicid_to_node(hard_smp_processor_id());

	if (!node_online(node))
		node = first_online_node;

	cpu_2_logical_apicid[cpu] = apicid;
	map_cpu_to_node(cpu, node);
}


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

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux