qcacmn: Add API to fetch ast entry by mac and ast type

Add API to fetch ast entry by mac and ast type

Change-Id: Ib8cfa5c269fd10c149804d02fcfae35e88c2a53f
CRs-Fixed: 3614965
This commit is contained in:
Neha Bisht
2023-09-14 12:59:44 +05:30
committed by Rahul Choudhary
父節點 77cbd24eb2
當前提交 2e13c17be4
共有 3 個文件被更改,包括 56 次插入1 次删除

查看文件

@@ -1289,6 +1289,33 @@ struct dp_ast_entry *dp_peer_ast_hash_find_soc(struct dp_soc *soc,
return NULL;
}
struct dp_ast_entry *dp_peer_ast_hash_find_soc_by_type(
struct dp_soc *soc,
uint8_t *ast_mac_addr,
enum cdp_txrx_ast_entry_type type)
{
union dp_align_mac_addr local_mac_addr_aligned, *mac_addr;
unsigned index;
struct dp_ast_entry *ase;
if (!soc->ast_hash.bins)
return NULL;
qdf_mem_copy(&local_mac_addr_aligned.raw[0],
ast_mac_addr, QDF_MAC_ADDR_SIZE);
mac_addr = &local_mac_addr_aligned;
index = dp_peer_ast_hash_index(soc, mac_addr);
TAILQ_FOREACH(ase, &soc->ast_hash.bins[index], hash_list_elem) {
if (dp_peer_find_mac_addr_cmp(mac_addr, &ase->mac_addr) == 0 &&
ase->type == type) {
return ase;
}
}
return NULL;
}
/**
* dp_peer_map_ipa_evt() - Send peer map event to IPA
* @soc: SoC handle
@@ -2164,6 +2191,14 @@ struct dp_ast_entry *dp_peer_ast_hash_find_soc(struct dp_soc *soc,
return NULL;
}
struct dp_ast_entry *dp_peer_ast_hash_find_soc_by_type(
struct dp_soc *soc,
uint8_t *ast_mac_addr,
enum cdp_txrx_ast_entry_type type)
{
return NULL;
}
static inline
QDF_STATUS dp_peer_host_add_map_ast(struct dp_soc *soc, uint16_t peer_id,
uint8_t *mac_addr, uint16_t hw_peer_id,