wireless-tools: do ifconfig down before the ifconfig up is done.
authorMike Westerhof <mwester@dls.net>
Fri, 20 Mar 2009 03:32:00 +0000 (22:32 -0500)
committerMike Westerhof <mwester@dls.net>
Fri, 20 Mar 2009 03:32:00 +0000 (22:32 -0500)
Required to reliably re-initialize the interface if it was running previously.

recipes/wireless-tools/wireless-tools/zzz-wireless.if-pre-up
recipes/wireless-tools/wireless-tools_29.bb

index 85fcc87..29a2663 100644 (file)
@@ -18,6 +18,8 @@ SLEEPTIME=1
 ONLY_FOR="dhcp"
 
 if [ -z "$IF_WIRELESS_TYPE" ] && echo "$ONLY_FOR" | grep -q "$METHOD" ; then
+       $IFCONFIG $IFACE down
+       $SLEEP 1
        $IFCONFIG $IFACE up
        $LOGGER Checking for WLAN association...
        while ( [ $RETRIES -gt 0 ] && ($IWCONFIG "$IFACE" | $GREP -q "Access Point: Not-Associated") ); do