diff --git a/dp/inc/cdp_txrx_mon_struct.h b/dp/inc/cdp_txrx_mon_struct.h index 2fcedfdb79..096e107381 100644 --- a/dp/inc/cdp_txrx_mon_struct.h +++ b/dp/inc/cdp_txrx_mon_struct.h @@ -223,6 +223,8 @@ enum { * @mon_rx_bufs_reaped_dest: Rx buffer reap count * @ppdu_id_mismatch: counter to track ppdu id mismatch in * mointor status and monitor destination ring + * @ppdu_id_match: counter to track ppdu id match in + * mointor status and monitor destination ring */ struct cdp_pdev_mon_stats { #ifndef REMOVE_MON_DBG_STATS @@ -247,5 +249,6 @@ struct cdp_pdev_mon_stats { uint32_t mon_rx_bufs_replenished_dest; uint32_t mon_rx_bufs_reaped_dest; uint32_t ppdu_id_mismatch; + uint32_t ppdu_id_match; }; #endif diff --git a/dp/wifi3.0/dp_main.c b/dp/wifi3.0/dp_main.c index 7628289835..0563cea7d7 100644 --- a/dp/wifi3.0/dp_main.c +++ b/dp/wifi3.0/dp_main.c @@ -2003,6 +2003,8 @@ static void dp_soc_interrupt_map_calculate_integrated(struct dp_soc *soc, ppdu_end_interrupts_mac1 - j; irq_id_map[num_irq++] = rxdma2host_monitor_status_ring_mac1 - j; + irq_id_map[num_irq++] = + rxdma2host_monitor_destination_mac1 - j; } if (rx_wbm_rel_ring_mask & (1 << j)) diff --git a/dp/wifi3.0/dp_rx_mon.h b/dp/wifi3.0/dp_rx_mon.h index 4a44ae5513..6db09469a3 100644 --- a/dp/wifi3.0/dp_rx_mon.h +++ b/dp/wifi3.0/dp_rx_mon.h @@ -330,6 +330,7 @@ dp_rx_mon_update_dbg_ppdu_stats(struct hal_rx_ppdu_info *ppdu_info, rx_mon_stats->status_ppdu_end_mis++; rx_mon_stats->status_ppdu_state = CDP_MON_PPDU_START; + ppdu_info->rx_state = HAL_RX_MON_PPDU_RESET; } else if (ppdu_info->rx_state == HAL_RX_MON_PPDU_END) { rx_mon_stats->status_ppdu_end++; @@ -340,6 +341,7 @@ dp_rx_mon_update_dbg_ppdu_stats(struct hal_rx_ppdu_info *ppdu_info, rx_mon_stats->status_ppdu_compl++; rx_mon_stats->status_ppdu_state = CDP_MON_PPDU_END; + ppdu_info->rx_state = HAL_RX_MON_PPDU_RESET; } } diff --git a/dp/wifi3.0/dp_rx_mon_dest.c b/dp/wifi3.0/dp_rx_mon_dest.c index 12b2b5fb87..da3a8de9c5 100644 --- a/dp/wifi3.0/dp_rx_mon_dest.c +++ b/dp/wifi3.0/dp_rx_mon_dest.c @@ -328,6 +328,12 @@ dp_rx_mon_mpdu_pop(struct dp_soc *soc, uint32_t mac_id, dp_tx_capture_get_user_id(dp_pdev, rx_desc_tlv); + if (*ppdu_id == msdu_ppdu_id) + dp_pdev->rx_mon_stats.ppdu_id_match++; + else + dp_pdev->rx_mon_stats.ppdu_id_mismatch + ++; + dp_pdev->mon_last_linkdesc_paddr = buf_info.paddr; } @@ -892,7 +898,6 @@ QDF_STATUS dp_rx_mon_deliver(struct dp_soc *soc, uint32_t mac_id, DP_STATS_INC(pdev, dropped.mon_radiotap_update_err, 1); goto mon_deliver_fail; } - pdev->monitor_vdev->osif_rx_mon(pdev->monitor_vdev->osif_vdev, mon_mpdu, &pdev->ppdu_info.rx_status); diff --git a/dp/wifi3.0/dp_stats.c b/dp/wifi3.0/dp_stats.c index 83f21ef703..770a3ab64c 100644 --- a/dp/wifi3.0/dp_stats.c +++ b/dp/wifi3.0/dp_stats.c @@ -5933,12 +5933,14 @@ dp_print_pdev_rx_mon_stats(struct dp_pdev *pdev) rx_mon_stats->dup_mon_linkdesc_cnt); DP_PRINT_STATS("dup_mon_buf_cnt = %d", rx_mon_stats->dup_mon_buf_cnt); - DP_PRINT_STATS("ppdu_id_mismatch = %u", - rx_mon_stats->ppdu_id_mismatch); DP_PRINT_STATS("mon_rx_buf_reaped = %u", rx_mon_stats->mon_rx_bufs_reaped_dest); DP_PRINT_STATS("mon_rx_buf_replenished = %u", rx_mon_stats->mon_rx_bufs_replenished_dest); + DP_PRINT_STATS("ppdu_id_mismatch = %u", + rx_mon_stats->ppdu_id_mismatch); + DP_PRINT_STATS("mpdu_ppdu_id_match_cnt = %d", + rx_mon_stats->ppdu_id_match); stat_ring_ppdu_ids = (uint32_t *)qdf_mem_malloc(sizeof(uint32_t) * MAX_PPDU_ID_HIST); dest_ring_ppdu_ids = diff --git a/hal/wifi3.0/hal_api_mon.h b/hal/wifi3.0/hal_api_mon.h index 4ea10bcdfc..c70bac38e4 100644 --- a/hal/wifi3.0/hal_api_mon.h +++ b/hal/wifi3.0/hal_api_mon.h @@ -442,11 +442,13 @@ enum { /** * enum * @HAL_RX_MON_PPDU_START: PPDU start TLV is decoded in HAL - * @HAL_RX_MON_PPDU_END: PPDU end TLV is decided in HAL + * @HAL_RX_MON_PPDU_END: PPDU end TLV is decoded in HAL + * @HAL_RX_MON_PPDU_RESET: Not PPDU start and end TLV */ enum { HAL_RX_MON_PPDU_START = 0, HAL_RX_MON_PPDU_END, + HAL_RX_MON_PPDU_RESET, }; /* struct hal_rx_ppdu_common_info - common ppdu info