lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 22 Oct 2009 09:31:52 -0700 (PDT)
From:	Eugene Bordenkircher <eugebo@...il.com>
To:	linux-kernel@...r.kernel.org
Subject: Ordering problem in serial_core.c




---------- Forwarded message ----------
From: Eugene Bordenkircher <eug...@...il.com>
Date: Oct 22, 9:19 am
Subject: Ordering problem in serial_core.c
To: fa.linux.kernel


There is an ordering problem with closing a UART in the serial core.
If the line discipline is throttling the port when close is called, it
tries to unthrottle the port which, in the case of soft flow, tries to
send the XON character.  This doesn't work well since at this point
the uart has been shutdown.

The simple reordering shown below will seems to fix the problem, but
please comment if there are other side effects I am not seeing.

Eugene T. Bordenkircher

--- linux_kernel/drivers/serial/serial_core.c.orig      2009-08-13
14:58:04.000000000 -0700
+++ linux_kernel/drivers/serial/serial_core.c   2009-08-13
15:29:02.000000000 -0700
@@ -1317,11 +1317,11 @@
                uart_wait_until_sent(tty, port->timeout);
        }

+       tty_ldisc_flush(tty);
+
        uart_shutdown(state);
        uart_flush_buffer(tty);

-       tty_ldisc_flush(tty);
-
        tty->closing = 0;
        state->info.port.tty = NULL;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