head	1.25;
access;
symbols
	RELENG_8_4:1.25.0.2
	RELENG_9_1_0_RELEASE:1.23.2.1.4.2
	RELENG_9_1:1.23.2.1.0.4
	RELENG_9_1_BP:1.23.2.1
	RELENG_8_3_0_RELEASE:1.22.2.2.6.1
	RELENG_8_3:1.22.2.2.0.6
	RELENG_8_3_BP:1.22.2.2
	RELENG_9_0_0_RELEASE:1.23.2.1.2.1
	RELENG_9_0:1.23.2.1.0.2
	RELENG_9_0_BP:1.23.2.1
	RELENG_9:1.23.0.2
	RELENG_9_BP:1.23
	RELENG_7_4_0_RELEASE:1.21.2.1.2.1
	RELENG_8_2_0_RELEASE:1.22.2.2.4.1
	RELENG_7_4:1.21.2.1.0.2
	RELENG_7_4_BP:1.21.2.1
	RELENG_8_2:1.22.2.2.0.4
	RELENG_8_2_BP:1.22.2.2
	RELENG_8_1_0_RELEASE:1.22.2.2.2.1
	RELENG_8_1:1.22.2.2.0.2
	RELENG_8_1_BP:1.22.2.2
	RELENG_7_3_0_RELEASE:1.21.10.1
	RELENG_7_3:1.21.0.10
	RELENG_7_3_BP:1.21
	RELENG_8_0_0_RELEASE:1.22.2.1.2.1
	RELENG_8_0:1.22.2.1.0.2
	RELENG_8_0_BP:1.22.2.1
	RELENG_8:1.22.0.2
	RELENG_8_BP:1.22
	RELENG_7_2_0_RELEASE:1.21.8.1
	RELENG_7_2:1.21.0.8
	RELENG_7_2_BP:1.21
	RELENG_7_1_0_RELEASE:1.21.6.1
	RELENG_6_4_0_RELEASE:1.13.2.4.4.1
	RELENG_7_1:1.21.0.6
	RELENG_7_1_BP:1.21
	RELENG_6_4:1.13.2.4.0.4
	RELENG_6_4_BP:1.13.2.4
	RELENG_7_0_0_RELEASE:1.21
	RELENG_6_3_0_RELEASE:1.13.2.4
	RELENG_7_0:1.21.0.4
	RELENG_7_0_BP:1.21
	RELENG_6_3:1.13.2.4.0.2
	RELENG_6_3_BP:1.13.2.4
	RELENG_7:1.21.0.2
	RELENG_7_BP:1.21
	RELENG_6_2_0_RELEASE:1.13.2.2
	RELENG_6_2:1.13.2.2.0.4
	RELENG_6_2_BP:1.13.2.2
	RELENG_5_5_0_RELEASE:1.12.2.1
	RELENG_5_5:1.12.2.1.0.6
	RELENG_5_5_BP:1.12.2.1
	RELENG_6_1_0_RELEASE:1.13.2.2
	RELENG_6_1:1.13.2.2.0.2
	RELENG_6_1_BP:1.13.2.2
	RELENG_6_0_0_RELEASE:1.13
	RELENG_6_0:1.13.0.4
	RELENG_6_0_BP:1.13
	RELENG_6:1.13.0.2
	RELENG_6_BP:1.13
	RELENG_5_4_0_RELEASE:1.12.2.1
	RELENG_5_4:1.12.2.1.0.4
	RELENG_5_4_BP:1.12.2.1
	RELENG_5_3_0_RELEASE:1.12.2.1
	RELENG_5_3:1.12.2.1.0.2
	RELENG_5_3_BP:1.12.2.1
	RELENG_5:1.12.0.2
	RELENG_5_BP:1.12
	RELENG_5_2_1_RELEASE:1.9
	RELENG_5_2_0_RELEASE:1.9
	RELENG_5_2:1.9.0.6
	RELENG_5_2_BP:1.9
	RELENG_5_1_0_RELEASE:1.9
	RELENG_5_1:1.9.0.4
	RELENG_5_1_BP:1.9
	RELENG_5_0_0_RELEASE:1.9
	RELENG_5_0:1.9.0.2
	RELENG_5_0_BP:1.9
	old_RELENG_4_6_1_RELEASE:1.1.2.4
	old_RELENG_4_6_0_RELEASE:1.1.2.4
	old_RELENG_4_6:1.1.2.4.0.2
	old_RELENG_4_6_BP:1.1.2.4
	old_RELENG_4_5_0_RELEASE:1.1.2.3
	old_RELENG_4_5:1.1.2.3.0.2
	old_RELENG_4_5_BP:1.1.2.3
	old_RELENG_4_4_0_RELEASE:1.1.2.2
	old_RELENG_4_4:1.1.2.2.0.2
	old_RELENG_4_4_BP:1.1.2.2
	old_RELENG_4_3_0_RELEASE:1.1.2.1
	old_RELENG_4_3:1.1.2.1.0.2
	old_RELENG_4_3_BP:1.1.2.1
	old_RELENG_4:1.1.0.2;
locks; strict;
comment	@# @;


1.25
date	2012.11.17.01.49.06;	author svnexp;	state Exp;
branches
	1.25.2.1;
next	1.24;

1.24
date	2011.11.08.23.02.32;	author jilles;	state Exp;
branches;
next	1.23;

1.23
date	2010.05.14.04.53.57;	author dougb;	state Exp;
branches
	1.23.2.1;
next	1.22;

1.22
date	2008.06.24.21.01.56;	author mtm;	state Exp;
branches
	1.22.2.1;
next	1.21;

1.21
date	2007.03.25.23.58.46;	author brooks;	state Exp;
branches
	1.21.2.1
	1.21.6.1
	1.21.8.1
	1.21.10.1;
next	1.20;

1.20
date	2007.03.12.22.35.43;	author mux;	state Exp;
branches;
next	1.19;

1.19
date	2006.12.31.10.37.18;	author yar;	state Exp;
branches;
next	1.18;

1.18
date	2006.12.20.12.59.50;	author yar;	state Exp;
branches;
next	1.17;

1.17
date	2006.05.17.09.33.06;	author phk;	state Exp;
branches;
next	1.16;

1.16
date	2006.03.16.17.42.28;	author emax;	state Exp;
branches;
next	1.15;

