]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
If wpa_supplicant is not running when rebinding, start it for
authorRoy Marples <roy@marples.name>
Fri, 7 Jun 2013 20:51:44 +0000 (20:51 +0000)
committerRoy Marples <roy@marples.name>
Fri, 7 Jun 2013 20:51:44 +0000 (20:51 +0000)
wireless interfaces.

dhcpcd-hooks/10-wpa_supplicant
dhcpcd.8.in

index 18c889f2fef38c8b87aeb30c44862b6bd5000963..af429d00601fb60cfe5eac2f68600f85b8592222 100644 (file)
@@ -1,4 +1,4 @@
-# Start and stop wpa_supplicant per wireless interface.
+# Start, reconfigure and stop wpa_supplicant per wireless interface.
 # This is needed because wpa_supplicant lacks hotplugging of any kind
 # and the user should not be expected to have to wire it into their system
 # if the base system doesn't do this itself.
@@ -24,7 +24,10 @@ wpa_supplicant_reconfigure()
 {
        local err errn
 
-       wpa_cli -i "$interface" status >/dev/null 2>&1 || return 0
+       if ! wpa_cli -i "$interface" status >/dev/null 2>&1; then
+               wpa_supplicant_start
+               return $?
+       fi
        syslog info "reconfiguring wpa_supplicant"
        err=$(wpa_cli -i"$interface" reconfigure 2>&1)
        errn=$?
index 355277d1e55e7287e2e93b5c3212d55d2492d330..c9011425f34df493476f71b6699893c18a499463 100644 (file)
@@ -329,6 +329,9 @@ to reload its configuration and rebind its interfaces.
 If
 .Nm
 is not running, then it starts up as normal.
+This may also cause
+.Xr wpa_supplicant 8
+to reload its configuration for each interface as well.
 .It Fl o , Fl Fl option Ar option
 Request the DHCP
 .Ar option