Skip to contentSkip to conversation

prism54: correct assignment of DOT1XENABLE in WE-19 codepaths

PATCH In review Dan Williams 2 participants 5 messages Feb 13, 2007 Networking drivers (wireless)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 prism54: correct assignment of DOT1XENABLE in WE-19 codepaths

Correct assignment of DOT1XENABLE in WE-19 codepaths. RX_UNENCRYPTED_EAPOL = 1 really means setting DOT1XENABLE _off_, and vice versa. The original WE-19 patch erroneously reversed that. This patch fixes association with unencrypted and WEP networks when using wpa_supplicant.

It also adds two missing break statements that, left out, could result in incorrect card configuration.

Please commit to both development and stable branches.

drivers/net/wireless/prism54/isl_ioctl.c +7 -1
index 838d510..a5396c1 100644
@@ -1395,11 +1395,16 @@ static int prism54_set_auth(struct net_device *ndev,
 		break;
 
 	case IW_AUTH_RX_UNENCRYPTED_EAPOL:
-		dot1x = param->value ? 1 : 0;
+		/* dot1x should be the opposite of RX_UNENCRYPTED_EAPOL;
+		 * turn off dot1x when allowing receipt of unencrypted EAPOL
+		 * frames, turn on dot1x when receipt should be disallowed
+		 */
+		dot1x = param->value ? 0 : 0x01;
 		break;
 
 	case IW_AUTH_PRIVACY_INVOKED:
 		privinvoked = param->value ? 1 : 0;
+		break;
 
 	case IW_AUTH_DROP_UNENCRYPTED:
 		exunencrypt = param->value ? 1 : 0;
@@ -1589,6 +1594,7 @@ static int prism54_set_encodeext(struct net_device *ndev,
 			}
 			key.type = DOT11_PRIV_TKIP;
 			key.length = KEY_SIZE_TKIP;
+			break;
 		default:
 			return -EINVAL;
 		}
maintainer
#1 lore raw
Quoted 10 lines · Dan Williams

Correct assignment of DOT1XENABLE in WE-19 codepaths. RX_UNENCRYPTED_EAPOL = 1 really means setting DOT1XENABLE _off_, and vice versa. The original WE-19 patch erroneously reversed that. This patch fixes association with unencrypted and WEP networks when using wpa_supplicant.

It also adds two missing break statements that, left out, could result in incorrect card configuration.

Please commit to both development and stable branches.

I guess it could also be applicable for stable?

johannes

#2 lore raw
Quoted 11 lines · Johannes Berg
Quoted 10 lines · Dan Williams

Correct assignment of DOT1XENABLE in WE-19 codepaths. RX_UNENCRYPTED_EAPOL = 1 really means setting DOT1XENABLE _off_, and vice versa. The original WE-19 patch erroneously reversed that. This patch fixes association with unencrypted and WEP networks when using wpa_supplicant.

It also adds two missing break statements that, left out, could result in incorrect card configuration.

Please commit to both development and stable branches.

                                          ^^^^^

Right; applicable to anything after _and_ including 2.6.19, which is when I think the WE-19 patch landed.

Dan

Quoted 4 lines

I guess it could also be applicable for stable?

johannes

maintainer
#3 lore raw
Quoted 11 lines · Dan Williams
Quoted 10 lines · Johannes Berg
Quoted 9 lines · Dan Williams

Correct assignment of DOT1XENABLE in WE-19 codepaths. RX_UNENCRYPTED_EAPOL = 1 really means setting DOT1XENABLE _off_, and vice versa. The original WE-19 patch erroneously reversed that. This patch fixes association with unencrypted and WEP networks when using wpa_supplicant.

It also adds two missing break statements that, left out, could result in incorrect card configuration.

Quoted 6 lines
Quoted 1 line
Quoted 1 line

Please commit to both development and stable branches.

                                          ^^^^^

Right; applicable to anything after _and_ including 2.6.19, which is when I think the WE-19 patch landed.

But I think John will take it to mean to apply it to wireless-dev and wireless-2.6 so you should send it to [email protected]

johannes

#4 lore raw
Quoted 14 lines · Johannes Berg
Quoted 13 lines · Dan Williams
Quoted 11 lines · Johannes Berg
Quoted 10 lines · Dan Williams

Correct assignment of DOT1XENABLE in WE-19 codepaths. RX_UNENCRYPTED_EAPOL = 1 really means setting DOT1XENABLE _off_, and vice versa. The original WE-19 patch erroneously reversed that. This patch fixes association with unencrypted and WEP networks when using wpa_supplicant.

It also adds two missing break statements that, left out, could result in incorrect card configuration.

Please commit to both development and stable branches.

Quoted 7 lines
Quoted 4 lines
                                          ^^^^^

Right; applicable to anything after _and_ including 2.6.19, which is when I think the WE-19 patch landed.

But I think John will take it to mean to apply it to wireless-dev and wireless-2.6 so you should send it to [email protected]

Aha; ok. Will do.

Dan