svn commit: r254534 - in head/sys: conf dev/uart
Ian Lepore
ian at FreeBSD.org
Mon Aug 19 15:51:31 UTC 2013
Author: ian
Date: Mon Aug 19 15:51:30 2013
New Revision: 254534
URL: http://svnweb.freebsd.org/changeset/base/254534
Log:
Allow UART_POLL_FREQ to be set as a kernel option as well as via tunable
(the code was already set up for this, just needs to be in conf/options).
Also, if reporting that polling is being used, report the frequency too.
Modified:
head/sys/conf/NOTES
head/sys/conf/options
head/sys/dev/uart/uart_core.c
Modified: head/sys/conf/NOTES
==============================================================================
--- head/sys/conf/NOTES Mon Aug 19 15:36:23 2013 (r254533)
+++ head/sys/conf/NOTES Mon Aug 19 15:51:30 2013 (r254534)
@@ -1801,6 +1801,8 @@ device uart
# Options for uart(4)
options UART_PPS_ON_CTS # Do time pulse capturing using CTS
# instead of DCD.
+options UART_POLL_FREQ # Set polling rate, used when hw has
+ # no interrupt support (50 Hz default).
# The following hint should only be used for pure ISA devices. It is not
# needed otherwise. Use of hints is strongly discouraged.
Modified: head/sys/conf/options
==============================================================================
--- head/sys/conf/options Mon Aug 19 15:36:23 2013 (r254533)
+++ head/sys/conf/options Mon Aug 19 15:51:30 2013 (r254534)
@@ -641,8 +641,9 @@ BKTR_SIS_VIA_MODE opt_bktr.h
BKTR_USE_FREEBSD_SMBUS opt_bktr.h
BKTR_NEW_MSP34XX_DRIVER opt_bktr.h
-# Options to support PPS
+# Options for uart(4)
UART_PPS_ON_CTS opt_uart.h
+UART_POLL_FREQ opt_uart.h
# options for bus/device framework
BUS_DEBUG opt_bus.h
Modified: head/sys/dev/uart/uart_core.c
==============================================================================
--- head/sys/dev/uart/uart_core.c Mon Aug 19 15:36:23 2013 (r254533)
+++ head/sys/dev/uart/uart_core.c Mon Aug 19 15:51:30 2013 (r254534)
@@ -537,7 +537,7 @@ uart_bus_attach(device_t dev)
sep = ", ";
}
if (sc->sc_polled) {
- printf("%spolled mode", sep);
+ printf("%spolled mode (%dHz)", sep, uart_poll_freq);
sep = ", ";
}
printf("\n");
More information about the svn-src-all
mailing list