diff options
Diffstat (limited to 'arch/mips/txx9/generic/setup_tx4927.c')
-rw-r--r-- | arch/mips/txx9/generic/setup_tx4927.c | 30 |
1 files changed, 12 insertions, 18 deletions
diff --git a/arch/mips/txx9/generic/setup_tx4927.c b/arch/mips/txx9/generic/setup_tx4927.c index 89d6e28add93..f80d4b7a694d 100644 --- a/arch/mips/txx9/generic/setup_tx4927.c +++ b/arch/mips/txx9/generic/setup_tx4927.c | |||
@@ -13,7 +13,6 @@ | |||
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/ioport.h> | 14 | #include <linux/ioport.h> |
15 | #include <linux/delay.h> | 15 | #include <linux/delay.h> |
16 | #include <linux/serial_core.h> | ||
17 | #include <linux/param.h> | 16 | #include <linux/param.h> |
18 | #include <asm/txx9irq.h> | 17 | #include <asm/txx9irq.h> |
19 | #include <asm/txx9tmr.h> | 18 | #include <asm/txx9tmr.h> |
@@ -21,7 +20,7 @@ | |||
21 | #include <asm/txx9/generic.h> | 20 | #include <asm/txx9/generic.h> |
22 | #include <asm/txx9/tx4927.h> | 21 | #include <asm/txx9/tx4927.h> |
23 | 22 | ||
24 | void __init tx4927_wdr_init(void) | 23 | static void __init tx4927_wdr_init(void) |
25 | { | 24 | { |
26 | /* clear WatchDogReset (W1C) */ | 25 | /* clear WatchDogReset (W1C) */ |
27 | tx4927_ccfg_set(TX4927_CCFG_WDRST); | 26 | tx4927_ccfg_set(TX4927_CCFG_WDRST); |
@@ -29,6 +28,11 @@ void __init tx4927_wdr_init(void) | |||
29 | tx4927_ccfg_set(TX4927_CCFG_WR); | 28 | tx4927_ccfg_set(TX4927_CCFG_WR); |
30 | } | 29 | } |
31 | 30 | ||
31 | void __init tx4927_wdt_init(void) | ||
32 | { | ||
33 | txx9_wdt_init(TX4927_TMR_REG(2) & 0xfffffffffULL); | ||
34 | } | ||
35 | |||
32 | static struct resource tx4927_sdram_resource[4]; | 36 | static struct resource tx4927_sdram_resource[4]; |
33 | 37 | ||
34 | void __init tx4927_setup(void) | 38 | void __init tx4927_setup(void) |
@@ -173,22 +177,12 @@ void __init tx4927_time_init(unsigned int tmrnr) | |||
173 | TXX9_IMCLK); | 177 | TXX9_IMCLK); |
174 | } | 178 | } |
175 | 179 | ||
176 | void __init tx4927_setup_serial(void) | 180 | void __init tx4927_sio_init(unsigned int sclk, unsigned int cts_mask) |
177 | { | 181 | { |
178 | #ifdef CONFIG_SERIAL_TXX9 | ||
179 | int i; | 182 | int i; |
180 | struct uart_port req; | 183 | |
181 | 184 | for (i = 0; i < 2; i++) | |
182 | for (i = 0; i < 2; i++) { | 185 | txx9_sio_init(TX4927_SIO_REG(i) & 0xfffffffffULL, |
183 | memset(&req, 0, sizeof(req)); | 186 | TXX9_IRQ_BASE + TX4927_IR_SIO(i), |
184 | req.line = i; | 187 | i, sclk, (1 << i) & cts_mask); |
185 | req.iotype = UPIO_MEM; | ||
186 | req.membase = (unsigned char __iomem *)TX4927_SIO_REG(i); | ||
187 | req.mapbase = TX4927_SIO_REG(i) & 0xfffffffffULL; | ||
188 | req.irq = TXX9_IRQ_BASE + TX4927_IR_SIO(i); | ||
189 | req.flags |= UPF_BUGGY_UART /*HAVE_CTS_LINE*/; | ||
190 | req.uartclk = TXX9_IMCLK; | ||
191 | early_serial_txx9_setup(&req); | ||
192 | } | ||
193 | #endif /* CONFIG_SERIAL_TXX9 */ | ||
194 | } | 188 | } |