Re: [PATCH 08/10] x86: Change NR_CPUS arrays in numa_64

From: Jan Engelhardt
Date: Mon Jan 14 2008 - 13:14:42 EST



On Jan 13 2008 10:35, travis@xxxxxxx wrote:
>--- a/arch/x86/kernel/setup_64.c
>+++ b/arch/x86/kernel/setup_64.c
>@@ -372,8 +373,9 @@ void __init setup_arch(char **cmdline_p)
> io_delay_init();
>
> #ifdef CONFIG_SMP
>- /* setup to use the static apicid table during kernel startup */
>+ /* setup to use the early static init tables during kernel startup */
> x86_cpu_to_apicid_early_ptr = (void *)&x86_cpu_to_apicid_init;
>+ x86_cpu_to_node_map_early_ptr = (void *)&x86_cpu_to_node_map_init;
> #endif
>
> #ifdef CONFIG_ACPI

Please do not add unnecessary casts.

>--- a/arch/x86/kernel/smpboot_64.c
>+++ b/arch/x86/kernel/smpboot_64.c
>@@ -559,8 +563,16 @@ __cpuinit void numa_add_cpu(int cpu)
>
> void __cpuinit numa_set_node(int cpu, int node)
> {
>+ u16 *cpu_to_node_map = (u16 *)x86_cpu_to_node_map_early_ptr;
>+

^

> static inline int cpu_to_node(int cpu)
> {
>- return cpu_to_node_map[cpu];
>+ u16 *cpu_to_node_map = (u16 *)x86_cpu_to_node_map_early_ptr;

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