summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/mwifiex/cfg80211.c
diff options
context:
space:
mode:
authorAvinash Patil2012-05-09 03:30:26 +0200
committerJohn W. Linville2012-05-16 18:46:36 +0200
commitf752dcd52923b8de82881cf1269f0dc03dbd1088 (patch)
tree261d4fa07221e2074f24e83aa941b2b2991f42ee /drivers/net/wireless/mwifiex/cfg80211.c
parentmwifiex: add AP event handling framework (diff)
downloadkernel-qcow2-linux-f752dcd52923b8de82881cf1269f0dc03dbd1088.tar.gz
kernel-qcow2-linux-f752dcd52923b8de82881cf1269f0dc03dbd1088.tar.xz
kernel-qcow2-linux-f752dcd52923b8de82881cf1269f0dc03dbd1088.zip
mwifiex: add WPA2 support for AP
1. Support for parsing security related parameters from cfg80211_ap_settings in start_ap cfg80211 handler 2. Conversion of these security information into FW understandle TLVs and setting into FW thru sys_config command 3. key management is done on host. This ensures that FW forwards EAPOL key packets to host instead of processing on its own. Signed-off-by: Avinash Patil <patila@marvell.com> Signed-off-by: Kiran Divekar <dkiran@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/mwifiex/cfg80211.c')
-rw-r--r--drivers/net/wireless/mwifiex/cfg80211.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/net/wireless/mwifiex/cfg80211.c b/drivers/net/wireless/mwifiex/cfg80211.c
index e7882e56950d..6c343218d9f0 100644
--- a/drivers/net/wireless/mwifiex/cfg80211.c
+++ b/drivers/net/wireless/mwifiex/cfg80211.c
@@ -950,6 +950,9 @@ static int mwifiex_cfg80211_start_ap(struct wiphy *wiphy,
struct mwifiex_uap_bss_param *bss_cfg;
struct mwifiex_private *priv = mwifiex_netdev_get_priv(dev);
+ if (priv->bss_type != MWIFIEX_BSS_TYPE_UAP)
+ return -1;
+
bss_cfg = kzalloc(sizeof(struct mwifiex_uap_bss_param), GFP_KERNEL);
if (!bss_cfg)
return -ENOMEM;
@@ -966,6 +969,12 @@ static int mwifiex_cfg80211_start_ap(struct wiphy *wiphy,
bss_cfg->ssid.ssid_len = params->ssid_len;
}
+ if (mwifiex_set_secure_params(priv, bss_cfg, params)) {
+ kfree(bss_cfg);
+ wiphy_err(wiphy, "Failed to parse secuirty parameters!\n");
+ return -1;
+ }
+
if (mwifiex_send_cmd_sync(priv, HostCmd_CMD_UAP_BSS_STOP,
HostCmd_ACT_GEN_SET, 0, NULL)) {
wiphy_err(wiphy, "Failed to stop the BSS\n");