summaryrefslogtreecommitdiff
path: root/recipes-kernel/linux/linux-at91-5.4.243/mtcdt/linux-5.4-reserve-5-bit-serial-for-multidrop.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-kernel/linux/linux-at91-5.4.243/mtcdt/linux-5.4-reserve-5-bit-serial-for-multidrop.patch')
-rw-r--r--recipes-kernel/linux/linux-at91-5.4.243/mtcdt/linux-5.4-reserve-5-bit-serial-for-multidrop.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-at91-5.4.243/mtcdt/linux-5.4-reserve-5-bit-serial-for-multidrop.patch b/recipes-kernel/linux/linux-at91-5.4.243/mtcdt/linux-5.4-reserve-5-bit-serial-for-multidrop.patch
new file mode 100644
index 0000000..33f8ecd
--- /dev/null
+++ b/recipes-kernel/linux/linux-at91-5.4.243/mtcdt/linux-5.4-reserve-5-bit-serial-for-multidrop.patch
@@ -0,0 +1,31 @@
+From 1edc302f56b57512a99d6c21e1ddb85a89d16045 Mon Sep 17 00:00:00 2001
+From: Andrii Pientsov <andrii.pientsov@globallogic.com>
+Date: Mon, 22 Nov 2021 12:03:15 +0200
+Subject: [PATCH] [PATCH] linux-5.4-reserve-5-bit-serial-for-multidrop
+
+---
+ drivers/tty/serial/atmel_serial.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/tty/serial/atmel_serial.c b/drivers/tty/serial/atmel_serial.c
+index ea0215a0f4a4..28d4a92c0d63 100644
+--- a/drivers/tty/serial/atmel_serial.c
++++ b/drivers/tty/serial/atmel_serial.c
+@@ -2158,10 +2158,13 @@ static void atmel_set_termios(struct uart_port *port, struct ktermios *termios,
+
+ baud = uart_get_baud_rate(port, termios, old, 0, port->uartclk / 16);
+
++ mdrop = 0;
+ /* byte size */
+ switch (termios->c_cflag & CSIZE) {
+ case CS5:
+- mode |= ATMEL_US_CHRL_5;
++ mode |= ATMEL_US_PAR_MULTI_DROP;
++ mdrop = ATMEL_US_SENDA;
++ printk(KERN_INFO "termios: Setting Atmel Multi-Drop serial");
+ break;
+ case CS6:
+ mode |= ATMEL_US_CHRL_6;
+--
+2.25.1
+