1.15
date	2006.03.06.06.38.34;	author emax;	state Exp;
branches;
next	1.14;

1.14
date	2005.12.15.01.04.48;	author iedowse;	state Exp;
branches;
next	1.13;

1.13
date	2004.10.07.13.55.26;	author mtm;	state Exp;
branches
	1.13.2.1;
next	1.12;

1.12
date	2004.06.18.20.09.30;	author green;	state Exp;
branches
	1.12.2.1;
next	1.11;

1.11
date	2004.03.08.12.25.05;	author pjd;	state Exp;
branches;
next	1.10;

1.10
date	2003.12.10.15.48.49;	author peter;	state Exp;
branches;
next	1.9;

1.9
date	2002.09.09.22.40.34;	author gordon;	state Exp;
branches;
next	1.8;

1.8
date	2002.09.05.23.51.28;	author fenner;	state Exp;
branches;
next	1.7;

1.7
date	2002.06.20.08.49.44;	author dougb;	state Exp;
branches;
next	1.6;

1.6
date	2002.06.13.22.14.36;	author gordon;	state Exp;
branches;
next	1.5;

1.5
date	2001.08.31.15.29.24;	author dd;	state Exp;
branches;
next	1.4;

1.4
date	2001.08.09.15.36.03;	author obrien;	state Exp;
branches;
next	1.3;

1.3
date	2001.04.28.20.56.52;	author dd;	state Exp;
branches;
next	1.2;

1.2
date	2001.04.19.14.53.43;	author ache;	state Exp;
branches;
next	1.1;

1.1
date	2001.01.09.22.28.17;	author jhb;	state Exp;
branches
	1.1.2.1;
next	;

1.25.2.1
date	2012.11.17.01.49.06;	author svnexp;	state dead;
branches;
next	1.25.2.2;

1.25.2.2
date	2013.03.28.13.02.44;	author svnexp;	state Exp;
branches;
next	;

1.23.2.1
date	2011.09.23.00.51.37;	author kensmith;	state Exp;
branches
	1.23.2.1.2.1
	1.23.2.1.4.1;
next	1.23.2.2;

1.23.2.2
date	2012.11.17.11.36.11;	author svnexp;	state Exp;
branches;
next	;

1.23.2.1.2.1
date	2011.11.11.04.20.22;	author kensmith;	state Exp;
branches;
next	1.23.2.1.2.2;

1.23.2.1.2.2
date	2012.11.17.08.36.11;	author svnexp;	state Exp;
branches;
next	;

1.23.2.1.4.1
date	2012.08.05.23.54.33;	author kensmith;	state Exp;
branches;
next	1.23.2.1.4.2;

1.23.2.1.4.2
date	2012.11.17.08.47.01;	author svnexp;	state Exp;
branches;
next	;

1.22.2.1
date	2009.08.03.08.13.06;	author kensmith;	state Exp;
branches
	1.22.2.1.2.1;
next	1.22.2.2;

1.22.2.2
date	2010.05.14.19.28.16;	author dougb;	state Exp;
branches
	1.22.2.2.2.1
	1.22.2.2.4.1
	1.22.2.2.6.1;
next	1.22.2.3;

1.22.2.3
date	2012.11.17.10.35.57;	author svnexp;	state Exp;
branches;
next	;

1.22.2.1.2.1
date	2009.10.25.01.10.29;	author kensmith;	state Exp;
branches;
next	;

1.22.2.2.2.1
date	2010.06.14.02.09.06;	author kensmith;	state Exp;
branches;
next	;

1.22.2.2.4.1
date	2010.12.21.17.09.25;	author kensmith;	state Exp;
branches;
next	;

1.22.2.2.6.1
date	2012.03.03.06.15.13;	author kensmith;	state Exp;
branches;
next	1.22.2.2.6.2;

1.22.2.2.6.2
date	2012.11.17.08.24.38;	author svnexp;	state Exp;
branches;
next	;

1.21.2.1
date	2010.05.14.19.36.11;	author dougb;	state Exp;
branches
	1.21.2.1.2.1;
next	1.21.2.2;

1.21.2.2
date	2012.11.17.08.01.23;	author svnexp;	state Exp;
branches;
next	;

1.21.2.1.2.1
date	2010.12.21.17.10.29;	author kensmith;	state Exp;
branches;
next	1.21.2.1.2.2;

1.21.2.1.2.2
date	2012.11.17.08.16.37;	author svnexp;	state Exp;
branches;
next	;

1.21.6.1
date	2008.11.25.02.59.29;	author kensmith;	state Exp;
branches;
next	;

1.21.8.1
date	2009.04.15.03.14.26;	author kensmith;	state Exp;
branches;
next	;

1.21.10.1
date	2010.02.10.00.26.20;	author kensmith;	state Exp;
branches;
next	;

1.13.2.1
date	2006.03.07.06.13.17;	author emax;	state Exp;
branches;
next	1.13.2.2;

1.13.2.2
date	2006.03.21.19.42.32;	author emax;	state Exp;
branches;
next	1.13.2.3;

1.13.2.3
date	2007.03.10.14.00.51;	author yar;	state Exp;
branches;
next	1.13.2.4;

1.13.2.4
date	2007.03.29.19.06.14;	author mux;	state Exp;
branches
	1.13.2.4.4.1;
next	1.13.2.5;

1.13.2.5
date	2010.05.14.19.57.18;	author dougb;	state Exp;
branches;
next	1.13.2.6;

1.13.2.6
date	2012.11.17.07.39.09;	author svnexp;	state Exp;
branches;
next	;

1.13.2.4.4.1
date	2008.10.02.02.57.24;	author kensmith;	state Exp;
branches;
next	;

1.12.2.1
date	2004.10.10.09.50.54;	author mtm;	state Exp;
branches;
next	;

1.1.2.1
date	2001.02.27.20.03.28;	author jhb;	state Exp;
branches;
next	1.1.2.2;

1.1.2.2
date	2001.08.01.20.14.05;	author obrien;	state Exp;
branches;
next	1.1.2.3;

1.1.2.3
date	2001.10.15.13.45.38;	author dd;	state Exp;
branches;
next	1.1.2.4;

1.1.2.4
date	2002.04.15.00.44.13;	author dougb;	state Exp;
branches;
next	;


desc
@@


