diff options
author | Colin Cross <ccross@android.com> | 2010-12-21 18:34:37 -0800 |
---|---|---|
committer | Colin Cross <ccross@android.com> | 2010-12-21 18:34:37 -0800 |
commit | b104a07edb2a319f734ddc4fe04852865d8d9e24 (patch) | |
tree | a0cd50b3d84ece4d94e366fac4b440e380c2d247 /drivers/serial | |
parent | e87ec4d59e1f96381547e614c5279bed63775719 (diff) | |
parent | a1346c99fc89f2b3d35c7d7e2e4aef8ea4124342 (diff) |
Merge commit 'v2.6.36.2' into linux-tegra-2.6.36
Diffstat (limited to 'drivers/serial')
-rw-r--r-- | drivers/serial/mfd.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/drivers/serial/mfd.c b/drivers/serial/mfd.c index 5dff45c76d32..f083f7c90c29 100644 --- a/drivers/serial/mfd.c +++ b/drivers/serial/mfd.c @@ -892,8 +892,7 @@ serial_hsu_set_termios(struct uart_port *port, struct ktermios *termios, unsigned char cval, fcr = 0; unsigned long flags; unsigned int baud, quot; - u32 mul = 0x3600; - u32 ps = 0x10; + u32 ps, mul; switch (termios->c_cflag & CSIZE) { case CS5: @@ -937,20 +936,19 @@ serial_hsu_set_termios(struct uart_port *port, struct ktermios *termios, ps = 0xC; quot = 1; break; - case 2500000: - mul = 0x2710; - ps = 0x10; - quot = 1; - break; case 18432000: mul = 0x2400; ps = 0x10; quot = 1; break; + case 3000000: + case 2500000: + case 2000000: case 1500000: - mul = 0x1D4C; - ps = 0xc; - quot = 1; + case 1000000: + case 500000: + /* mul/ps/quot = 0x9C4/0x10/0x1 will make a 500000 bps */ + mul = baud / 500000 * 0x9C4; break; default: ; |