diff options
author | Scott Wood <scottwood@freescale.com> | 2009-04-03 17:15:49 -0400 |
---|---|---|
committer | Kumar Gala <galak@kernel.crashing.org> | 2009-04-06 10:09:33 -0400 |
commit | 4d8107f474029167ae69862bf6b2c7273be757c7 (patch) | |
tree | ce312eaf2287e848315fce699899c604fb6f4a5a /drivers/serial/cpm_uart | |
parent | bd86ef378412fc30282daf722a833f734e4e2236 (diff) |
cpm_uart: Disable CPM udbg when re-initing CPM uart, even if not the console.
Previously, if udbg was using the CPM uart, and the normal CPM uart driver
was enabled, but the console was directed elsewhere, udbg would not be
stopped prior to initialization. This resulted in udbg hanging forever
waiting for the CPM to process a descriptor.
Signed-off-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'drivers/serial/cpm_uart')
-rw-r--r-- | drivers/serial/cpm_uart/cpm_uart_core.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/serial/cpm_uart/cpm_uart_core.c b/drivers/serial/cpm_uart/cpm_uart_core.c index 4dd00bea191..f8df0681e16 100644 --- a/drivers/serial/cpm_uart/cpm_uart_core.c +++ b/drivers/serial/cpm_uart/cpm_uart_core.c | |||
@@ -1106,6 +1106,10 @@ static int cpm_uart_init_port(struct device_node *np, | |||
1106 | for (i = 0; i < NUM_GPIOS; i++) | 1106 | for (i = 0; i < NUM_GPIOS; i++) |
1107 | pinfo->gpios[i] = of_get_gpio(np, i); | 1107 | pinfo->gpios[i] = of_get_gpio(np, i); |
1108 | 1108 | ||
1109 | #ifdef CONFIG_PPC_EARLY_DEBUG_CPM | ||
1110 | udbg_putc = NULL; | ||
1111 | #endif | ||
1112 | |||
1109 | return cpm_uart_request_port(&pinfo->port); | 1113 | return cpm_uart_request_port(&pinfo->port); |
1110 | 1114 | ||
1111 | out_pram: | 1115 | out_pram: |
@@ -1255,10 +1259,6 @@ static int __init cpm_uart_console_setup(struct console *co, char *options) | |||
1255 | baud = 9600; | 1259 | baud = 9600; |
1256 | } | 1260 | } |
1257 | 1261 | ||
1258 | #ifdef CONFIG_PPC_EARLY_DEBUG_CPM | ||
1259 | udbg_putc = NULL; | ||
1260 | #endif | ||
1261 | |||
1262 | if (IS_SMC(pinfo)) { | 1262 | if (IS_SMC(pinfo)) { |
1263 | out_be16(&pinfo->smcup->smc_brkcr, 0); | 1263 | out_be16(&pinfo->smcup->smc_brkcr, 0); |
1264 | cpm_line_cr_cmd(pinfo, CPM_CR_STOP_TX); | 1264 | cpm_line_cr_cmd(pinfo, CPM_CR_STOP_TX); |