1.25
log
@Switching exporter and resync
@
text
@#!/bin/sh -
#
# Copyright (c) 2000  The FreeBSD Project
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
# 1. Redistributions of source code must retain the above copyright
#    notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
#    notice, this list of conditions and the following disclaimer in the
#    documentation and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
#
# $FreeBSD: head/etc/rc.d/syscons 227366 2011-11-08 23:02:32Z jilles $
#

# PROVIDE: syscons
# REQUIRE: LOGIN
# KEYWORD: nojail

. /etc/rc.subr

name="syscons"
extra_commands="setkeyboard"
setkeyboard_cmd="syscons_setkeyboard"
start_precmd="syscons_precmd"
start_cmd="syscons_start"
stop_cmd=":"

# stdin must be redirected because it might be for a serial console
#
kbddev=/dev/ttyv0
viddev=/dev/ttyv0

_sc_config="syscons"
_sc_initdone=
sc_init()
{
	if [ -z "${_sc_initdone}" ]; then
		echo -n "Configuring ${_sc_config}:"
		_sc_initdone=yes
	fi
}

# helper
syscons_configure_keyboard()
{
	# keymap
	#
	case ${keymap} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keymap';	kbdcontrol < ${kbddev} -l ${keymap}
		;;
	esac

	# keyrate
	#
	case ${keyrate} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keyrate';	kbdcontrol < ${kbddev} -r ${keyrate}
		;;
	esac

	# keybell
	#
	case ${keybell} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keybell';	kbdcontrol < ${kbddev} -b ${keybell}
		;;
	esac

	# change function keys
	#
	case ${keychange} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keychange'
		set -- ${keychange}
		while [ $# -gt 0 ]; do
			kbdcontrol <${kbddev} -f "$1" "$2"
			shift; shift
		done
		;;
	esac

	# set this keyboard mode for all virtual terminals
	#
	if [ -n "${allscreens_kbdflags}" ]; then
		sc_init
		echo -n ' allscreens_kbd'
		for ttyv in /dev/ttyv*; do
			kbdcontrol ${allscreens_kbdflags} < ${ttyv} > ${ttyv} 2>&1
		done
	fi
}

syscons_setkeyboard()
{
	kbd=$1

	if [ -z "${kbd}" ]; then
		return 1
	fi

	# Check if the kbdmux(4) is the current active keyboard
	kbdcontrol -i < ${kbddev} | grep kbdmux > /dev/null 2>&1
	if [ $? -ne 0 ]; then
		kbdcontrol -k ${kbd} < ${kbddev} > /dev/null 2>&1
	fi

	_sc_config="keyboard"
	syscons_configure_keyboard

	# Terminate keyboard configuration line and reset global variables.
	#
	if [ -n "${_sc_initdone}" ]; then
		echo '.'
		_sc_config="syscons"
		_sc_initdone=
	fi

}

syscons_precmd()
{
	if [ ! -c $kbddev ]
	then
		return 1
	fi
	return 0
}

syscons_start()
{
	# keyboard
	#
	if [ -n "${keyboard}" ]; then
		syscons_setkeyboard ${keyboard}
	fi

	syscons_configure_keyboard

	# cursor type
	#
	case ${cursor} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' cursor';	vidcontrol < ${viddev} -c ${cursor}
		;;
	esac

	# screen mapping
	#
	case ${scrnmap} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' scrnmap';	vidcontrol < ${viddev} -l ${scrnmap}
		;;
	esac

	# font 8x16
	#
	case ${font8x16} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' font8x16';	vidcontrol < ${viddev} -f 8x16 ${font8x16}
		;;
	esac

	# font 8x14
	#
	case ${font8x14} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' font8x14';	vidcontrol < ${viddev} -f 8x14 ${font8x14}
		;;
	esac

	# font 8x8
	#
	case ${font8x8} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' font8x8';	vidcontrol < ${viddev} -f 8x8 ${font8x8}
		;;
	esac

	# blank time
	#
	case ${blanktime} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' blanktime';	vidcontrol < ${viddev} -t ${blanktime}
		;;
	esac

	# screen saver
	#
	case ${saver} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' screensaver'
		for i in `kldstat | awk '$5 ~ "_saver\.ko$" { print $5 }'`; do
			kldunload ${i}
		done
		load_kld -e _saver ${saver}_saver
		;;
	esac

	# set this mode for all virtual screens
	#
	if [ -n "${allscreens_flags}" ]; then
		sc_init
		echo -n ' allscreens'
		for ttyv in /dev/ttyv*; do
			vidcontrol ${allscreens_flags} < ${ttyv} > ${ttyv} 2>&1
		done
	fi

	[ -n "${_sc_initdone}" ] && echo '.'
}

load_rc_config $name
run_rc_command $*

@


1.25.2.1
log
@file syscons was added on branch RELENG_8_4 on 2013-03-28 13:02:44 +0000
@
text
@d1 263
@


1.25.2.2
log
@## SVN ## Exported commit - http://svnweb.freebsd.org/changeset/base/248810
## SVN ## CVS IS DEPRECATED: http://wiki.freebsd.org/CvsIsDeprecated
@
text
@a0 263
#!/bin/sh -
#
# Copyright (c) 2000  The FreeBSD Project
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
# 1. Redistributions of source code must retain the above copyright
#    notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
#    notice, this list of conditions and the following disclaimer in the
#    documentation and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
#
# $FreeBSD: releng/8.4/etc/rc.d/syscons 208094 2010-05-14 19:28:16Z dougb $
#

# PROVIDE: syscons
# REQUIRE: LOGIN
# KEYWORD: nojail

. /etc/rc.subr

name="syscons"
extra_commands="setkeyboard"
setkeyboard_cmd="syscons_setkeyboard"
start_precmd="syscons_precmd"
start_cmd="syscons_start"
stop_cmd=":"

# stdin must be redirected because it might be for a serial console
#
kbddev=/dev/ttyv0
viddev=/dev/ttyv0

_sc_config="syscons"
_sc_initdone=
sc_init()
{
	if [ -z "${_sc_initdone}" ]; then
		echo -n "Configuring ${_sc_config}:"
		_sc_initdone=yes
	fi
}

# helper
syscons_configure_keyboard()
{
	# keymap
	#
	case ${keymap} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keymap';	kbdcontrol < ${kbddev} -l ${keymap}
		;;
	esac

	# keyrate
	#
	case ${keyrate} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keyrate';	kbdcontrol < ${kbddev} -r ${keyrate}
		;;
	esac

	# keybell
	#
	case ${keybell} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keybell';	kbdcontrol < ${kbddev} -b ${keybell}
		;;
	esac

	# change function keys
	#
	case ${keychange} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' keychange'
		set - ${keychange}
		while [ $# -gt 0 ]; do
			kbdcontrol <${kbddev} -f "$1" "$2"
			shift; shift
		done
		;;
	esac

	# set this keyboard mode for all virtual terminals
	#
	if [ -n "${allscreens_kbdflags}" ]; then
		sc_init
		echo -n ' allscreens_kbd'
		for ttyv in /dev/ttyv*; do
			kbdcontrol ${allscreens_kbdflags} < ${ttyv} > ${ttyv} 2>&1
		done
	fi
}

syscons_setkeyboard()
{
	kbd=$1

	if [ -z "${kbd}" ]; then
		return 1
	fi

	# Check if the kbdmux(4) is the current active keyboard
	kbdcontrol -i < ${kbddev} | grep kbdmux > /dev/null 2>&1
	if [ $? -ne 0 ]; then
		kbdcontrol -k ${kbd} < ${kbddev} > /dev/null 2>&1
	fi

	_sc_config="keyboard"
	syscons_configure_keyboard

	# Terminate keyboard configuration line and reset global variables.
	#
	if [ -n "${_sc_initdone}" ]; then
		echo '.'
		_sc_config="syscons"
		_sc_initdone=
	fi

}

syscons_precmd()
{
	if [ ! -c $kbddev ]
	then
		return 1
	fi
	return 0
}

syscons_start()
{
	# keyboard
	#
	if [ -n "${keyboard}" ]; then
		syscons_setkeyboard ${keyboard}
	fi

	syscons_configure_keyboard

	# cursor type
	#
	case ${cursor} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' cursor';	vidcontrol < ${viddev} -c ${cursor}
		;;
	esac

	# screen mapping
	#
	case ${scrnmap} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' scrnmap';	vidcontrol < ${viddev} -l ${scrnmap}
		;;
	esac

	# font 8x16
	#
	case ${font8x16} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' font8x16';	vidcontrol < ${viddev} -f 8x16 ${font8x16}
		;;
	esac

	# font 8x14
	#
	case ${font8x14} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' font8x14';	vidcontrol < ${viddev} -f 8x14 ${font8x14}
		;;
	esac

	# font 8x8
	#
	case ${font8x8} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' font8x8';	vidcontrol < ${viddev} -f 8x8 ${font8x8}
		;;
	esac

	# blank time
	#
	case ${blanktime} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' blanktime';	vidcontrol < ${viddev} -t ${blanktime}
		;;
	esac

	# screen saver
	#
	case ${saver} in
	[Nn][Oo] | '')
		;;
	*)
		sc_init
		echo -n ' screensaver'
		for i in `kldstat | awk '$5 ~ "_saver\.ko$" { print $5 }'`; do
			kldunload ${i}
		done
		load_kld -e _saver ${saver}_saver
		;;
	esac

	# set this mode for all virtual screens
	#
	if [ -n "${allscreens_flags}" ]; then
		sc_init
		echo -n ' allscreens'
		for ttyv in /dev/ttyv*; do
			vidcontrol ${allscreens_flags} < ${ttyv} > ${ttyv} 2>&1
		done
	fi

	[ -n "${_sc_initdone}" ] && echo '.'
}

