]> git.pld-linux.org Git - packages/afbinit.git/commitdiff
- added actions: force-reload, status (obligatory), try-restart (optional)
authorJakub Bogusz <qboosh@pld-linux.org>
Fri, 8 Feb 2008 18:08:31 +0000 (18:08 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
- binary will always exist (packaged with script)
- fixed exit code returning

Changed files:
    afbinit.init -> 1.2

afbinit.init

index eea34ece773df2970d365df3c2c5ad6eed67b6b4..ec8d974ccffe9fd735122355bda1c8c58413bcb9 100644 (file)
@@ -17,17 +17,11 @@ LOADER=/usr/sbin/afbinit
 ARCH=$(uname -m)
 # If this is not sparc64, get out of here.
 if [ "$ARCH" != "sparc64" ]; then
-        echo "$ARCH cannot have AFB"
-        return 1
-fi
-       
-# The microcode loader binary and the microcode
-# itself must exist.
-if [ ! -x $LOADER ]; then
-       echo "Missing afbinit"
+       echo "$ARCH cannot have AFB"
        return 1
 fi
        
+# The microcode must exist.
 if [ ! -f $UCODE ]; then
        echo "Missing microcode"
        return 1
@@ -52,14 +46,19 @@ start()
        done
 }
 
+RETVAL=0
 case "$1" in
-       start|restart|reload)
+       start|restart|try-restart|reload|force-reload)
                start
                ;;
        stop)
                ;;
+       status)
+               echo "AFB devices present: $afb_devs"
+               ;;
        *)
-               msg_usage "$0 {start|stop|restart|reload}"
+               msg_usage "$0 {start|stop|restart|try-restart|reload|force-reload}"
                exit 3
                ;;
 esac
+exit $RETVAL
This page took 0.084173 seconds and 4 git commands to generate.