summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Kaiser <martin@kaiser.cx>2022-06-02 21:37:21 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-06-06 08:08:35 +0200
commitc5727d76ca0cf84d1d8b4fd7bb28920a4d440c11 (patch)
tree91c5dd5bb9e8c84d3a4dd9be240294aafd549722
parentc67eea0c34101ba199e500c825edf0a080cdfd45 (diff)
staging: r8188eu: use mgmt to set the delba reason code
Use the mgmt struct to set the delba reason code. Replace the numeric value with a define and remove the temporary variable. Tested-by: Pavel Skripkin <paskripkin@gmail.com> Signed-off-by: Martin Kaiser <martin@kaiser.cx> Link: https://lore.kernel.org/r/20220602193726.280922-7-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/r8188eu/core/rtw_mlme_ext.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/staging/r8188eu/core/rtw_mlme_ext.c b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
index 55e347bb9a6a..dd9f7f2b36ef 100644
--- a/drivers/staging/r8188eu/core/rtw_mlme_ext.c
+++ b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
@@ -5367,7 +5367,6 @@ void issue_action_BA(struct adapter *padapter, unsigned char *raddr, unsigned ch
{
u16 start_seq;
u16 BA_para_set;
- u16 reason_code;
__le16 le_tmp;
u16 BA_starting_seqctrl = 0;
struct xmit_frame *pmgntframe;
@@ -5457,9 +5456,8 @@ void issue_action_BA(struct adapter *padapter, unsigned char *raddr, unsigned ch
le_tmp = cpu_to_le16(BA_para_set);
pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)&le_tmp, &pattrib->pktlen);
- reason_code = 37;/* Requested from peer STA as it does not want to use the mechanism */
- le_tmp = cpu_to_le16(reason_code);
- pframe = rtw_set_fixed_ie(pframe, 2, (unsigned char *)&le_tmp, &pattrib->pktlen);
+ mgmt->u.action.u.delba.reason_code = cpu_to_le16(WLAN_STATUS_REQUEST_DECLINED);
+ pattrib->pktlen += 2;
break;
default:
break;