load_rc_config $name
run_rc_command $*

@


1.24
log
@SVN rev 227366 on 2011-11-08 23:02:32Z by jilles

rc.d: Eliminate some unnecessary non-POSIX constructs:

 * set - ...
 * empty braces
 * ^ in character class
@
text
@d27 1
a27 1
# $FreeBSD$
@


1.23
log
@SVN rev 208060 on 2010-05-14 04:53:57Z by dougb

Remove trailing white space. No functional changes.
@
text
@d102 1
a102 1
		set - ${keychange}
@


1.23.2.1
log
@SVN rev 225736 on 2011-09-23 00:51:37Z by kensmith

Copy head to stable/9 as part of 9.0-RELEASE release cycle.

Approved by:	re (implicit)
@
text
@@


1.23.2.2
log
@## SVN ##
## SVN ## Exported commit - http://svnweb.freebsd.org/changeset/base/ 242902
## SVN ## CVS IS DEPRECATED: http://wiki.freebsd.org/CvsIsDeprecated
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ## r242902 | dteske | 2012-11-11 23:29:45 +0000 (Sun, 11 Nov 2012) | 10 lines
## SVN ##
## SVN ## Fix a regression introduced by SVN r211417 that saw the breakage of a feature
## SVN ## documented in usr.sbin/sysinstall/help/shortcuts.hlp (reproduced below):
## SVN ##
## SVN ## If /usr/sbin/sysinstall is linked to another filename, say
## SVN ## `/usr/local/bin/configPackages', then the basename will be used
## SVN ## as an implicit command name.
## SVN ##
## SVN ## Reviewed by:	adrian (co-mentor)
## SVN ## Approved by:	adrian (co-mentor)
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ##
@
text
@d27 1
a27 1
# $FreeBSD: stable/9/etc/rc.d/syscons 208060 2010-05-14 04:53:57Z dougb $
@


1.23.2.1.4.1
log
@SVN rev 239080 on 2012-08-05 23:54:33Z by kensmith

Copy stable/9 to releng/9.1 as part of the 9.1-RELEASE release process.

Approved by:	re (implicit)
@
text
@@


1.23.2.1.4.2
log
@Switch importer
@
text
@d27 1
a27 1
# $FreeBSD: releng/9.1/etc/rc.d/syscons 208060 2010-05-14 04:53:57Z dougb $
@


1.23.2.1.2.1
log
@SVN rev 227445 on 2011-11-11 04:20:22Z by kensmith

Copy stable/9 to releng/9.0 as part of the FreeBSD 9.0-RELEASE release
cycle.

Approved by:	re (implicit)
@
text
@@


1.23.2.1.2.2
log
@Switch importer
@
text
@d27 1
a27 1
# $FreeBSD: releng/9.0/etc/rc.d/syscons 208060 2010-05-14 04:53:57Z dougb $
@


