qcacmn: Add CDP API to set key in data path

1. Add CDP API to set encryption key in datapath.
   Used to perform RX TKIP demic.
2. Fixes to RX TKIP demic function.

Change-Id: Ia14caeb71a320b4746f4303cf6611f1b6e4947ae
CRs-Fixed: 2214749
This commit is contained in:
Pramod Simha
2018-06-20 12:05:44 -07:00
committed by nshrivas
vanhempi 366c1e01e6
commit 6e10cb2dd6
7 muutettua tiedostoa jossa 130 lisäystä ja 69 poistoa

Näytä tiedosto

@@ -2378,3 +2378,18 @@ void dp_peer_rxtid_stats(struct dp_peer *peer, void (*dp_stats_cmd_cb),
}
}
void dp_set_michael_key(struct cdp_peer *peer_handle,
bool is_unicast, uint32_t *key)
{
struct dp_peer *peer = (struct dp_peer *)peer_handle;
uint8_t sec_index = is_unicast ? 1 : 0;
if (!peer) {
QDF_TRACE(QDF_MODULE_ID_TXRX, QDF_TRACE_LEVEL_ERROR,
"peer not found ");
return;
}
qdf_mem_copy(&peer->security[sec_index].michael_key[0],
key, IEEE80211_WEP_MICLEN);
}