Skip to content

Commit 2b857d6

Browse files
Łukasz Bartosikgregkh
authored andcommitted
xhci: dbctty: disable ECHO flag by default
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 cd65ee8 commit 2b857d6

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
@@ -617,6 +617,7 @@ int dbc_tty_init(void)
617617
dbc_tty_driver->type = TTY_DRIVER_TYPE_SERIAL;
618618
dbc_tty_driver->subtype = SERIAL_TYPE_NORMAL;
619619
dbc_tty_driver->init_termios = tty_std_termios;
620+
dbc_tty_driver->init_termios.c_lflag &= ~ECHO;
620621
dbc_tty_driver->init_termios.c_cflag =
621622
B9600 | CS8 | CREAD | HUPCL | CLOCAL;
622623
dbc_tty_driver->init_termios.c_ispeed = 9600;

0 commit comments

Comments
 (0)