svn commit: r262921 - head/sys/dev/uart

Warner Losh imp at FreeBSD.org
Sat Mar 8 03:39:16 UTC 2014


Author: imp
Date: Sat Mar  8 03:39:15 2014
New Revision: 262921
URL: http://svnweb.freebsd.org/changeset/base/262921

Log:
  Set the baud rate if it isn't 0 (meaning it has been specified) not
  only if it is 0 (meaning that it hasn't been specified and is likely
  to turn off the UART's transmitter).

Modified:
  head/sys/dev/uart/uart_core.c

Modified: head/sys/dev/uart/uart_core.c
==============================================================================
--- head/sys/dev/uart/uart_core.c	Sat Mar  8 03:39:09 2014	(r262920)
+++ head/sys/dev/uart/uart_core.c	Sat Mar  8 03:39:15 2014	(r262921)
@@ -473,7 +473,7 @@ uart_bus_attach(device_t dev)
 	}
 
 	if (sc->sc_sysdev != NULL) {
-		if (sc->sc_sysdev->baudrate == 0) {
+		if (sc->sc_sysdev->baudrate != 0) {
 			if (UART_IOCTL(sc, UART_IOCTL_BAUD,
 			    (intptr_t)&sc->sc_sysdev->baudrate) != 0)
 				sc->sc_sysdev->baudrate = -1;


More information about the svn-src-head mailing list