]> git.ipfire.org Git - ipfire-2.x.git/blame - src/patches/suse-2.6.27.39/patches.arch/ppc-prom-nodisplay.patch
Fix oinkmaster patch.
[ipfire-2.x.git] / src / patches / suse-2.6.27.39 / patches.arch / ppc-prom-nodisplay.patch
CommitLineData
2cb7cef9
BS
1From: unknown@suse.de
2Subject: some crazy ppc patch
3
4add prom=nodisplay
5avoid crash in firmware on IBM B50 when OF stdout is on serial.
6
7 0 > boot scsi/sd@4:1,yaboot |
8yaboot starting: loaded at 00200000 00222530 (0/0/00c1a078; sp: 00efffd0)
9brokenfirmware did not claim executable memory, fixed it myself
10Config file 'yaboot.cnf' read, 213 bytes
11
12Welcome to yaboot version 10.1.22-r945.SuSE
13booted from '/pci@80000000/scsi@10/sd@4:1,yaboot'
14Enter "help" to get some basic usage information
15boot:
16* linux
17boot: linux 3
18Please wait, loading kernel...
19Allocated 00600000 bytes for executable @ 02000000
20 Elf32 kernel loaded...
21Loading ramdisk...
22ramdisk loaded 0030e057 @ 04100000
23OF stdout device is: /pci@80000000/isa@b/serial@i3f8
24command line: root=/dev/system/root xmon=on sysrq=1 quiet panic=12 3
25memory layout at init:
26 memory_limit : 00000000 (16 MB aligned)
27 alloc_bottom : 0440f000
28 alloc_top : 30000000
29 alloc_top_hi : 40000000
30 rmo_top : 30000000
31 ram_top : 40000000
32Looking for displays
33found display : /pci@80000000/display@16, opening ...
34Unexpected Firmware Error:
35DEFAULT CATCH!, code=fff00300 at %SRR0: 00c18ccc %SRR1: 00003030
36 ok
37 0 > reset-all
38
39
40---
41 arch/powerpc/kernel/prom_init.c | 12 ++++++++++--
42 1 file changed, 10 insertions(+), 2 deletions(-)
43
44--- a/arch/powerpc/kernel/prom_init.c
45+++ b/arch/powerpc/kernel/prom_init.c
46@@ -172,6 +172,7 @@ static unsigned long __initdata dt_strin
47
48 static unsigned long __initdata prom_initrd_start, prom_initrd_end;
49
50+static int __initdata prom_no_display;
51 #ifdef CONFIG_PPC64
52 static int __initdata prom_iommu_force_on;
53 static int __initdata prom_iommu_off;
54@@ -555,9 +556,7 @@ unsigned long prom_memparse(const char *
55 static void __init early_cmdline_parse(void)
56 {
57 struct prom_t *_prom = &RELOC(prom);
58-#ifdef CONFIG_PPC64
59 const char *opt;
60-#endif
61 char *p;
62 int l = 0;
63
64@@ -572,6 +571,14 @@ static void __init early_cmdline_parse(v
65 #endif /* CONFIG_CMDLINE */
66 prom_printf("command line: %s\n", RELOC(prom_cmd_line));
67
68+ opt = strstr(RELOC(prom_cmd_line), RELOC("prom="));
69+ if (opt) {
70+ opt += 5;
71+ while (*opt && *opt == ' ')
72+ opt++;
73+ if (!strncmp(opt, RELOC("nodisplay"), 9))
74+ RELOC(prom_no_display) = 1;
75+ }
76 #ifdef CONFIG_PPC64
77 opt = strstr(RELOC(prom_cmd_line), RELOC("iommu="));
78 if (opt) {
79@@ -2400,6 +2407,7 @@ unsigned long __init prom_init(unsigned
80 /*
81 * Initialize display devices
82 */
83+ if (RELOC(prom_no_display) == 0)
84 prom_check_displays();
85
86 #ifdef CONFIG_PPC64