]>
Commit | Line | Data |
---|---|---|
99f3c72f MT |
1 | #!/bin/sh |
2 | # Begin $rc_base/init.d/alsa | |
3 | ||
4 | # Based on sysklogd script from LFS-3.1 and earlier. | |
5 | # Rewritten by Gerard Beekmans - gerard@linuxfromscratch.org | |
6 | # ALSA specific parts by Mark Hymers - markh@linuxfromscratch.org | |
7 | # Stores mixer settings in the default location: /etc/asound.state | |
8 | ||
9 | . /etc/sysconfig/rc | |
10 | . $rc_functions | |
11 | ||
12 | case "$1" in | |
51f3b7f5 | 13 | start) |
cdfc1e52 | 14 | boot_mesg "Starting ALSA... Restoring volumes..." |
51f3b7f5 MT |
15 | modprobe snd_pcm_oss >/dev/null 2>&1 || failed=1 |
16 | modprobe snd_mixer_oss >/dev/null 2>&1 || failed=1 | |
17 | (exit ${failed}) | |
18 | evaluate_retval | |
cdfc1e52 | 19 | loadproc /usr/sbin/alsactl restore |
51f3b7f5 | 20 | ;; |
99f3c72f MT |
21 | stop) |
22 | boot_mesg "Stopping ALSA... Saving volumes..." | |
23 | loadproc /usr/sbin/alsactl store | |
24 | ;; | |
25 | ||
26 | *) | |
51f3b7f5 | 27 | echo "Usage: $0 (start|stop)" |
99f3c72f MT |
28 | exit 1 |
29 | ;; | |
30 | esac | |
31 | ||
32 | # End $rc_base/init.d/alsa |