1 From 52393e2ae12f18fb1a60578c24c46ebab292ddb6 Mon Sep 17 00:00:00 2001
2 From: Rameshkumar Sundaram <quic_ramess@quicinc.com>
3 Date: Mon, 28 Mar 2022 13:21:04 +0530
4 Subject: [PATCH] ath11k: Revert: clear the keys properly when DISABLE_KEY
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
9 Reverting the Upstream clear key change added as a part of
10 436a4e886598 ("ath11k: clear the keys properly
12 This change exposed a race in WLAN Firmware where target asserts
13 are seen frequently due FW not synchronizing ath11k host’s clear
14 key commands(CIPHER changes to NONE) with frames in TX queue.
15 Hence reverting this change untill FW fixes to synchronize
16 ath11k host’s clear key command are available.
18 Signed-off-by: Rameshkumar Sundaram <quic_ramess@quicinc.com>
20 drivers/net/wireless/ath/ath11k/mac.c | 4 +++-
21 drivers/net/wireless/ath/ath11k/wmi.c | 3 +--
22 2 files changed, 4 insertions(+), 3 deletions(-)
24 --- a/drivers/net/wireless/ath/ath11k/mac.c
25 +++ b/drivers/net/wireless/ath/ath11k/mac.c
26 @@ -4232,7 +4232,9 @@ static int ath11k_install_key(struct ath
29 if (cmd == DISABLE_KEY) {
30 - arg.key_cipher = WMI_CIPHER_NONE;
31 + /* TODO: Check if FW expects value other than NONE for del */
32 + /* arg.key_cipher = WMI_CIPHER_NONE; */
37 --- a/drivers/net/wireless/ath/ath11k/wmi.c
38 +++ b/drivers/net/wireless/ath/ath11k/wmi.c
39 @@ -1854,8 +1854,7 @@ int ath11k_wmi_vdev_install_key(struct a
40 tlv = (struct wmi_tlv *)(skb->data + sizeof(*cmd));
41 tlv->header = FIELD_PREP(WMI_TLV_TAG, WMI_TAG_ARRAY_BYTE) |
42 FIELD_PREP(WMI_TLV_LEN, key_len_aligned);
44 - memcpy(tlv->value, (u8 *)arg->key_data, key_len_aligned);
45 + memcpy(tlv->value, (u8 *)arg->key_data, key_len_aligned);
47 ret = ath11k_wmi_cmd_send(wmi, skb, WMI_VDEV_INSTALL_KEY_CMDID);