#!/bin/sh
########################################################################
# Begin sshd
#
# Description : Store alsa settings at shutdown
#
# Author      : Bruce Dubbs - bdubbs@linuxfromscratch.org
#
# Version     : LFS 7.0
#
########################################################################

### BEGIN INIT INFO
# Provides:            alsa
# Required-Start:      
# Should-Start:
# Required-Stop:       sendsignals
# Should-Stop:
# Default-Start:       
# Default-Stop:        0 1 6
# Short-Description:   Stores alsa mixer settings.
# Description:         Stores mixer settings in the default location: /etc/asound.state.
# X-LFS-Provided-By:   LFS
### END INIT INFO

. /lib/lsb/init-functions

#$LastChangedBy: bdubbs $
#$Date: 2011-12-13 20:22:21 +0000 (Tue, 13 Dec 2011) $

case "$1" in
   stop)
      log_info_msg "Stopping ALSA...    Saving volumes..."
      /usr/sbin/alsactl store
      evaluate_retval
      ;;

   *)
      echo "Usage: $0 stop"
      exit 1
      ;;
esac

# End /etc/init.d/alsa
