Date: Sun, 23 Dec 2001 18:15:22 -0600 (CST) From: "Douglas K. Rand" <rand@meridian-enviro.com> To: FreeBSD-gnats-submit@freebsd.org Subject: misc/33132: Patch to handle otherscreens similiar to allscreens Message-ID: <200112240015.fBO0FMm86298@delta.meridian-enviro.com>
next in thread | raw e-mail | index | archive | help
>Number: 33132 >Category: misc >Synopsis: Patch to handle otherscreens similiar to allscreens >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sun Dec 23 16:20:00 PST 2001 >Closed-Date: >Last-Modified: >Originator: Douglas K. Rand >Release: FreeBSD 4.4-RELEASE i386 >Organization: Meridian Environmental Technology, Inc. >Environment: System: FreeBSD delta.meridian-enviro.com 4.4-RELEASE FreeBSD 4.4-RELEASE #10: Fri Oct 26 17:21:08 CDT 2001 bryanh@delta.meridian-enviro.com:/usr/obj/usr/src/sys/DELTA i386 >Description: The allscreens_flags is very nice for changing the default syscons mode. The one thing I dislike about it is that it clears the screen. This patch doesn't preserve the screen contents, it just introduces a new /etc/defaults/rc.conf knob called otherscreens_flags that affects all screens /except/ ttyv0. We use this in /etc/rc.local, but I thought others might enjoy it. The ttyv? devices other than ttyv0 are changed with the otherscreens_flags knob, this preserves the contents of the boot screen, which I find useful. I can then use the other screens at other modes, say 132x60. >How-To-Repeat: Have a boot problem, especially with a RC script, and try to debug it when allscreens_flags clears the screen on you. :) >Fix: Here is a patch to /etc/rc.syscons: --- rc.syscons.orig Sun Dec 23 18:01:52 2001 +++ rc.syscons Sun Dec 23 18:07:03 2001 @@ -180,12 +180,36 @@ done fi +# set this mode for all virtual screens except for ttyv0 +# +if [ -n "${otherscreens_flags}" ]; then + echo -n ' otherscreens' + for ttyv in /dev/ttyv*; do + case ${ttyv} in + /dev/ttyv0) + ;; + *) + vidcontrol ${otherscreens_flags} < ${ttyv} > ${ttyv} 2>&1 + ;; + esac + 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 + done +fi + +# set this keyboard more for all virtual terminals except for ttyv0 +# +if [ -n "${otherscreens_kbdflags}" ]; then + echo -n ' otherscreens_kbd' + for ttyv in /dev/ttyv*; do + kbdcontrol ${otherscreens_kbdflags} < ${ttyv} > ${ttyv} 2>&1 done fi >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200112240015.fBO0FMm86298>