add firmware loading support to hotplug
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Thu, 5 Jan 2006 01:20:44 +0000 (01:20 +0000)
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Thu, 5 Jan 2006 01:20:44 +0000 (01:20 +0000)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@2834 3c298f89-4303-0410-b956-a3cf2f4a3e73

openwrt/package/base-files/default/sbin/hotplug

index e53b2af..3500f75 100755 (executable)
@@ -1,4 +1,13 @@
 #!/bin/sh
+[ "$1" = "firmware" -a "$ACTION" = "add" ] && {
+       [ -f "/lib/firmware/$FIRMWARE" ] && {
+               echo 1 > "/sys$DEVPATH/loading"
+               cp "/lib/firmware/$FIRMWARE" "/sys$DEVPATH/data"
+               echo 0 > "/sys$DEVPATH/loading"
+       }
+       exit 0
+}
+
 [ -e /tmp/.failsafe ] && {
        export FAILSAFE=true
 } || {
This page took 0.023483 seconds and 4 git commands to generate.