Skip to content

Commit

Permalink
libertas: fix WPA adhoc network creation
Browse files Browse the repository at this point in the history
Oddly enough, the firmware's JOIN/START commands don't appear to have
any facility for setting custom IEs, thus the started adhoc network
doesn't advertise its WPA capability in the beacon.  Whee!

Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Dan Williams authored and John W. Linville committed Jun 3, 2009
1 parent 822ac03 commit 2fa7a98
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions drivers/net/wireless/libertas/assoc.c
Original file line number Diff line number Diff line change
Expand Up @@ -711,11 +711,13 @@ static int lbs_adhoc_start(struct lbs_private *priv,

/* set capability info */
tmpcap = WLAN_CAPABILITY_IBSS;
if (assoc_req->secinfo.wep_enabled) {
lbs_deb_join("ADHOC_START: WEP enabled, setting privacy on\n");
if (assoc_req->secinfo.wep_enabled ||
assoc_req->secinfo.WPAenabled ||
assoc_req->secinfo.WPA2enabled) {
lbs_deb_join("ADHOC_START: WEP/WPA enabled, privacy on\n");
tmpcap |= WLAN_CAPABILITY_PRIVACY;
} else
lbs_deb_join("ADHOC_START: WEP disabled, setting privacy off\n");
lbs_deb_join("ADHOC_START: WEP disabled, privacy off\n");

cmd.capability = cpu_to_le16(tmpcap);

Expand Down

0 comments on commit 2fa7a98

Please sign in to comment.