diff options
author | David Woodhouse <dwmw2@infradead.org> | 2008-04-13 12:52:38 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2008-04-16 17:46:12 -0400 |
commit | 7f4392cdcc63fea72fc77d14497059267d77d5d0 (patch) | |
tree | 4fa43a2b38636cdf5ffbd441e7ed3b258ca2a880 /arch/powerpc/kernel/prom_init.c | |
parent | 612212a3f2f053ea68ce9cd16d3deeca7754e8c9 (diff) |
[POWERPC] Efika: Really, don't pretend to be CHRP
Fedora 9 works on Efika without the separate 'device-tree supplement',
thanks to the kernel's own fixups. With one exception -- because 'CHRP'
still appears on the 'machine:' line in /proc/cpuinfo, the installer
misdetects the platform and misconfigures yaboot, putting it into a PReP
boot partition instead of in the /boot filesystem where the Efika's
firmware could find it.
The kernel's fixups for Efika already correct one instance of 'chrp', in
the 'device_type' property. This fixes it in the 'CODEGEN,description'
property too, since that's what's exposed to userspace in /proc/cpuinfo.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/kernel/prom_init.c')
-rw-r--r-- | arch/powerpc/kernel/prom_init.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/prom_init.c b/arch/powerpc/kernel/prom_init.c index 5ab4c8466cc9..6d6df1e60325 100644 --- a/arch/powerpc/kernel/prom_init.c +++ b/arch/powerpc/kernel/prom_init.c | |||
@@ -2240,6 +2240,14 @@ static void __init fixup_device_tree_efika(void) | |||
2240 | if (rv != PROM_ERROR && (strcmp(prop, "chrp") == 0)) | 2240 | if (rv != PROM_ERROR && (strcmp(prop, "chrp") == 0)) |
2241 | prom_setprop(node, "/", "device_type", "efika", sizeof("efika")); | 2241 | prom_setprop(node, "/", "device_type", "efika", sizeof("efika")); |
2242 | 2242 | ||
2243 | /* CODEGEN,description is exposed in /proc/cpuinfo so | ||
2244 | fix that too */ | ||
2245 | rv = prom_getprop(node, "CODEGEN,description", prop, sizeof(prop)); | ||
2246 | if (rv != PROM_ERROR && (strstr(prop, "CHRP"))) | ||
2247 | prom_setprop(node, "/", "CODEGEN,description", | ||
2248 | "Efika 5200B PowerPC System", | ||
2249 | sizeof("Efika 5200B PowerPC System")); | ||
2250 | |||
2243 | /* Fixup bestcomm interrupts property */ | 2251 | /* Fixup bestcomm interrupts property */ |
2244 | node = call_prom("finddevice", 1, 1, ADDR("/builtin/bestcomm")); | 2252 | node = call_prom("finddevice", 1, 1, ADDR("/builtin/bestcomm")); |
2245 | if (PHANDLE_VALID(node)) { | 2253 | if (PHANDLE_VALID(node)) { |