Re: [PATCH 1/2 #tj-percpu] x86: fix build breakage on voyage

James Bottomley
2009-01-27T16:53:32Z

On Tue, 2009-01-27 at 11:25 -0500, Brian Gerst wrote:
> To be fair, setup_percpu.c isn't built on UP. But we're splitting
> hairs over just 3 conditional variables. I'm open to ideas, but I'm
> quite certain that any general solution will have more overhead than
> the current code. I am looking at a patch to remove the early percpu
> pointers, so the second set of ifdefs would go away.

Well, how much do you need rid of? All the local apic stuff can move
into apic.c as something like x86_percpu_apic_setup(cpu) for the in loop
stuff and x86_percpu_apic_global() for the rest ... these then become
weak empty functions in setup_percpu.c. That elimiates the alleged
voyager problem.

The other cases are nastier: there's a numa case, an x86_84 case and a
both numa and x86_64 case. We only have files for the x86_64 case. At
a stretch the numa cases could move into mm/numa_${BITS}.c

This isn't really hugely critical path so this type of approach would
work ... I can cook up a patch if it's acceptable?

James