diff --git a/core/hif/src/ce/ce_internal.h b/core/hif/src/ce/ce_internal.h index d95f27cd3e4f..b4272c56a41a 100644 --- a/core/hif/src/ce/ce_internal.h +++ b/core/hif/src/ce/ce_internal.h @@ -298,6 +298,8 @@ union ce_desc { * @HIF_CE_TASKLET_ENTRY: records the start of the ce_tasklet * @HIF_CE_TASKLET_RESCHEDULE: records the rescheduling of the wlan_tasklet * @HIF_CE_TASKLET_EXIT: records the exit of the wlan tasklet without reschedule + * @HIF_CE_REAP_ENTRY: records when we process completion outside of a bh + * @HIF_CE_REAP_EXIT: records when we process completion outside of a bh */ enum hif_ce_event_type { HIF_RX_DESC_POST, @@ -309,6 +311,8 @@ enum hif_ce_event_type { HIF_CE_TASKLET_ENTRY, HIF_CE_TASKLET_RESCHEDULE, HIF_CE_TASKLET_EXIT, + HIF_CE_REAP_ENTRY, + HIF_CE_REAP_EXIT, }; void ce_init_ce_desc_event_log(int ce_id, int size); diff --git a/core/hif/src/ce/ce_service.c b/core/hif/src/ce/ce_service.c index 8e31cd507bab..0d97b4949943 100644 --- a/core/hif/src/ce/ce_service.c +++ b/core/hif/src/ce/ce_service.c @@ -1181,7 +1181,7 @@ ce_completed_send_next(struct CE_handle *copyeng, * within it . */ -void ce_per_engine_servicereap(struct ol_softc *scn, unsigned int CE_id) +void ce_per_engine_servicereap(struct ol_softc *scn, unsigned int ce_id) { void *CE_context; void *transfer_context; @@ -1190,9 +1190,11 @@ void ce_per_engine_servicereap(struct ol_softc *scn, unsigned int CE_id) unsigned int id; unsigned int sw_idx, hw_idx; uint32_t toeplitz_hash_result; - struct CE_state *CE_state = scn->ce_id_to_state[CE_id]; + struct CE_state *CE_state = scn->ce_id_to_state[ce_id]; A_TARGET_ACCESS_BEGIN(scn); + hif_record_ce_desc_event(ce_id, HIF_CE_REAP_ENTRY, + NULL, NULL, 0); /* Since this function is called from both user context and * tasklet context the spinlock has to lock the bottom halves. @@ -1220,7 +1222,7 @@ void ce_per_engine_servicereap(struct ol_softc *scn, unsigned int CE_id) &nbytes, &id, &sw_idx, &hw_idx, &toeplitz_hash_result) == CDF_STATUS_SUCCESS) { - if (CE_id != CE_HTT_H2T_MSG) { + if (ce_id != CE_HTT_H2T_MSG) { cdf_spin_unlock_bh( &CE_state->ce_index_lock); CE_state->send_cb( @@ -1247,6 +1249,9 @@ void ce_per_engine_servicereap(struct ol_softc *scn, unsigned int CE_id) } cdf_spin_unlock_bh(&CE_state->ce_index_lock); + + hif_record_ce_desc_event(ce_id, HIF_CE_REAP_EXIT, + NULL, NULL, 0); A_TARGET_ACCESS_END(scn); }