[PC-BSD Commits] r20086 - in pcbsd/branches/9.1/overlays/desktop-overlay: boot etc usr/local/share/pcbsd/scripts
svn at pcbsd.org
svn at pcbsd.org
Tue Oct 30 09:03:14 PDT 2012
Author: kris
Date: 2012-10-30 16:03:14 +0000 (Tue, 30 Oct 2012)
New Revision: 20086
Modified:
pcbsd/branches/9.1/overlays/desktop-overlay/boot/beastie.4th
pcbsd/branches/9.1/overlays/desktop-overlay/boot/loader.conf
pcbsd/branches/9.1/overlays/desktop-overlay/etc/devd.conf
pcbsd/branches/9.1/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh
Log:
MFC some files to 9.1, including sound-device, loader.conf and splash issues
Modified: pcbsd/branches/9.1/overlays/desktop-overlay/boot/beastie.4th
===================================================================
--- pcbsd/branches/9.1/overlays/desktop-overlay/boot/beastie.4th 2012-10-30 16:01:50 UTC (rev 20085)
+++ pcbsd/branches/9.1/overlays/desktop-overlay/boot/beastie.4th 2012-10-30 16:03:14 UTC (rev 20086)
@@ -607,13 +607,6 @@
s" 0" s" hint.acpi.0.disabled" setenv
then
current-safe @ if
- s" arch-i386" environment? if
- drop
- s" acpi_load" unsetenv
- s" 1" s" hint.acpi.0.disabled" setenv
- s" 1" s" loader.acpi_disabled_by_user" setenv
- s" 1" s" hint.apic.0.disabled" setenv
- then
s" 0" s" hw.ata.ata_dma" setenv
s" 0" s" hw.ata.atapi_dma" setenv
s" 0" s" hw.ata.wc" setenv
Modified: pcbsd/branches/9.1/overlays/desktop-overlay/boot/loader.conf
===================================================================
--- pcbsd/branches/9.1/overlays/desktop-overlay/boot/loader.conf 2012-10-30 16:01:50 UTC (rev 20085)
+++ pcbsd/branches/9.1/overlays/desktop-overlay/boot/loader.conf 2012-10-30 16:03:14 UTC (rev 20086)
@@ -41,9 +41,9 @@
beastie_theme="/boot/themes/default/theme.conf"
# Load splash screen
-splash_pcx_load="YES"
-bitmap_load="YES"
-bitmap_name="/boot/loading-screen.pcx"
+#splash_pcx_load="YES"
+#bitmap_load="YES"
+#bitmap_name="/boot/loading-screen.pcx"
# Speed up boot
kern.cam.scsi_delay="500"
Modified: pcbsd/branches/9.1/overlays/desktop-overlay/etc/devd.conf
===================================================================
--- pcbsd/branches/9.1/overlays/desktop-overlay/etc/devd.conf 2012-10-30 16:01:50 UTC (rev 20085)
+++ pcbsd/branches/9.1/overlays/desktop-overlay/etc/devd.conf 2012-10-30 16:03:14 UTC (rev 20086)
@@ -269,7 +269,7 @@
match "subsystem" "CDEV";
match "type" "CREATE";
match "cdev" "mixer[0-9]+";
- action "/usr/local/share/pcbsd/scripts/sound-dev-changed.sh add";
+ action "/usr/local/share/pcbsd/scripts/sound-dev-changed.sh add $cdev";
};
notify 15 {
@@ -277,7 +277,7 @@
match "subsystem" "CDEV";
match "type" "DESTROY";
match "cdev" "mixer[0-9]+";
- action "/usr/local/share/pcbsd/scripts/sound-dev-changed.sh del";
+ action "/usr/local/share/pcbsd/scripts/sound-dev-changed.sh del $cdev";
};
notify 5 {
Modified: pcbsd/branches/9.1/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh
===================================================================
--- pcbsd/branches/9.1/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh 2012-10-30 16:01:50 UTC (rev 20085)
+++ pcbsd/branches/9.1/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh 2012-10-30 16:03:14 UTC (rev 20086)
@@ -2,6 +2,7 @@
# Action can be add / del
action=$1
+cdev=$2
regen_ossconf()
{
@@ -15,6 +16,7 @@
PCM=`egrep -o 'pcm[0-9]+' /dev/sndstat | egrep -o '[0-9]+'`
OSSCONF=`cat <<EOF
# pcm-oss plugin configuration
+# generated by ${0}
pcm.oss {
type oss
@@ -68,10 +70,17 @@
return
fi
- # Get the last pcm device so we can make it the default
- newDev=`cat /dev/sndstat | grep play | egrep -o 'pcm[0-9]+' | tail -n 1`
- dNum=`echo $newDev | sed 's|pcm||g'`
- sysctl hw.snd.default_unit=$dNum
+ mixerNum=`echo ${cdev} | egrep -o '[0-9]+'`
+
+ # Can new dev play?
+ cat /dev/sndstat | grep pcm${mixerNum} | grep -q play
+ if [ $? -ne 0 ] ; then
+ return
+ fi
+
+ # make new device the default one
+ sysctl hw.snd.default_unit=$mixerNum
+
}
# Update device based upon action
More information about the Commits
mailing list