]> git.ipfire.org Git - ipfire-2.x.git/blame - src/rc.d/rc.pulsardsl
Ein NTFS-Update fuer den Heiner :D
[ipfire-2.x.git] / src / rc.d / rc.pulsardsl
CommitLineData
cd1a2927
MT
1#!/bin/bash
2#
3# $Id: rc.pulsardsl,v 1.3.2.8 2005/07/07 20:11:58 franck78 Exp $
4#
5
6eval $(/usr/local/bin/readhash CONFIG_ROOT/ppp/settings)
7
8# Debugging. Comment it out to stop logging
9DEBUG="yes"
10msg() {
11 if [ "z$DEBUG" != "z" ] ; then
12 /usr/bin/logger -t red "Pulsar DSL: $*"
13 fi
14 echo "$*"
15}
16
17# See how we were called.
18case "$1" in
19 start)
20 if ( ! /sbin/lsmod | /bin/grep -q pulsar ); then
21 /sbin/modprobe pulsar
22 if [ $? -ne 0 ]; then
23 msg "Pulsar loading failed"
24 exit 2
25 else
26 # arbitrary fixed time until the driver support a way to know that the modem is synchronised
27 /bin/sleep 60
28 fi
29 fi
30 exit 0
31 ;;
32stop)
33 msg "stop"
34 ;;
35cleanup)
36 msg "driver cleanup"
37 /sbin/modprobe -r pulsar
38 ;;
39 *)
40 echo "Usage: $0 {start|stop|cleanup}"
41 exit 1
42 ;;
43esac
44
45exit 0