qcacmn: initialize PPE rings
Changes to initialize PPE rings based on ini configuration Change-Id: Id6a26b557c45fd78ae17675b0292424e979958ad
This commit is contained in:

gecommit door
Madan Koyyalamudi

bovenliggende
d5006a849b
commit
0702aaf463
@@ -405,6 +405,18 @@
|
||||
#define WLAN_CFG_RADIO_DEFAULT_REO_MIN 0x1
|
||||
#define WLAN_CFG_RADIO_DEFAULT_REO_MAX 0x4
|
||||
|
||||
#define WLAN_CFG_REO2PPE_RING_SIZE 1024
|
||||
#define WLAN_CFG_REO2PPE_RING_SIZE_MIN 64
|
||||
#define WLAN_CFG_REO2PPE_RING_SIZE_MAX 1024
|
||||
|
||||
#define WLAN_CFG_PPE2TCL_RING_SIZE 1024
|
||||
#define WLAN_CFG_PPE2TCL_RING_SIZE_MIN 64
|
||||
#define WLAN_CFG_PPE2TCL_RING_SIZE_MAX 1024
|
||||
|
||||
#define WLAN_CFG_PPE_RELEASE_RING_SIZE 1024
|
||||
#define WLAN_CFG_PPE_RELEASE_RING_SIZE_MIN 64
|
||||
#define WLAN_CFG_PPE_RELEASE_RING_SIZE_MAX 1024
|
||||
|
||||
/* DP INI Declerations */
|
||||
#define CFG_DP_HTT_PACKET_TYPE \
|
||||
CFG_INI_UINT("dp_htt_packet_type", \
|
||||
@@ -1206,6 +1218,41 @@
|
||||
#define CFG_DP_IPA_TX_RING_CFG
|
||||
#endif
|
||||
|
||||
#ifdef WLAN_SUPPORT_PPEDS
|
||||
#define CFG_DP_PPE_ENABLE \
|
||||
CFG_INI_BOOL("ppe_enable", false, \
|
||||
"DP ppe enable flag")
|
||||
|
||||
#define CFG_DP_REO2PPE_RING \
|
||||
CFG_INI_UINT("dp_reo2ppe_ring", \
|
||||
WLAN_CFG_REO2PPE_RING_SIZE_MIN, \
|
||||
WLAN_CFG_REO2PPE_RING_SIZE_MAX, \
|
||||
WLAN_CFG_REO2PPE_RING_SIZE, \
|
||||
CFG_VALUE_OR_DEFAULT, "DP REO2PPE ring")
|
||||
|
||||
#define CFG_DP_PPE2TCL_RING \
|
||||
CFG_INI_UINT("dp_ppe2tcl_ring", \
|
||||
WLAN_CFG_PPE2TCL_RING_SIZE_MIN, \
|
||||
WLAN_CFG_PPE2TCL_RING_SIZE_MAX, \
|
||||
WLAN_CFG_PPE2TCL_RING_SIZE, \
|
||||
CFG_VALUE_OR_DEFAULT, "DP PPE2TCL rings")
|
||||
|
||||
#define CFG_DP_PPE_RELEASE_RING \
|
||||
CFG_INI_UINT("dp_ppe_release_ring", \
|
||||
WLAN_CFG_PPE_RELEASE_RING_SIZE_MIN, \
|
||||
WLAN_CFG_PPE_RELEASE_RING_SIZE_MAX, \
|
||||
WLAN_CFG_PPE_RELEASE_RING_SIZE, \
|
||||
CFG_VALUE_OR_DEFAULT, "DP PPE Release Ring")
|
||||
|
||||
#define CFG_DP_PPE_CONFIG \
|
||||
CFG(CFG_DP_PPE_ENABLE) \
|
||||
CFG(CFG_DP_REO2PPE_RING) \
|
||||
CFG(CFG_DP_PPE2TCL_RING) \
|
||||
CFG(CFG_DP_PPE_RELEASE_RING)
|
||||
#else
|
||||
#define CFG_DP_PPE_CONFIG
|
||||
#endif
|
||||
|
||||
#define CFG_DP \
|
||||
CFG(CFG_DP_HTT_PACKET_TYPE) \
|
||||
CFG(CFG_DP_INT_BATCH_THRESHOLD_OTHER) \
|
||||
@@ -1302,5 +1349,6 @@
|
||||
CFG(CFG_DP_HW_CC_ENABLE) \
|
||||
CFG(CFG_FORCE_RX_64_BA) \
|
||||
CFG(CFG_DP_DELAY_MON_REPLENISH) \
|
||||
CFG_DP_IPA_TX_RING_CFG
|
||||
CFG_DP_IPA_TX_RING_CFG \
|
||||
CFG_DP_PPE_CONFIG
|
||||
#endif /* _CFG_DP_H_ */
|
||||
|
@@ -1027,6 +1027,33 @@ wlan_soc_hw_cc_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc,
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef WLAN_SUPPORT_PPEDS
|
||||
/**
|
||||
* wlan_soc_ppe_cfg_attach() - Update ppe config in dp soc
|
||||
* cfg context
|
||||
* @psoc - Object manager psoc
|
||||
* @wlan_cfg_ctx - dp soc cfg ctx
|
||||
*
|
||||
* Return: None
|
||||
*/
|
||||
static void
|
||||
wlan_soc_ppe_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc,
|
||||
struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx)
|
||||
{
|
||||
wlan_cfg_ctx->ppe_enable = cfg_get(psoc, CFG_DP_PPE_ENABLE);
|
||||
wlan_cfg_ctx->reo2ppe_ring = cfg_get(psoc, CFG_DP_REO2PPE_RING);
|
||||
wlan_cfg_ctx->ppe2tcl_ring = cfg_get(psoc, CFG_DP_PPE2TCL_RING);
|
||||
wlan_cfg_ctx->ppe_release_ring = cfg_get(psoc,
|
||||
CFG_DP_PPE_RELEASE_RING);
|
||||
}
|
||||
#else
|
||||
static inline void
|
||||
wlan_soc_ppe_cfg_attach(struct cdp_ctrl_objmgr_psoc *psoc,
|
||||
struct wlan_cfg_dp_soc_ctxt *wlan_cfg_ctx)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* wlan_cfg_soc_attach() - Allocate and prepare SoC configuration
|
||||
* @psoc - Object manager psoc
|
||||
@@ -1205,6 +1232,7 @@ wlan_cfg_soc_attach(struct cdp_ctrl_objmgr_psoc *psoc)
|
||||
CFG_DP_DELAY_MON_REPLENISH);
|
||||
wlan_soc_ipa_cfg_attach(psoc, wlan_cfg_ctx);
|
||||
wlan_soc_hw_cc_cfg_attach(psoc, wlan_cfg_ctx);
|
||||
wlan_soc_ppe_cfg_attach(psoc, wlan_cfg_ctx);
|
||||
|
||||
return wlan_cfg_ctx;
|
||||
}
|
||||
@@ -2172,3 +2200,29 @@ uint32_t wlan_cfg_ipa_tx_comp_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg)
|
||||
return cfg->ipa_tx_comp_ring_size;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef WLAN_SUPPORT_PPEDS
|
||||
bool
|
||||
wlan_cfg_get_dp_soc_is_ppe_enabled(struct wlan_cfg_dp_soc_ctxt *cfg)
|
||||
{
|
||||
return cfg->ppe_enable;
|
||||
}
|
||||
|
||||
int
|
||||
wlan_cfg_get_dp_soc_reo2ppe_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg)
|
||||
{
|
||||
return cfg->reo2ppe_ring;
|
||||
}
|
||||
|
||||
int
|
||||
wlan_cfg_get_dp_soc_ppe2tcl_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg)
|
||||
{
|
||||
return cfg->ppe2tcl_ring;
|
||||
}
|
||||
|
||||
int
|
||||
wlan_cfg_get_dp_soc_ppe_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg)
|
||||
{
|
||||
return cfg->ppe_release_ring;
|
||||
}
|
||||
#endif
|
||||
|
@@ -354,6 +354,12 @@ struct wlan_cfg_dp_soc_ctxt {
|
||||
#endif
|
||||
bool hw_cc_enabled;
|
||||
struct wlan_cfg_tcl_wbm_ring_num_map *tcl_wbm_map_array;
|
||||
#ifdef WLAN_SUPPORT_PPEDS
|
||||
bool ppe_enable;
|
||||
int reo2ppe_ring;
|
||||
int ppe2tcl_ring;
|
||||
int ppe_release_ring;
|
||||
#endif
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -1739,4 +1745,42 @@ wlan_cfg_set_delay_mon_replenish(struct wlan_cfg_dp_soc_ctxt *cfg, bool val);
|
||||
* Return:
|
||||
*/
|
||||
void wlan_cfg_dp_soc_ctx_dump(struct wlan_cfg_dp_soc_ctxt *cfg);
|
||||
|
||||
#ifdef WLAN_SUPPORT_PPEDS
|
||||
/*
|
||||
* wlan_cfg_get_dp_soc_is_ppe_enabled() - API to get ppe enable flag
|
||||
* @wlan_cfg_ctx - Configuration Handle
|
||||
*
|
||||
* Return: true if ppe is enabled else return false
|
||||
*/
|
||||
bool
|
||||
wlan_cfg_get_dp_soc_is_ppe_enabled(struct wlan_cfg_dp_soc_ctxt *cfg);
|
||||
|
||||
/*
|
||||
* wlan_cfg_get_dp_soc_reo2ppe_ring_size() - get ppe rx ring size
|
||||
* @wlan_cfg_ctx - Configuration Handle
|
||||
*
|
||||
* Return: size of reo2ppe ring
|
||||
*/
|
||||
int
|
||||
wlan_cfg_get_dp_soc_reo2ppe_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
|
||||
|
||||
/*
|
||||
* wlan_cfg_get_dp_soc_ppe2tcl_ring_size() - get ppe tx ring size
|
||||
* @wlan_cfg_ctx - Configuration Handle
|
||||
*
|
||||
* Return: size of ppe2tcl ring
|
||||
*/
|
||||
int
|
||||
wlan_cfg_get_dp_soc_ppe2tcl_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
|
||||
|
||||
/*
|
||||
* wlan_cfg_get_dp_soc_ppe_release_ring_size() - get ppe tx comp ring size
|
||||
* @wlan_cfg_ctx - Configuration Handle
|
||||
*
|
||||
* Return: size of ppe release ring
|
||||
*/
|
||||
int
|
||||
wlan_cfg_get_dp_soc_ppe_release_ring_size(struct wlan_cfg_dp_soc_ctxt *cfg);
|
||||
#endif
|
||||
#endif
|
||||
|
Verwijs in nieuw issue
Block a user