]> git.karo-electronics.de Git - karo-tx-linux.git/commit
serial: fsl_lpuart: restore UARTCR2 after watermark setup is done
authorShawn Guo <shawn.guo@freescale.com>
Mon, 8 Jul 2013 07:05:31 +0000 (15:05 +0800)
committerJason Liu <r64343@freescale.com>
Wed, 30 Oct 2013 01:53:40 +0000 (09:53 +0800)
commit720cbc5c305dda4550dd799e1c6b187545391116
tree0ec2cb41313678c3fe519be6d7c8bd735c586e4d
parenta7ad067bc14f3d08642419b6198b202e34aeb835
serial: fsl_lpuart: restore UARTCR2 after watermark setup is done

Function lpuart_setup_watermark() clears some bits in register UARTCR2
before writing FIFO configuration registers as required by hardware.
But it should restore UARTCR2 after that.  Otherwise, we end up changing
UARTCR2 register when setting up watermark, and that is not really
desirable.  At least, when low-level debug and earlyprint is enabled,
serial console is broken due to it.

Fix the problem by restoring UARTCR2 register at the end of function
lpuart_setup_watermark().

Signed-off-by: Shawn Guo <shawn.guo@freescale.com>
drivers/tty/serial/fsl_lpuart.c