summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/iwmc3200wifi/commands.c
diff options
context:
space:
mode:
authorSamuel Ortiz <sameo@linux.intel.com>2009-11-25 00:02:26 +0100
committerJohn W. Linville <linville@tuxdriver.com>2009-11-28 15:05:06 -0500
commit9bf22f2c4607dbb68beb26153d83fa52b82e2d2f (patch)
tree13336c0aa86248f4608f15b597d5a09b7dbab1d2 /drivers/net/wireless/iwmc3200wifi/commands.c
parent2944b2c2d2dd884c550163c698577132588277d8 (diff)
iwmc3200wifi: Implement cfg80211 PMKSA API
We need to implement the PMKSA API for proper WPA2 pre-auth and fast re-association. Our fullmac device generates all (re-)assoc IEs, and thus it needs the right PMKIDs. With this implementation we now get them from wpa_supplicant. Signed-off-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwmc3200wifi/commands.c')
-rw-r--r--drivers/net/wireless/iwmc3200wifi/commands.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwmc3200wifi/commands.c b/drivers/net/wireless/iwmc3200wifi/commands.c
index 46ca7c58f5ac..bd0630755b32 100644
--- a/drivers/net/wireless/iwmc3200wifi/commands.c
+++ b/drivers/net/wireless/iwmc3200wifi/commands.c
@@ -960,3 +960,25 @@ int iwm_send_umac_stop_resume_tx(struct iwm_priv *iwm,
sizeof(struct iwm_umac_cmd_stop_resume_tx));
}
+
+int iwm_send_pmkid_update(struct iwm_priv *iwm,
+ struct cfg80211_pmksa *pmksa, u32 command)
+{
+ struct iwm_umac_pmkid_update update;
+ int ret;
+
+ memset(&update, 0, sizeof(struct iwm_umac_pmkid_update));
+
+ update.command = cpu_to_le32(command);
+ memcpy(&update.bssid, pmksa->bssid, ETH_ALEN);
+ memcpy(&update.pmkid, pmksa->pmkid, WLAN_PMKID_LEN);
+
+ ret = iwm_send_wifi_if_cmd(iwm, &update,
+ sizeof(struct iwm_umac_pmkid_update), 0);
+ if (ret) {
+ IWM_ERR(iwm, "PMKID update command failed\n");
+ return ret;
+ }
+
+ return 0;
+}