qcacmn: skip MEC ast entry creation in wlan fw

MEC ast entry will be created only in software
and adding MEC entry to wlan fw is skipped.

Change-Id: I6991f9f12ceb22a7c599cdf3cc2a13c996d93671
Этот коммит содержится в:
Nitin Shetty
2021-01-22 13:37:46 +05:30
коммит произвёл snandini
родитель b06c25ee09
Коммит 71e3244d46
7 изменённых файлов: 529 добавлений и 130 удалений

Просмотреть файл

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2016-2020 The Linux Foundation. All rights reserved.
* Copyright (c) 2016-2021 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -24,6 +24,9 @@
#define DP_INVALID_PEER_ID 0xffff
#define DP_PEER_MAX_MEC_IDX 1024 /* maximum index for MEC table */
#define DP_PEER_MAX_MEC_ENTRY 4096 /* maximum MEC entries in MEC table */
#define DP_FW_PEER_STATS_CMP_TIMEOUT_MSEC 5000
#define dp_peer_alert(params...) QDF_TRACE_FATAL(QDF_MODULE_ID_DP_PEER, params)
@@ -601,6 +604,59 @@ void dp_peer_unlink_ast_entry(struct dp_soc *soc,
struct dp_ast_entry *ast_entry,
struct dp_peer *peer);
/**
* dp_peer_mec_detach_entry() - Detach the MEC entry
* @soc: SoC handle
* @mecentry: MEC entry of the node
* @ptr: pointer to free list
*
* The MEC entry is detached from MEC table and added to free_list
* to free the object outside lock
*
* Return: None
*/
void dp_peer_mec_detach_entry(struct dp_soc *soc, struct dp_mec_entry *mecentry,
void *ptr);
/**
* dp_peer_mec_free_list() - free the MEC entry from free_list
* @soc: SoC handle
* @ptr: pointer to free list
*
* Return: None
*/
void dp_peer_mec_free_list(struct dp_soc *soc, void *ptr);
/**
* dp_peer_mec_add_entry()
* @soc: SoC handle
* @vdev: vdev to which mec node belongs
* @mac_addr: MAC address of mec node
*
* This function allocates and adds MEC entry to MEC table.
* It assumes caller has taken the mec lock to protect the access to these
* tables
*
* Return: QDF_STATUS
*/
QDF_STATUS dp_peer_mec_add_entry(struct dp_soc *soc,
struct dp_vdev *vdev,
uint8_t *mac_addr);
/**
* dp_peer_mec_hash_find_by_pdevid() - Find MEC entry by MAC address
* within pdev
* @soc: SoC handle
*
* It assumes caller has taken the mec_lock to protect the access to
* MEC hash table
*
* Return: MEC entry
*/
struct dp_mec_entry *dp_peer_mec_hash_find_by_pdevid(struct dp_soc *soc,
uint8_t pdev_id,
uint8_t *mec_mac_addr);
#define DP_AST_ASSERT(_condition) \
do { \
if (!(_condition)) { \
@@ -850,4 +906,42 @@ static inline void dp_peer_delete_ast_entries(struct dp_soc *soc,
{
}
#endif
#ifdef FEATURE_MEC
/**
* dp_peer_mec_spinlock_create() - Create the MEC spinlock
* @soc: SoC handle
*
* Return: none
*/
void dp_peer_mec_spinlock_create(struct dp_soc *soc);
/**
* dp_peer_mec_spinlock_destroy() - Destroy the MEC spinlock
* @soc: SoC handle
*
* Return: none
*/
void dp_peer_mec_spinlock_destroy(struct dp_soc *soc);
/**
* dp_peer_mec_flush_entries() - Delete all mec entries in table
* @soc: Datapath SOC
*
* Return: None
*/
void dp_peer_mec_flush_entries(struct dp_soc *soc);
#else
static inline void dp_peer_mec_spinlock_create(struct dp_soc *soc)
{
}
static inline void dp_peer_mec_spinlock_destroy(struct dp_soc *soc)
{
}
static inline void dp_peer_mec_flush_entries(struct dp_soc *soc)
{
}
#endif
#endif /* _DP_PEER_H_ */