1.22
log
@SVN rev 179981 on 2008-06-24 21:01:56Z by mtm

Quiet rc.d/syscons unless it has something to say.
@
text
@d124 1
a124 1
                
@


1.22.2.1
log
@SVN rev 196045 on 2009-08-03 08:13:06Z by kensmith

Copy head to stable/8 as part of 8.0 Release cycle.

Approved by:	re (Implicit)
@
text
@@


1.22.2.2
log
@SVN rev 208094 on 2010-05-14 19:28:16Z by dougb

MFC 208060:

Remove trailing white space. No functional changes.
@
text
@d124 1
a124 1

@


1.22.2.3
log
@## SVN ##
## SVN ## Exported commit - http://svnweb.freebsd.org/changeset/base/ 242909
## SVN ## CVS IS DEPRECATED: http://wiki.freebsd.org/CvsIsDeprecated
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ## r242909 | dim | 2012-11-12 07:47:19 +0000 (Mon, 12 Nov 2012) | 20 lines
## SVN ##
## SVN ## MFC r242625:
## SVN ##
## SVN ## Remove duplicate const specifiers in many drivers (I hope I got all of
## SVN ## them, please let me know if not).  Most of these are of the form:
## SVN ##
## SVN ## static const struct bzzt_type {
## SVN ##       [...list of members...]
## SVN ## } const bzzt_devs[] = {
## SVN ##       [...list of initializers...]
## SVN ## };
## SVN ##
## SVN ## The second const is unnecessary, as arrays cannot be modified anyway,
## SVN ## and if the elements are const, the whole thing is const automatically
## SVN ## (e.g. it is placed in .rodata).
## SVN ##
## SVN ## I have verified this does not change the binary output of a full kernel
## SVN ## build (except for build timestamps embedded in the object files).
## SVN ##
## SVN ## Reviewed by:	yongari, marius
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ##
@
text
@d27 1
a27 1
# $FreeBSD: stable/8/etc/rc.d/syscons 208094 2010-05-14 19:28:16Z dougb $
@


1.22.2.2.6.1
log
@SVN rev 232438 on 2012-03-03 06:15:13Z by kensmith

Copy stable/8 to releng/8.3 as part of 8.3-RELEASE release cycle.

Approved by:	re (implicit)
@
text
@@


1.22.2.2.6.2
log
@Switch importer
@
text
@d27 1
a27 1
# $FreeBSD: releng/8.3/etc/rc.d/syscons 208094 2010-05-14 19:28:16Z dougb $
@


1.22.2.2.4.1
log
@SVN rev 216617 on 2010-12-21 17:09:25Z by kensmith

Copy stable/8 to releng/8.2 in preparation for FreeBSD-8.2 release.

Approved by:	re (implicit)
@
text
@@


1.22.2.2.2.1
log
@SVN rev 209145 on 2010-06-14 02:09:06Z by kensmith

Copy stable/8 to releng/8.1 in preparation for 8.1-RC1.

Approved by:	re (implicit)
@
text
@@


1.22.2.1.2.1
log
@SVN rev 198460 on 2009-10-25 01:10:29Z by kensmith

Copy stable/8 to releng/8.0 as part of 8.0-RELEASE release procedure.

Approved by:	re (implicit)
@
text
@@


1.21
log
@Use "-ne" instead of "!=" for integer comparison.
@
text
@d48 10
d67 1
d78 1
d89 1
d100 1
d113 1
d135 1
a135 1
	echo -n 'Configuring keyboard:'
d137 9
a145 1
	echo '.'
a158 2
	echo -n 'Configuring syscons:'

d162 1
a162 1
		echo -n ' keyboard';	syscons_setkeyboard ${keyboard}
d173 1
d184 1
d195 1
d206 1
d217 1
d228 1
d239 1
d251 1
d258 1
a258 1
	echo '.'
@


1.21.2.1
log
@SVN rev 208095 on 2010-05-14 19:36:11Z by dougb

MFC 208060:

Remove trailing white space. No functional changes.

Hand-delete trailing ws from rc.firewall while I'm here.
@
text
@d109 1
a109 1

@


1.21.2.2
log
@Switch importer
@
text
@d27 1
a27 1
# $FreeBSD: stable/7/etc/rc.d/syscons 220110 2011-03-28 19:29:30Z dougb $
@


1.21.2.1.2.1
log
@SVN rev 216618 on 2010-12-21 17:10:29Z by kensmith

Copy stable/7 to releng/7.4 in preparation for FreeBSD-7.4 release.

Approved by:	re (implicit)
@
text
@@


1.21.2.1.2.2
log
@Switch importer
@
text
@d27 1
a27 1
# $FreeBSD: releng/7.4/etc/rc.d/syscons 208095 2010-05-14 19:36:11Z dougb $
@


1.21.10.1
log
@SVN rev 203736 on 2010-02-10 00:26:20Z by kensmith

Copy stable/7 to releng/7.3 as part of the 7.3-RELEASE process.

Approved by:	re (implicit)
@
text
@@


1.21.8.1
log
@SVN rev 191087 on 2009-04-15 03:14:26Z by kensmith

Create releng/7.2 from stable/7 in preparation for 7.2-RELEASE.

Approved by:	re (implicit)
@
text
@@


1.21.6.1
log
@SVN rev 185281 on 2008-11-25 02:59:29Z by kensmith

Create releng/7.1 in preparation for moving into RC phase of 7.1 release
cycle.

Approved by:	re (implicit)
@
text
@@


1.20
log
@Make "/etc/rc.d/syscons start" correctly reload screensaver settings.

The code looks for all the loaded screensaver modules, tries to
kldunload them, and only loads the new one if kldstat's output shows
that there aren't any left.  However, the regexp looking for modules
to unload was still searching according to the the old naming scheme,
splash_<name>.ko, instead of <name>_saver.ko.

MFC after:	3 days
@
text
@d116 1
a116 1
	if [ $? != 0 ]; then
@


1.19
log
@Use $required_modules wherever suitable.  Use load_kld() in special
cases.  So we get rid of quite a few lines of duplicated code.
@
text
@d213 1
a213 1
		for i in `kldstat | awk '$5 ~ "^splash_.*$" { print $5 }'`; do
@


1.18
log
@Syscons cannot be stopped, so provide a no-op stop method.
The default stop method from rc.subr isn't suited for this
case and produces a bogus warning: "syscons not running".

