Skip to content

Commit 5a26f6b

Browse files
mikeypaulusmack
authored andcommitted
[POWERPC] Do firmware feature fixups after features are initialised
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 <[email protected]> Signed-off-by: Paul Mackerras <[email protected]>
1 parent 4cefebb commit 5a26f6b

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

arch/powerpc/kernel/setup_64.c

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -350,13 +350,11 @@ void __init setup_system(void)
350350
{
351351
DBG(" -> setup_system()\n");
352352

353-
/* Apply the CPUs-specific and firmware specific fixups to kernel
354-
* text (nop out sections not relevant to this CPU or this firmware)
353+
/* Apply CPUs-specific fixups to kernel text (nop out sections
354+
* not relevant to this CPU)
355355
*/
356356
do_feature_fixups(cur_cpu_spec->cpu_features,
357357
&__start___ftr_fixup, &__stop___ftr_fixup);
358-
do_feature_fixups(powerpc_firmware_features,
359-
&__start___fw_ftr_fixup, &__stop___fw_ftr_fixup);
360358

361359
/*
362360
* Unflatten the device-tree passed by prom_init or kexec
@@ -394,6 +392,12 @@ void __init setup_system(void)
394392
if (ppc_md.init_early)
395393
ppc_md.init_early();
396394

395+
/* Apply firmware specific fixups to kernel text (nop out
396+
* sections not relevant to this firmware)
397+
*/
398+
do_feature_fixups(powerpc_firmware_features,
399+
&__start___fw_ftr_fixup, &__stop___fw_ftr_fixup);
400+
397401
/*
398402
* We can discover serial ports now since the above did setup the
399403
* hash table management for us, thus ioremap works. We do that early

0 commit comments

Comments
 (0)