mwifiex: simplify ad hoc join capability info
authorJames Cameron <quozl@laptop.org>
Tue, 11 Nov 2014 05:21:28 +0000 (16:21 +1100)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 11 Nov 2014 21:31:16 +0000 (16:31 -0500)
While preparing an ad-hoc start command, the capability info bitmap is
needlessly set from the command, and then the ESS bit cleared.

Change to set the bitmap directly without reference to the command.

Signed-off-by: James Cameron <quozl@laptop.org>
Acked-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/mwifiex/join.c

index 8d6c259..411a6c2 100644 (file)
@@ -880,9 +880,7 @@ mwifiex_cmd_802_11_ad_hoc_start(struct mwifiex_private *priv,
 
        /* Set Capability info */
        bss_desc->cap_info_bitmap |= WLAN_CAPABILITY_IBSS;
-       tmp_cap = le16_to_cpu(adhoc_start->cap_info_bitmap);
-       tmp_cap &= ~WLAN_CAPABILITY_ESS;
-       tmp_cap |= WLAN_CAPABILITY_IBSS;
+       tmp_cap = WLAN_CAPABILITY_IBSS;
 
        /* Set up privacy in bss_desc */
        if (priv->sec_info.encryption_mode) {