Suggested by:	matteo
@
text
@d216 1
a216 1
		kldstat -v | grep -q _saver || kldload ${saver}_saver
@


1.17
log
@Send the pcvt(4) driver off to retirement.
@
text
@d41 1
@


1.16
log
@Reorganize /etc/rc.d/syscons and move all keyboard related settings
into one function syscons_configure_keyboard(). Call new function from
both syscons_start() and sysconst_setkeyboard(). The reason for this
is because syscons_start() will (re)configure both keyboard and screen
settings. Apparently, some graphics cards have problems with running
vidcontrol(1) while X11 is running.

Remove "/etc/rc.d/syscons restart" from /etc/devd.conf. It is no longer
required. Using "/etc/rc.d/syscons setkeyboard" is enough. This also
should fix annoying "syscons not running?" message.

Tested by:	Ulrich Spoerlein < q at galgenberg dot net >
MFC after:	3 days
@
text
@a129 4
	if [ -x /usr/sbin/ispcvt ] && /usr/sbin/ispcvt
	then
		return 1
	fi
@


1.15
log
@Add new 'setkeyboard' method to the /etc/rc.d/syscons. It accepts the
keyboard device name (i.e. /dev/kbd0). This method will do nothing is
kbdmux(4) is the current active keyboard, otherwise it will switch
active keyboard as requested.

Modify ukbd(4) entries in the /etc/devd.conf to use /etc/rc.d/syscons
and new 'setkeyboard' method.

No comments from:	freebsd-current@@
MFC after:		1 day
@
text
@d47 2
a48 1
syscons_setkeyboard()
a49 36
	kbd=$1
                
	if [ -z "${kbd}" ]; then
		return 1
	fi

	# Check if the kbdmux(4) is the current active keyboard
	kbdcontrol -i < ${kbddev} | grep kbdmux > /dev/null 2>&1
	if [ $? != 0 ]; then
		kbdcontrol -k ${kbd} < ${kbddev} > /dev/null 2>&1
	fi
}

syscons_precmd()
{
	if [ ! -c $kbddev ]
	then
		return 1
	fi
	if [ -x /usr/sbin/ispcvt ] && /usr/sbin/ispcvt
	then
		return 1
	fi
	return 0
}

syscons_start()
{
	echo -n 'Configuring syscons:'

	# keyboard
	#
	if [ -n "${keyboard}" ]; then
		echo -n ' keyboard';	syscons_setkeyboard ${keyboard}
	fi

d95 54
a231 9
	# set this keyboard mode for all virtual terminals
	#
	if [ -n "${allscreens_kbdflags}" ]; then
		echo -n ' allscreens_kbd'
		for ttyv in /dev/ttyv*; do
			kbdcontrol ${allscreens_kbdflags} < ${ttyv} > ${ttyv} 2>&1
		done
	fi

@


1.14
log
@Remove usbd(8) and all references to it. It is no longer necessary
since devd(8) now provides the same functionality.

Submitted by:	Anish Mistry
@
text
@d37 2
d47 15
d82 1
a82 2
		echo -n ' keyboard';	kbdcontrol < ${kbddev} \
		    -k "${keyboard}" >/dev/null
d226 2
a227 1
run_rc_command "$1"
@


1.13
log
@Remove the requirement for the FreeBSD keyword as it no longer
makes any sense.

Discussed with: dougb, brooks
MFC after: 3 days
@
text
@d31 1
a31 1
# REQUIRE: LOGIN usbd
@


1.13.2.1
log
@MFC:

Add new 'setkeyboard' method to the /etc/rc.d/syscons. It accepts the
keyboard device name (i.e. /dev/kbd0). This method will do nothing is
kbdmux(4) is the current active keyboard, otherwise it will switch
active keyboard as requested.

Modify ukbd(4) entries in the /etc/devd.conf to use /etc/rc.d/syscons
and new 'setkeyboard' method.

Approved by:	re (scottl)
@
text
@a36 2
extra_commands="setkeyboard"
setkeyboard_cmd="syscons_setkeyboard"
a44 15
syscons_setkeyboard()
{
	kbd=$1
                
	if [ -z "${kbd}" ]; then
		return 1
	fi

	# Check if the kbdmux(4) is the current active keyboard
	kbdcontrol -i < ${kbddev} | grep kbdmux > /dev/null 2>&1
	if [ $? != 0 ]; then
		kbdcontrol -k ${kbd} < ${kbddev} > /dev/null 2>&1
	fi
}

d65 2
a66 1
		echo -n ' keyboard';	syscons_setkeyboard ${keyboard}
d210 1
a210 2
run_rc_command $*

@


1.13.2.2
log
@MFC:

Reorganize /etc/rc.d/syscons and move all keyboard related settings
into one function syscons_configure_keyboard(). Call new function from
both syscons_start() and sysconst_setkeyboard(). The reason for this
is because syscons_start() will (re)configure both keyboard and screen
settings. Apparently, some graphics cards have problems with running
vidcontrol(1) while X11 is running.

Remove "/etc/rc.d/syscons restart" from /etc/devd.conf. It is no longer
required. Using "/etc/rc.d/syscons setkeyboard" is enough. This also
should fix annoying "syscons not running?" message.

Tested by:	Ulrich Spoerlein < q at galgenberg dot net >
Approved by:	re (hrs)
@
text
@d47 1
a47 2
# helper
syscons_configure_keyboard()
d49 36
a129 54
	# set this keyboard mode for all virtual terminals
	#
	if [ -n "${allscreens_kbdflags}" ]; then
		echo -n ' allscreens_kbd'
		for ttyv in /dev/ttyv*; do
			kbdcontrol ${allscreens_kbdflags} < ${ttyv} > ${ttyv} 2>&1
		done
	fi
}

syscons_setkeyboard()
{
	kbd=$1
                
	if [ -z "${kbd}" ]; then
		return 1
	fi

	# Check if the kbdmux(4) is the current active keyboard
	kbdcontrol -i < ${kbddev} | grep kbdmux > /dev/null 2>&1
	if [ $? != 0 ]; then
		kbdcontrol -k ${kbd} < ${kbddev} > /dev/null 2>&1
	fi

	echo -n 'Configuring keyboard:'
	syscons_configure_keyboard
	echo '.'
}

