]> git.baikalelectronics.ru Git - kernel.git/commit
serial: MPSC: set baudrate when BRG divider is set.
authorMark A. Greer <mgreer@mvista.com>
Tue, 5 Feb 2008 06:27:54 +0000 (22:27 -0800)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Tue, 5 Feb 2008 17:44:10 +0000 (09:44 -0800)
commit4631288ab3dc7e159404a6068cba675a2f6abafc
tree483bf4e7db67bcd7d292d09679cdc3f755e8ac85
parent4a4a6490b1bbb8d83257e794008f60a099fc3617
serial: MPSC: set baudrate when BRG divider is set.

The clock to generate the desired baudrate with the MPSC is first divided
by the Baud Rate Generator (BRG) and then by the MPSC itself.  So, when the
BRG divider is changed, the MPSC divider must also be changed to generate
the correct baudrate.  During MPSC initialization, the BRG divider is
changed but the MPSC divider isn't changed until much later.  This results
in some printk's coming out garbled.  To fix that, set the MPSC divider at
the same time that the BRG divider is changed.

Signed-off-by: Mark A. Greer <mgreer@mvista.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/serial/mpsc.c