mwifiex: update IEs after AP has started
authorAvinash Patil <patila@marvell.com>
Wed, 28 Jan 2015 10:24:18 +0000 (15:54 +0530)
committerKalle Valo <kvalo@codeaurora.org>
Thu, 29 Jan 2015 08:21:57 +0000 (10:21 +0200)
This patch moves IE management routine to end of start_ap handler.
IEs now would be updated after AP has started.

Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Qingshui Gao <gaoqs@marvell.com>
Signed-off-by: Cathy Luo <cluo@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/mwifiex/cfg80211.c

index 8e07564735279dabdb8fe337aedf6fad804b9320..ceeaeac45007b0c7c75409137e6f92086c77e02a 100644 (file)
@@ -1681,8 +1681,6 @@ static int mwifiex_cfg80211_start_ap(struct wiphy *wiphy,
 
        if (GET_BSS_ROLE(priv) != MWIFIEX_BSS_ROLE_UAP)
                return -1;
-       if (mwifiex_set_mgmt_ies(priv, &params->beacon))
-               return -1;
 
        bss_cfg = kzalloc(sizeof(struct mwifiex_uap_bss_param), GFP_KERNEL);
        if (!bss_cfg)
@@ -1783,6 +1781,9 @@ static int mwifiex_cfg80211_start_ap(struct wiphy *wiphy,
                return -1;
        }
 
+       if (mwifiex_set_mgmt_ies(priv, &params->beacon))
+               return -1;
+
        memcpy(&priv->bss_cfg, bss_cfg, sizeof(priv->bss_cfg));
        kfree(bss_cfg);