svn commit: r366650 - stable/12/sys/kern

Mark Johnston markj at FreeBSD.org
Mon Oct 12 16:45:07 UTC 2020


Author: markj
Date: Mon Oct 12 16:45:07 2020
New Revision: 366650
URL: https://svnweb.freebsd.org/changeset/base/366650

Log:
  MFC r366450:
  Remove sysctl_kern_consmute()

Modified:
  stable/12/sys/kern/kern_cons.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/kern/kern_cons.c
==============================================================================
--- stable/12/sys/kern/kern_cons.c	Mon Oct 12 16:44:05 2020	(r366649)
+++ stable/12/sys/kern/kern_cons.c	Mon Oct 12 16:45:07 2020	(r366650)
@@ -90,7 +90,11 @@ int	cons_avail_mask = 0;	/* Bit mask. Each registered 
 				 * (i.e., if it is in graphics mode) will have
 				 * this bit cleared.
 				 */
+
 static int cn_mute;
+SYSCTL_INT(_kern, OID_AUTO, consmute, CTLFLAG_RW, &cn_mute, 0,
+    "State of the console muting");
+
 static char *consbuf;			/* buffer used by `consmsgbuf' */
 static struct callout conscallout;	/* callout for outputting to constty */
 struct msgbuf consmsgbuf;		/* message buffer for console tty */
@@ -338,25 +342,6 @@ sysctl_kern_console(SYSCTL_HANDLER_ARGS)
 
 SYSCTL_PROC(_kern, OID_AUTO, console, CTLTYPE_STRING|CTLFLAG_RW,
 	0, 0, sysctl_kern_console, "A", "Console device control");
-
-/*
- * User has changed the state of the console muting.
- * This may require us to open or close the device in question.
- */
-static int
-sysctl_kern_consmute(SYSCTL_HANDLER_ARGS)
-{
-	int error;
-
-	error = sysctl_handle_int(oidp, &cn_mute, 0, req);
-	if (error != 0 || req->newptr == NULL)
-		return (error);
-	return (error);
-}
-
-SYSCTL_PROC(_kern, OID_AUTO, consmute, CTLTYPE_INT|CTLFLAG_RW,
-	0, sizeof(cn_mute), sysctl_kern_consmute, "I",
-	"State of the console muting");
 
 void
 cngrab()


More information about the svn-src-all mailing list