aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2015-10-19 10:19:23 +0000
committerJohn Crispin <blogic@openwrt.org>2015-10-19 10:19:23 +0000
commit718cc02aa4e812f81e55c451c73023ab219e423b (patch)
tree643bdbf0e837a3597d5811c7e7d73782b95b685e
parentebff32ce9e793005ff6a54037bf02ea067a41569 (diff)
downloadupstream-718cc02aa4e812f81e55c451c73023ab219e423b.tar.gz
upstream-718cc02aa4e812f81e55c451c73023ab219e423b.tar.bz2
upstream-718cc02aa4e812f81e55c451c73023ab219e423b.zip
ramips: add a baurate hack
When talking to an atmel controller we need 9600 or 250000 baud. as 250000 does not exist we use 2500000. Signed-off-by: John Crispin <blogic@openwrt.org> Backport of r47204 git-svn-id: svn://svn.openwrt.org/openwrt/branches/chaos_calmer@47228 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--target/linux/ramips/patches-3.18/999-baud_250000.patch12
1 files changed, 12 insertions, 0 deletions
diff --git a/target/linux/ramips/patches-3.18/999-baud_250000.patch b/target/linux/ramips/patches-3.18/999-baud_250000.patch
new file mode 100644
index 0000000000..eebe31c918
--- /dev/null
+++ b/target/linux/ramips/patches-3.18/999-baud_250000.patch
@@ -0,0 +1,12 @@
+--- a/drivers/tty/serial/serial_core.c
++++ b/drivers/tty/serial/serial_core.c
+@@ -356,6 +356,9 @@
+ else if (flags == UPF_SPD_WARP)
+ altbaud = 460800;
+
++ if (tty_termios_baud_rate(termios) == 2500000)
++ return 250000;
++
+ for (try = 0; try < 2; try++) {
+ baud = tty_termios_baud_rate(termios);
+