Search Linux Wireless

[PATCH] mac80211: make 802.1X setting consistent with low-level driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



If the low-level driver fails to reconfigure 802.1X we currently still
set the variable. Don't do that since it brings things out of sync.

Signed-off-by: Johannes Berg <johannes@xxxxxxxxxxxxxxxx>

---
 net/mac80211/ieee80211_ioctl.c |    9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

--- wireless-dev.orig/net/mac80211/ieee80211_ioctl.c	2007-03-27 16:33:44.363155480 +0200
+++ wireless-dev/net/mac80211/ieee80211_ioctl.c	2007-03-27 16:33:44.943155480 +0200
@@ -2478,11 +2478,14 @@ static int ieee80211_ioctl_prism2_param(
 		break;
 
 	case PRISM2_PARAM_IEEE_802_1X:
-		sdata->ieee802_1x = value;
-		if (local->ops->set_ieee8021x &&
-		    local->ops->set_ieee8021x(local_to_hw(local), value))
+		if (local->ops->set_ieee8021x)
+			ret = local->ops->set_ieee8021x(local_to_hw(local),
+							value);
+		if (ret)
 			printk(KERN_DEBUG "%s: failed to set IEEE 802.1X (%d) "
 			       "for low-level driver\n", dev->name, value);
+		else
+			sdata->ieee802_1x = value;
 		break;
 
 	case PRISM2_PARAM_ANTSEL_TX:


-
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux