[POWERPC] Do firmware feature fixups after features are initialised
authorMichael Neuling <mikey@neuling.org>
Fri, 8 Jun 2007 04:00:35 +0000 (14:00 +1000)
committerPaul Mackerras <paulus@samba.org>
Mon, 25 Jun 2007 07:03:26 +0000 (17:03 +1000)
On pSeries the firmware features are not setup until ppc_md.init_early,
so we can't do the firmware feature sections fixups till after this.

Currently firmware feature sections is only used on iSeries which inits
the firmware features much earlier.  This is a bug in waiting on
pSeries.

Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/kernel/setup_64.c

index 6018178708a55f76be298d405c0fd8d76c9af6b2..bc43bba05cf84e3793dc01aa1b692364cecf331b 100644 (file)
@@ -350,13 +350,11 @@ void __init setup_system(void)
 {
        DBG(" -> setup_system()\n");
 
-       /* Apply the CPUs-specific and firmware specific fixups to kernel
-        * text (nop out sections not relevant to this CPU or this firmware)
+       /* Apply CPUs-specific fixups to kernel text (nop out sections
+        * not relevant to this CPU)
         */
        do_feature_fixups(cur_cpu_spec->cpu_features,
                          &__start___ftr_fixup, &__stop___ftr_fixup);
-       do_feature_fixups(powerpc_firmware_features,
-                         &__start___fw_ftr_fixup, &__stop___fw_ftr_fixup);
 
        /*
         * Unflatten the device-tree passed by prom_init or kexec
@@ -394,6 +392,12 @@ void __init setup_system(void)
        if (ppc_md.init_early)
                ppc_md.init_early();
 
+       /* Apply firmware specific fixups to kernel text (nop out
+        * sections not relevant to this firmware)
+        */
+       do_feature_fixups(powerpc_firmware_features,
+                         &__start___fw_ftr_fixup, &__stop___fw_ftr_fixup);
+
        /*
         * We can discover serial ports now since the above did setup the
         * hash table management for us, thus ioremap works. We do that early