diff options
Diffstat (limited to 'arch/mips/sgi-ip22')
-rw-r--r-- | arch/mips/sgi-ip22/ip22-setup.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/arch/mips/sgi-ip22/ip22-setup.c b/arch/mips/sgi-ip22/ip22-setup.c index 5e59b4c8876b..7018e1833e85 100644 --- a/arch/mips/sgi-ip22/ip22-setup.c +++ b/arch/mips/sgi-ip22/ip22-setup.c | |||
@@ -56,6 +56,7 @@ extern void ip22_time_init(void) __init; | |||
56 | void __init plat_setup(void) | 56 | void __init plat_setup(void) |
57 | { | 57 | { |
58 | char *ctype; | 58 | char *ctype; |
59 | char *cserial; | ||
59 | 60 | ||
60 | board_be_init = ip22_be_init; | 61 | board_be_init = ip22_be_init; |
61 | ip22_time_init(); | 62 | ip22_time_init(); |
@@ -81,9 +82,14 @@ void __init plat_setup(void) | |||
81 | /* ARCS console environment variable is set to "g?" for | 82 | /* ARCS console environment variable is set to "g?" for |
82 | * graphics console, it is set to "d" for the first serial | 83 | * graphics console, it is set to "d" for the first serial |
83 | * line and "d2" for the second serial line. | 84 | * line and "d2" for the second serial line. |
85 | * | ||
86 | * Need to check if the case is 'g' but no keyboard: | ||
87 | * (ConsoleIn/Out = serial) | ||
84 | */ | 88 | */ |
85 | ctype = ArcGetEnvironmentVariable("console"); | 89 | ctype = ArcGetEnvironmentVariable("console"); |
86 | if (ctype && *ctype == 'd') { | 90 | cserial = ArcGetEnvironmentVariable("ConsoleOut"); |
91 | |||
92 | if ((ctype && *ctype == 'd') || (cserial && *cserial == 's')) { | ||
87 | static char options[8]; | 93 | static char options[8]; |
88 | char *baud = ArcGetEnvironmentVariable("dbaud"); | 94 | char *baud = ArcGetEnvironmentVariable("dbaud"); |
89 | if (baud) | 95 | if (baud) |
@@ -91,7 +97,7 @@ void __init plat_setup(void) | |||
91 | add_preferred_console("ttyS", *(ctype + 1) == '2' ? 1 : 0, | 97 | add_preferred_console("ttyS", *(ctype + 1) == '2' ? 1 : 0, |
92 | baud ? options : NULL); | 98 | baud ? options : NULL); |
93 | } else if (!ctype || *ctype != 'g') { | 99 | } else if (!ctype || *ctype != 'g') { |
94 | /* Use ARC if we don't want serial ('d') or Newport ('g'). */ | 100 | /* Use ARC if we don't want serial ('d') or graphics ('g'). */ |
95 | prom_flags |= PROM_FLAG_USE_AS_CONSOLE; | 101 | prom_flags |= PROM_FLAG_USE_AS_CONSOLE; |
96 | add_preferred_console("arc", 0, NULL); | 102 | add_preferred_console("arc", 0, NULL); |
97 | } | 103 | } |