diff options
Diffstat (limited to 'arch/sh/kernel/early_printk.c')
-rw-r--r-- | arch/sh/kernel/early_printk.c | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/arch/sh/kernel/early_printk.c b/arch/sh/kernel/early_printk.c index 957f25611543..18ca249e8409 100644 --- a/arch/sh/kernel/early_printk.c +++ b/arch/sh/kernel/early_printk.c | |||
@@ -141,6 +141,7 @@ static void scif_sercon_init(char *s) | |||
141 | */ | 141 | */ |
142 | static void scif_sercon_init(char *s) | 142 | static void scif_sercon_init(char *s) |
143 | { | 143 | { |
144 | struct uart_port *port = &scif_port; | ||
144 | unsigned baud = DEFAULT_BAUD; | 145 | unsigned baud = DEFAULT_BAUD; |
145 | char *e; | 146 | char *e; |
146 | 147 | ||
@@ -160,19 +161,20 @@ static void scif_sercon_init(char *s) | |||
160 | baud = DEFAULT_BAUD; | 161 | baud = DEFAULT_BAUD; |
161 | } | 162 | } |
162 | 163 | ||
163 | ctrl_outw(0, scif_port.mapbase + 8); | 164 | sci_out(port, SCSCR, 0); /* TE=0, RE=0 */ |
164 | ctrl_outw(0, scif_port.mapbase); | 165 | sci_out(port, SCSMR, 0); |
165 | 166 | ||
166 | /* Set baud rate */ | 167 | /* Set baud rate */ |
167 | ctrl_outb((CONFIG_SH_PCLK_FREQ + 16 * baud) / | 168 | sci_out(port, SCBRR, (CONFIG_SH_PCLK_FREQ + 16 * baud) / |
168 | (32 * baud) - 1, scif_port.mapbase + 4); | 169 | (32 * baud) - 1); |
169 | 170 | ||
170 | ctrl_outw(12, scif_port.mapbase + 24); | 171 | sci_out(port, SCFCR, 12); |
171 | ctrl_outw(8, scif_port.mapbase + 24); | 172 | sci_out(port, SCFCR, 8); |
172 | ctrl_outw(0, scif_port.mapbase + 32); | 173 | |
173 | ctrl_outw(0x60, scif_port.mapbase + 16); | 174 | sci_out(port, SCSPTR, 0); |
174 | ctrl_outw(0, scif_port.mapbase + 36); | 175 | sci_out(port, SCxSR, 0x60); |
175 | ctrl_outw(0x30, scif_port.mapbase + 8); | 176 | sci_out(port, SCLSR, 0); |
177 | sci_out(port, SCSCR, 0x30); /* TE=1, RE=1 */ | ||
176 | } | 178 | } |
177 | #endif /* defined(CONFIG_CPU_SUBTYPE_SH7720) */ | 179 | #endif /* defined(CONFIG_CPU_SUBTYPE_SH7720) */ |
178 | #endif /* !defined(CONFIG_SH_STANDARD_BIOS) */ | 180 | #endif /* !defined(CONFIG_SH_STANDARD_BIOS) */ |