syscons_precmd()
{
	if [ ! -c $kbddev ]
	then
		return 1
	fi
	if [ -x /usr/sbin/ispcvt ] && /usr/sbin/ispcvt
	then
		return 1
	fi
	return 0
}

syscons_start()
{
	echo -n 'Configuring syscons:'

	# keyboard
	#
	if [ -n "${keyboard}" ]; then
		echo -n ' keyboard';	syscons_setkeyboard ${keyboard}
	fi

	syscons_configure_keyboard

d213 9
@


1.13.2.3
log
@MFC rev. 1.18:

Syscons cannot be stopped, so provide a no-op stop method.
The default stop method from rc.subr isn't suited for this
case and produces a bogus warning: "syscons not running".
@
text
@a40 1
stop_cmd=":"
@


1.13.2.4
log
@MFC r1.20:
  The code looks for all the loaded screensaver modules, tries to
  kldunload them, and only loads the new one if kldstat's output shows
  that there aren't any left.  However, the regexp looking for modules
  to unload was still searching according to the the old naming scheme,
  splash_<name>.ko, instead of <name>_saver.ko.
@
text
@d217 1
a217 1
		for i in `kldstat | awk '$5 ~ "_saver\.ko$" { print $5 }'`; do
@


1.13.2.5
log
@SVN rev 208096 on 2010-05-14 19:57:18Z by dougb

MFC 208060:

Remove trailing white space. No functional changes.

Hand-delete trailing ws from rc.subr, rc.d/nsswitch, and rc.d/nfslocking
while I'm here.
@
text
@d109 1
a109 1

@


1.13.2.6
log
@Switch importer
@
text
@d27 1
a27 1
# $FreeBSD: stable/6/etc/rc.d/syscons 208096 2010-05-14 19:57:18Z dougb $
@


1.13.2.4.4.1
log
@SVN rev 183531 on 2008-10-02 02:57:24Z by kensmith

Create releng/6.4 from stable/6 in preparation for 6.4-RC1.

Approved by:	re (implicit)
@
text
@@


1.12
log
@Allow setting the system console keyboard via the ${keyboard} rc.conf
directive.
@
text
@d32 1
a32 1
# KEYWORD: FreeBSD nojail
@


1.12.2.1
log
@RCS file: /home/ncvs/src/etc/rc,v
----------------------------
revision 1.335
date: 2004/10/08 14:23:49;  author: mtm;  state: Exp;  lines: +0 -1
Remove an unused variable.

Submitted by: Pawel Worach <pawel.worach@@telia.com>
----------------------------
revision 1.334
date: 2004/10/07 13:55:25;  author: mtm;  state: Exp;  lines: +1 -1
Remove the requirement for the FreeBSD keyword as it no longer
makes any sense.

Discussed with: dougb, brooks
MFC after: 3 days
=============================================================================
RCS file: /home/ncvs/src/etc/rc.d/nsswitch,v
----------------------------
revision 1.4
date: 2004/09/16 17:03:12;  author: keramida;  state: Exp;  lines: +1 -1
Fix requirement of `network' to `NETWORK' because the former isn't
provided by any rc.d script.

Approved by:	mtm
=============================================================================
RCS file: /home/ncvs/src/etc/rc.d/pflog,v
----------------------------
revision 1.3
date: 2004/09/16 17:04:20;  author: keramida;  state: Exp;  lines: +1 -1
We don't have any providers of `beforenetlkm' in FreeBSD.  Remove the
dependency to it from our rc.d scripts.

Approved by:	mtm
=============================================================================

Approved by: re/scottl
@
text
@d32 1
a32 1
# KEYWORD: nojail
@


1.11
log
@Mark scripts as not usable inside a jail by adding keyword 'nojail'.

Some suggestions from:	rwatson, Ruben de Groot <mail25@@bzerk.org>
@
text
@d62 7
@


1.10
log
@Change rc.d/syscons to not need /usr/sbin/ispcvt to exist.  This should
make it work for all non-i386 syscons platforms.
@
text
@d32 1
a32 1
# KEYWORD: FreeBSD
@


1.9
log
@Fix syscons so it actually does start.

Reported by:	keramida, ume
Submitted by:	keramida
@
text
@d47 1
a47 3
	if [ -c $kbddev ] && \
	   [ -x /usr/sbin/ispcvt ] && \
	   ! /usr/sbin/ispcvt
d49 1
a49 1
		return 0
d51 5
a55 1
	return 1
@


1.8
log
@Only try to initialize syscons if /dev/ttyv0 exists and it's not a pcvt.
@
text
@a38 1
load_rc_config $name
d199 3
@


1.7
log
@Anonymize the "portmap" program to get better compatibility with
rpcbind in -current.

Submitted by:   Alexander Kabaev <ak03@@gte.com>
@
text
@d37 2
d46 151
a196 1
echo -n 'Configuring syscons:'
d198 2
a199 138
# keymap
#
case ${keymap} in
[Nn][Oo] | '')
	;;
*)
	echo -n ' keymap';	kbdcontrol < ${kbddev} -l ${keymap}
	;;
esac

# keyrate
#
case ${keyrate} in
[Nn][Oo] | '')
	;;
*)
	echo -n ' keyrate';	kbdcontrol < ${kbddev} -r ${keyrate}
	;;
esac

# keybell
#
case ${keybell} in
[Nn][Oo] | '')
	;;
*)
	echo -n ' keybell';	kbdcontrol < ${kbddev} -b ${keybell}
	;;
esac

# change function keys
#
case ${keychange} in
[Nn][Oo] | '')
	;;
*)
	echo -n ' keychange'
	set - ${keychange}
	while [ $# -gt 0 ]; do
		kbdcontrol <${kbddev} -f "$1" "$2"
		shift; shift
	done
	;;
esac

# cursor type
#
case ${cursor} in
[Nn][Oo] | '')
	;;
*)
	echo -n ' cursor';	vidcontrol < ${viddev} -c ${cursor}
	;;
esac

# screen mapping
#
case ${scrnmap} in
[Nn][Oo] | '')
	;;
*)
	echo -n ' scrnmap';	vidcontrol < ${viddev} -l ${scrnmap}
	;;
esac

# font 8x16
#
case ${font8x16} in
[Nn][Oo] | '')
        ;;
