mwifiex: configure p2p interface during initialization
authorBing Zhao <bzhao@marvell.com>
Sat, 20 Apr 2013 00:44:41 +0000 (17:44 -0700)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 22 Apr 2013 19:20:27 +0000 (15:20 -0400)
Send P2P_MODE_CFG cmd to firmware when p2p interface is created.
Without proper p2p configuration firmware may behave incorrectly
while handling commands sent through this interface.

Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: Stone Piao <piaoyun@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/mwifiex/cfg80211.c

index 8c468c30b2d9a298718f2926443f494a6694c357..2a604eb0fd1dd450eab944260193b1683c8caca2 100644 (file)
@@ -2152,6 +2152,9 @@ struct wireless_dev *mwifiex_add_virtual_intf(struct wiphy *wiphy,
                priv->bss_started = 0;
                priv->bss_num = 0;
 
+               if (mwifiex_cfg80211_init_p2p_client(priv))
+                       return ERR_PTR(-EFAULT);
+
                break;
        default:
                wiphy_err(wiphy, "type not supported\n");