Skip to content
Snippets Groups Projects
Commit 8183d10d authored by Felix Fietkau's avatar Felix Fietkau
Browse files

check for sysfs before bypassing normal hotplug calls for firmware events (fixes #5200)

SVN-Revision: 17839
parent ed17f327
No related branches found
No related tags found
No related merge requests found
......@@ -5,7 +5,7 @@ export HOTPLUG_TYPE="$1"
# bypass the normal hotplug path for firmware loading
# would otherwise cause problems with drivers like bcm43xx
[ "firmware" = "$HOTPLUG_TYPE" -a "add" = "$ACTION" ] && {
[ -d /sys/firmware -a "firmware" = "$HOTPLUG_TYPE" -a "add" = "$ACTION" ] && {
[ -f "/lib/firmware/$FIRMWARE" ] && {
echo 1 > "/sys$DEVPATH/loading"
cp "/lib/firmware/$FIRMWARE" "/sys$DEVPATH/data"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment