> diff -ruN linux-2.6.orig/arch/powerpc/kernel/cputable.c linux-2.6/ > arch/powerpc/kernel/cputable.c > --- linux-2.6.orig/arch/powerpc/kernel/cputable.c 2007-09-20 > 19:30:47.000000000 +0400 > +++ linux-2.6/arch/powerpc/kernel/cputable.c 2007-09-20 > 21:27:35.000000000 +0400
[snip] > @@ -1318,18 +1327,14 @@ > > for (i = 0; i < ARRAY_SIZE(cpu_specs); i++,s++) > if ((pvr & s->pvr_mask) == s->pvr_value) { > + cpu_setup_t setup_func = PTRRELOC(s->cpu_setup); > + > *cur = cpu_specs + i; > -#ifdef CONFIG_PPC64 > - /* ppc64 expects identify_cpu to also call setup_cpu > - * for that processor. I will consolidate that at a > - * later time, for now, just use our friend #ifdef. > - * we also don't need to PTRRELOC the function pointer > - * on ppc64 as we are running at 0 in real mode. > + /* ppc expects identify_cpu to also call setup_cpu > + * for that processor. > */ > - if (s->cpu_setup) { > - s->cpu_setup(offset, s); > - } > -#endif /* CONFIG_PPC64 */ > + if (setup_func) > + setup_func(offset, s); > return s; > } This should just be something like: #if defined(CONFIG_PPC64) || defined(CONFIG_BOOKE) if (s->cpu_setup) ... #endif we know reloc_offset is always 0 in book-e, plus fixup the comment. - k _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-dev