qcacmn: add CDP reason code support for send_delba

Add CDP reason code support for sending DELBA request,
so protocol layer can make decisions for special cases.

Change-Id: I4e4b2e7f7232a8ab12d4c7838f97908f481dc787
CRs-Fixed: 2983553
This commit is contained in:
Vevek Venkatesan
2021-06-30 17:02:15 +05:30
committed by Madan Koyyalamudi
parent 98a3fceeb3
commit 723721e67f
3 changed files with 22 additions and 5 deletions

View File

@@ -59,6 +59,17 @@ enum cdp_nac_param_cmd {
CDP_NAC_PARAM_LIST,
};
#define CDP_DELBA_INTERVAL_MS 3000
/**
* enum cdp_delba_rcode - CDP reason code for sending DELBA
* @CDP_DELBA_REASON_NONE: None
* @CDP_DELBA_2K_JUMP: Sending DELBA from 2k_jump_handle
*/
enum cdp_delba_rcode {
CDP_DELBA_REASON_NONE = 0,
CDP_DELBA_2K_JUMP,
};
/**
* enum vdev_peer_protocol_enter_exit - whether ingress or egress
* @CDP_VDEV_PEER_PROTOCOL_IS_INGRESS: ingress
@@ -1099,12 +1110,14 @@ struct ol_if_ops {
* @vdev_id: dp vdev id
* @peer_macaddr: Peer mac addr
* @tid: Tid number
* @reason_code: Reason code
* @cdp_rcode: CDP reason code for sending DELBA
*
* Return: 0 for success, non-zero for failure
*/
int (*send_delba)(struct cdp_ctrl_objmgr_psoc *psoc, uint8_t vdev_id,
uint8_t *peer_macaddr, uint8_t tid,
uint8_t reason_code);
uint8_t reason_code, uint8_t cdp_rcode);
int
(*peer_delete_multiple_wds_entries)(struct cdp_ctrl_objmgr_psoc *psoc,

View File

@@ -3434,7 +3434,8 @@ static void dp_teardown_256_ba_sessions(struct dp_peer *peer)
peer->vdev->pdev->soc->ctrl_psoc,
peer->vdev->vdev_id,
peer->mac_addr.raw,
tid, delba_rcode);
tid, delba_rcode,
CDP_DELBA_REASON_NONE);
} else {
qdf_spin_unlock_bh(&rx_tid->tid_lock);
}
@@ -3853,7 +3854,8 @@ int dp_delba_tx_completion_wifi3(struct cdp_soc_t *cdp_soc, uint8_t *peer_mac,
peer->vdev->pdev->soc->ctrl_psoc,
peer->vdev->vdev_id,
peer->mac_addr.raw, tid,
rx_tid->delba_rcode);
rx_tid->delba_rcode,
CDP_DELBA_REASON_NONE);
}
goto end;
} else {
@@ -4225,7 +4227,8 @@ dp_rx_delba_ind_handler(void *soc_handle, uint16_t peer_id,
peer->vdev->vdev_id,
peer->mac_addr.raw,
tid,
rx_tid->delba_rcode);
rx_tid->delba_rcode,
CDP_DELBA_REASON_NONE);
}
} else {
dp_peer_err("%pK: BA session is not setup for TID:%d ", soc, tid);

View File

@@ -1059,7 +1059,8 @@ dp_2k_jump_handle(struct dp_soc *soc,
peer->vdev->vdev_id,
peer->mac_addr.raw,
tid,
rx_tid->delba_rcode);
rx_tid->delba_rcode,
CDP_DELBA_2K_JUMP);
}
} else {
qdf_spin_unlock_bh(&rx_tid->tid_lock);