]> git.pld-linux.org Git - packages/em8300.git/blame - em8300.init
- added depmod options so modules can be installed for kernel other than running
[packages/em8300.git] / em8300.init
CommitLineData
471aa9be 1#!/bin/sh
2#
cee4c9bb 3# chkconfig: 2345 11 89
4# description: loads em8300 modules and uploads microcode
471aa9be 5
6if [ ! -f /etc/sysconfig/em8300 ] ; then
7 exit 0
8fi
9
10# Source function library.
11. /etc/rc.d/init.d/functions
12
13. /etc/sysconfig/em8300
14
cee4c9bb 15load_module () { run_cmd "$(nls 'Loading module') $1" modprobe "$*"; }
471aa9be 16
17# See how we were called.
18case "$1" in
19 start)
20 is_yes "$BT_LOAD" && load_module bt865 $BT_OPT
21 load_module adv717x $ADV_OPT
22 load_module em8300 $EM_OPT
b694188b 23 run_cmd "Uploading em8300 microcode" "sh -c 'em8300_microcode_upload 2>/dev/null'"
471aa9be 24 ;;
25 stop)
cee4c9bb 26 run_cmd "Removing em8300 modules" "sh -c 'rmmod em8300 adv717x bt865 2>/dev/null'"
471aa9be 27 ;;
cee4c9bb 28 status)
29 ;;
30 restart|reload)
471aa9be 31 $0 stop
32 $0 start
33 ;;
34 *)
cee4c9bb 35 msg_usage "$0 {start|stop|restart|reload|status}"
471aa9be 36 exit 1
37esac
38
39exit 0
This page took 0.146904 seconds and 4 git commands to generate.