3
## Provided by Mkarcher at http://www.thinkwiki.org/wiki/Script_for_configuring_the_CS4239_sound_chip_in_PnP_mode
4
## Modified by Daniel T Chen for Debian/Ubuntu, redistributable
5
## under GPLv2 or later
7
for dev in /sys/bus/pnp/devices/*
9
grep CSC0100 $dev/id > /dev/null && WSSDEV=$dev
10
grep CSC0110 $dev/id > /dev/null && CTLDEV=$dev
13
echo activate > $WSSDEV/resources
14
echo activate > $CTLDEV/resources
23
# Hack: with PnPBIOS: ports are: port1: WSS, port2: OPL, port3: sb (unneeded)
24
# with ACPI-PnP:ports are: port1: OPL, port2: sb, port3: WSS
25
# (ACPI bios seems to be wrong here, the PnP-card-code in snd-cs4236.c uses the
27
# Detect port order using the fixed OPL port as reference
28
if [ ${port2%%-*} = 0x388 ]
30
# PnPBIOS: usual order
34
# ACPI: mixed-up order
45
modprobe snd-cs4236 port=$port cport=$cport fm_port=$oplport irq=$irq dma1=$dma1 dma2=$dma2 isapnp=0