[Pkg-sysvinit-commits] r909 - in sysvinit/trunk/debian: . initscripts/lib/init patches

Petter Reinholdtsen pere at costa.debian.org
Mon Sep 11 09:20:42 UTC 2006


Author: pere
Date: 2006-09-11 09:20:39 +0000 (Mon, 11 Sep 2006)
New Revision: 909

Added:
   sysvinit/trunk/debian/patches/68_init_quiet.dpatch
Modified:
   sysvinit/trunk/debian/changelog
   sysvinit/trunk/debian/initscripts/lib/init/vars.sh
   sysvinit/trunk/debian/patches/00list
Log:
  * Add support in the init.d scripts for the 'quiet' kernel option.
    Keep support for the experiemental INIT_VERBOSE, to make it
    possible to override VERBOSE=no on the kernel command line.
  * New patch 68_init_quiet to make init less verbose when the 'quiet'
    kernel option is used. (Closes: #326677)

Modified: sysvinit/trunk/debian/changelog
===================================================================
--- sysvinit/trunk/debian/changelog	2006-09-11 08:41:01 UTC (rev 908)
+++ sysvinit/trunk/debian/changelog	2006-09-11 09:20:39 UTC (rev 909)
@@ -5,6 +5,11 @@
   * Change mountnfs.sh, rc.local and skeleton to use /lib/init/vars.sh
     instead of sourcing /etc/default/rcS, to activate the INIT_VERBOSE
     variable for these scripts.
+  * Add support in the init.d scripts for the 'quiet' kernel option.
+    Keep support for the experiemental INIT_VERBOSE, to make it
+    possible to override VERBOSE=no on the kernel command line.
+  * New patch 68_init_quiet to make init less verbose when the 'quiet'
+    kernel option is used. (Closes: #326677)
 
  -- Petter Reinholdtsen <pere at debian.org>  Mon, 11 Sep 2006 00:44:44 +0200
 

Modified: sysvinit/trunk/debian/initscripts/lib/init/vars.sh
===================================================================
--- sysvinit/trunk/debian/initscripts/lib/init/vars.sh	2006-09-11 08:41:01 UTC (rev 908)
+++ sysvinit/trunk/debian/initscripts/lib/init/vars.sh	2006-09-11 09:20:39 UTC (rev 909)
@@ -3,4 +3,12 @@
 #
 
 [ -f /etc/default/rcS ] && . /etc/default/rcS
+
+# Accept the same 'quiet' option as the kernel
+if [ ! -e /proc/cmdline ] || egrep -qw 'quiet' /proc/cmdline ; then
+    VERBOSE="no"
+fi
+
+# But allow both rcS and the kernel options 'quiet' to be overrided
+# when INIT_VERBOSE=yes is used as well.
 [ "$INIT_VERBOSE" ] && VERBOSE="$INIT_VERBOSE"

Modified: sysvinit/trunk/debian/patches/00list
===================================================================
--- sysvinit/trunk/debian/patches/00list	2006-09-11 08:41:01 UTC (rev 908)
+++ sysvinit/trunk/debian/patches/00list	2006-09-11 09:20:39 UTC (rev 909)
@@ -26,6 +26,7 @@
 65_init_u_in_06
 66_init_emerg_tty
 67_init_hddown
+68_init_quiet
 70_wall_ttyname
 71_wall_hostname
 80_killall_sched

Added: sysvinit/trunk/debian/patches/68_init_quiet.dpatch
===================================================================
--- sysvinit/trunk/debian/patches/68_init_quiet.dpatch	                        (rev 0)
+++ sysvinit/trunk/debian/patches/68_init_quiet.dpatch	2006-09-11 09:20:39 UTC (rev 909)
@@ -0,0 +1,36 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+# 68_init_quiet.dpatch by Petter Reinholdtsen
+
+If the kernel was told to be quiet, let init be quiet too.  Based on
+patch from ubuntu, but using different activating variable.
+
+ at DPATCH@
+--- sysvinit_2.86.ds1-20/src/init.c.orig	2006-09-11 10:51:50.000000000 +0200
++++ sysvinit_2.86.ds1-20/src/init.c	2006-09-11 10:53:40.000000000 +0200
+@@ -115,6 +115,7 @@
+ char *console_dev;		/* Console device. */
+ int pipe_fd = -1;		/* /dev/initctl */
+ int did_boot = 0;		/* Did we already do BOOT* stuff? */
++int quietinit = 0;		/* Should init be quiet on load? */
+ int main(int, char **);
+ 
+ /*	Used by re-exec part */
+@@ -2423,7 +2424,8 @@
+   	/*
+ 	 *	Say hello to the world
+ 	 */
+-  	initlog(L_CO, bootmsg, "booting");
++	if (!quietinit)
++  		initlog(L_CO, bootmsg, "booting");
+ 
+   	/*
+ 	 *	See if we have to start an emergency shell.
+@@ -2651,6 +2653,8 @@
+ 			putenv("AUTOBOOT=YES");
+ 		else if (!strcmp(argv[f], "-b") || !strcmp(argv[f],"emergency"))
+ 			emerg_shell = 1;
++		else if (!strcmp(argv[f],"quiet"))
++			quietinit = 1;
+ 		else if (!strcmp(argv[f], "-z")) {
+ 			/* Ignore -z xxx */
+ 			if (argv[f + 1]) f++;




More information about the Pkg-sysvinit-commits mailing list