[PATCH] ppc32: fix: swallowed chars when booting.
Heiko Schocher
hs at denx.de
Mon Oct 31 22:29:22 EST 2005
Hello,
on a MPC8260 based Board, i lost some chars on the SMC2
Console, when booting the kernel. The following Patch
will fix this.
thanks
Heiko Schocher
Signed-off-by: Heiko Schocher <hs at denx.de>
---
drivers/serial/cpm_uart/cpm_uart_core.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/drivers/serial/cpm_uart/cpm_uart_core.c
b/drivers/serial/cpm_uart/cpm_uart_core.c
index 4c3ea05..ac05ee9 100644
--- a/drivers/serial/cpm_uart/cpm_uart_core.c
+++ b/drivers/serial/cpm_uart/cpm_uart_core.c
@@ -557,6 +557,11 @@ static void cpm_uart_set_termios(struct
* present.
*/
prev_mode = smcp->smc_smcmr;
+ /* Wait for all the BDs marked sent */
+ while(!cpm_uart_tx_empty(port)) {
+ set_current_state(TASK_UNINTERRUPTIBLE);
+ schedule_timeout(4);
+ }
smcp->smc_smcmr = smcr_mk_clen(bits) | cval | SMCMR_SM_UART;
smcp->smc_smcmr |= (prev_mode & (SMCMR_REN | SMCMR_TEN));
} else {
More information about the Linuxppc-dev
mailing list