Skip to content

Commit c3b5229

Browse files
Łukasz Bartosikgregkh
authored andcommitted
xhci: dbctty: disable ECHO flag by default
commit 2b857d69a5e116150639a0c6c39c86cc329939ee upstream. When /dev/ttyDBC0 device is created then by default ECHO flag is set for the terminal device. However if data arrives from a peer before application using /dev/ttyDBC0 applies its set of terminal flags then the arriving data will be echoed which might not be desired behavior. Fixes: 4521f16 ("xhci: dbctty: split dbc tty driver registration and unregistration functions.") Cc: stable <[email protected]> Signed-off-by: Łukasz Bartosik <[email protected]> Signed-off-by: Mathias Nyman <[email protected]> Link: https://lore.kernel.org/stable/20250610111802.18742-1-ukaszb%40chromium.org Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 7135056 commit c3b5229

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/usb/host/xhci-dbgtty.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -586,6 +586,7 @@ int dbc_tty_init(void)
586586
dbc_tty_driver->type = TTY_DRIVER_TYPE_SERIAL;
587587
dbc_tty_driver->subtype = SERIAL_TYPE_NORMAL;
588588
dbc_tty_driver->init_termios = tty_std_termios;
589+
dbc_tty_driver->init_termios.c_lflag &= ~ECHO;
589590
dbc_tty_driver->init_termios.c_cflag =
590591
B9600 | CS8 | CREAD | HUPCL | CLOCAL;
591592
dbc_tty_driver->init_termios.c_ispeed = 9600;

0 commit comments

Comments
 (0)