*)
	echo -n ' font8x16';	vidcontrol < ${viddev} -f 8x16 ${font8x16}
	;;
esac

# font 8x14
#
case ${font8x14} in
[Nn][Oo] | '')
        ;;
*)
	echo -n ' font8x14';	vidcontrol < ${viddev} -f 8x14 ${font8x14}
	;;
esac

# font 8x8
#
case ${font8x8} in
[Nn][Oo] | '')
        ;;
*)
	echo -n ' font8x8';	vidcontrol < ${viddev} -f 8x8 ${font8x8}
	;;
esac

# blank time
#
case ${blanktime} in
[Nn][Oo] | '')
        ;;
*)
	echo -n ' blanktime';	vidcontrol < ${viddev} -t ${blanktime}
	;;
esac

# screen saver
#
case ${saver} in
[Nn][Oo] | '')
        ;;
*)
	echo -n ' screensaver'
	for i in `kldstat | awk '$5 ~ "^splash_.*$" { print $5 }'`; do
		kldunload ${i}
	done
	kldstat -v | grep -q _saver || kldload ${saver}_saver
	;;
esac

# set this mode for all virtual screens
#
if [ -n "${allscreens_flags}" ]; then
	echo -n ' allscreens'
	for ttyv in /dev/ttyv*; do
		vidcontrol ${allscreens_flags} < ${ttyv} > ${ttyv} 2>&1
	done
fi

# set this keyboard mode for all virtual terminals
#
if [ -n "${allscreens_kbdflags}" ]; then
	echo -n ' allscreens_kbd'
	for ttyv in /dev/ttyv*; do
		kbdcontrol ${allscreens_kbdflags} < ${ttyv} > ${ttyv} 2>&1
	done
fi

echo '.'
@


1.6
log
@Merge in all the changes that Mike Makonnen has been maintaining for a
while. This is only the script pieces, the glue for the build comes next.

Submitted by:   Mike Makonnen <makonnen@@pacbell.net>
Reviewed by:    silence on -current and -hackers
Prodded by:     rwatson
@
text
@d182 2
@


1.5
log
@Make the 'echo' output for blanktime and scrnmap consistent with their
variable names.  There were minor differences in both cases, which were
needlessly confusing and inconsistent.
@
text
@d27 1
a27 2
# $FreeBSD: src/etc/rc.syscons,v 1.4 2001/08/09 15:36:03 obrien Exp $
#	Do syscons configuration
d30 9
a164 17
# mouse daemon
#
case ${moused_enable} in
[Yy][Ee][Ss])
	echo -n ' moused'
	moused ${moused_flags} -p ${moused_port} -t ${moused_type}
	case ${mousechar_start} in
	[Nn][Oo] | '')
		;;
	*)
		echo -n ' mousechar_start';  vidcontrol < ${viddev} -M ${mousechar_start}
		;;
	esac
	vidcontrol < ${viddev} -m on
	;;
esac

a181 2

echo '.'
@


1.4
log
@Fix minor typo.
@
text
@d27 1
a27 1
# $FreeBSD: src/etc/rc.syscons,v 1.3 2001/04/28 20:56:52 dd Exp $
d99 1
a99 1
	echo -n ' screen_map';	vidcontrol < ${viddev} -l ${scrnmap}
d139 1
a139 1
	echo -n ' blank_time';	vidcontrol < ${viddev} -t ${blanktime}
@


1.3
log
@Add an allscreens_kbdflags option.  Same thing as allscreens_flags,
but runs kbdcontrol instead of vidcontrol.

Reviewed by:	ru
@
text
@d27 1
a27 1
# $FreeBSD: src/etc/rc.syscons,v 1.2 2001/04/19 14:53:43 ache Exp $
d183 1
a183 1
# set this keyboard more for all virtual terminals
@


1.2
log
@Add mousechar_start hook

Reviewed by:	Nick Hibma <n_hibma@@qubesoft.com>
@
text
@d27 1
a27 1
# $FreeBSD: src/etc/rc.syscons,v 1.1 2001/01/09 22:28:17 jhb Exp $
d180 9
@


1.1
log
@Move the syscons configuration to a machine independent rc.syscons.  The
syscons sh code was identical on both platforms except for whitespace
differences.
@
text
@d27 1
a27 1
# $FreeBSD$
d163 7
@


1.1.2.1
log
@MFC: Move the syscons configuration to a machine independent rc.syscons.
@
text
@d27 1
a27 1
# $FreeBSD: src/etc/rc.syscons,v 1.1 2001/01/09 22:28:17 jhb Exp $
@


1.1.2.2
log
@MFC: mousechar_start and allscreens_kbdflags
@
text
@d27 1
a27 1
# $FreeBSD: src/etc/rc.syscons,v 1.1.2.1 2001/02/27 20:03:28 jhb Exp $
a162 7
	case ${mousechar_start} in
	[Nn][Oo] | '')
		;;
	*)
		echo -n ' mousechar_start';  vidcontrol < ${viddev} -M ${mousechar_start}
		;;
	esac
a172 9
	done
fi

# set this keyboard more for all virtual terminals
#
if [ -n "${allscreens_kbdflags}" ]; then
	echo -n ' allscreens_kbd'
	for ttyv in /dev/ttyv*; do
		kbdcontrol ${allscreens_kbdflags} < ${ttyv} > ${ttyv} 2>&1
@


1.1.2.3
log
@MFC 1.5: make echo output for blanktime and scrnmap consistent with
their variable names.
@
text
@d27 1
a27 1
# $FreeBSD$
d99 1
a99 1
	echo -n ' scrnmap';	vidcontrol < ${viddev} -l ${scrnmap}
d139 1
a139 1
	echo -n ' blanktime';	vidcontrol < ${viddev} -t ${blanktime}
@


1.1.2.4
log
@MFC en masse. Several of the included changes are mine, however we've
gotten pretty far out of synch with -current over the last year or so,
this catches us up for everything that makes sense.

There are several whitespace only changes here. In an ideal world I
would have had time to seperate them out, however I did not. Most of
them are included to be consistent with -current, some of them are
"improvements" that happened while I was adding things back.

Of particular note:
/var/log/auth.log
/var/run and /var/spool cleanup in rc
Early and late rc.sysctl runs
New mailq/queurun support in daily scripts
@
text
@d183 1
a183 1
# set this keyboard mode for all virtual terminals
@


