diff --git a/core/mac/src/pe/lim/lim_process_action_frame.c b/core/mac/src/pe/lim/lim_process_action_frame.c index 3af5b2e04f8f..f5d319e62853 100644 --- a/core/mac/src/pe/lim/lim_process_action_frame.c +++ b/core/mac/src/pe/lim/lim_process_action_frame.c @@ -1510,7 +1510,7 @@ static void lim_process_addba_req(struct mac_context *mac_ctx, uint8_t *rx_pkt_i session, addba_req->addba_extn_element.present, addba_req->addba_param_set.amsdu_supp, - mac_hdr->fc.wep); + mac_hdr->fc.wep, buff_size); if (qdf_status != QDF_STATUS_SUCCESS) { pe_err("Failed to send addba response frame"); cdp_addba_resp_tx_completion( diff --git a/core/mac/src/pe/lim/lim_send_management_frames.c b/core/mac/src/pe/lim/lim_send_management_frames.c index 06e3345b6f37..a42eed93d0bf 100644 --- a/core/mac/src/pe/lim/lim_send_management_frames.c +++ b/core/mac/src/pe/lim/lim_send_management_frames.c @@ -5319,7 +5319,7 @@ returnAfterError: QDF_STATUS lim_send_addba_response_frame(struct mac_context *mac_ctx, tSirMacAddr peer_mac, uint16_t tid, struct pe_session *session, uint8_t addba_extn_present, - uint8_t amsdu_support, uint8_t is_wep) + uint8_t amsdu_support, uint8_t is_wep, uint16_t calc_buff_size) { tDot11faddba_rsp frm; @@ -5363,7 +5363,9 @@ QDF_STATUS lim_send_addba_response_frame(struct mac_context *mac_ctx, if (sta_ds && lim_is_session_he_capable(session)) he_cap = lim_is_sta_he_capable(sta_ds); - if (he_cap) + if (sta_ds && sta_ds->staType == STA_ENTRY_NDI_PEER) + frm.addba_param_set.buff_size = calc_buff_size; + else if (he_cap) frm.addba_param_set.buff_size = MAX_BA_BUFF_SIZE; else frm.addba_param_set.buff_size = SIR_MAC_BA_DEFAULT_BUFF_SIZE; diff --git a/core/mac/src/pe/lim/lim_types.h b/core/mac/src/pe/lim/lim_types.h index 3b2f44821e06..c7265930407e 100644 --- a/core/mac/src/pe/lim/lim_types.h +++ b/core/mac/src/pe/lim/lim_types.h @@ -1232,6 +1232,7 @@ typedef enum sHalBitVal /* For Bit operations */ * @addba_extn_present: ADDBA extension present flag * @amsdu_support: amsdu in ampdu support * @is_wep: protected bit in fc + * @calc_buff_size: Calculated buf size from peer and self capabilities * * This function is called when ADDBA request is successful. ADDBA response is * setup by calling addba_response_setup API and frame is then sent out OTA. @@ -1242,7 +1243,8 @@ QDF_STATUS lim_send_addba_response_frame(struct mac_context *mac_ctx, tSirMacAddr peer_mac, uint16_t tid, struct pe_session *session, uint8_t addba_extn_present, - uint8_t amsdu_support, uint8_t is_wep); + uint8_t amsdu_support, uint8_t is_wep, + uint16_t calc_buff_size); /** * lim_send_delba_action_frame() - Send delba to peer