misc/101268: [patch] /etc/rc.d/mixer should obey mixer_enable
rc.conf(5) variable
Eugene Grosbein
eugen at grosbein.pp.ru
Wed Aug 2 15:50:25 UTC 2006
>Number: 101268
>Category: misc
>Synopsis: [patch] /etc/rc.d/mixer should obey mixer_enable rc.conf(5) variable
>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: Wed Aug 02 15:50:13 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: Eugene Grosbein
>Release: FreeBSD 6.1-STABLE i386
>Organization:
Svyaz Service JSC
>Environment:
System: FreeBSD grosbein.pp.ru 6.1-STABLE FreeBSD 6.1-STABLE #5: Tue Jul 25 20:15:31 KRAST 2006 eu at grosbein.pp.ru:/mnt/tmp/obj/usr/local/src/sys/DADV i386
i975XBX motherboard with onboard Intel HDA (azalia)
>Description:
There is no way to prevent /etc/rc.d/mixer from working
when it sees /dev/mixer* device nodes. However, there may be
reasons to disable it. For example, i975XBX onboard audio is
currently not supported by sound(4) audio device infrastructure.
One can use OSS drivers to make it work but /usr/sbin/mixer
used by /etc/rc.d/mixer cannot work with OSS's /dev/mixer* nodes.
Hence, /etc/rc.d/mixer issues lots of errors while running
and should be disabled.
>How-To-Repeat:
Boot FreeBSD 6.1 using i975XBX motherboard,
install and activate OSS driver for onboard audio.
/etc/rc.d/mixer will see /dev/mixer* devices at shutdown time
and will try to work with them (hopelessly).
The following patch introduces the "mixer_enable" rc.conf(5)
variable that defaults to the value "YES". One may use
mixer_enable="NO" to disable stock mixer management
and use compatible version, if any.
>Fix:
--- src/etc/rc.d/mixer.orig Fri Feb 17 19:30:14 2006
+++ src/etc/rc.d/mixer Wed Aug 2 23:27:23 2006
@@ -38,6 +38,7 @@
start_cmd="mixer_start"
reload_cmd="mixer_start"
extra_commands="reload"
+: ${mixer_enable:=YES}
#
# List current mixer devices to stdout.
@@ -81,6 +82,7 @@
{
local mixer
+ checkyesno mixer_enable || return
for mixer in `list_mixers`; do
mixer_restore ${mixer}
done
@@ -93,6 +95,7 @@
{
local mixer
+ checkyesno mixer_enable || return
for mixer in `list_mixers`; do
mixer_save ${mixer}
done
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-bugs
mailing list