diff --git a/hw_if/hal/inc/hal_structs.h b/hw_if/hal/inc/hal_structs.h index a9fcd60..47bf4a2 100644 --- a/hw_if/hal/inc/hal_structs.h +++ b/hw_if/hal/inc/hal_structs.h @@ -252,6 +252,10 @@ struct nrf_wifi_hal_dev_ctx { unsigned long last_wakeup_now_deasserted_time_ms; /** RPU sleep opp time */ unsigned long last_rpu_sleep_opp_time_ms; + /** Recieved watchdog timer interrupt */ + int watchdog_timer_recieved; + /** Ignored watchdog timer interrupt */ + int watchdog_timer_ignored; #endif /* NRF_WIFI_RPU_RECOVERY */ #if defined(NRF_WIFI_LOW_POWER) || defined(__DOXYGEN__) /** RPU power state */ diff --git a/hw_if/hal/src/hal_interrupt.c b/hw_if/hal/src/hal_interrupt.c index 17b35e7..3784100 100644 --- a/hw_if/hal/src/hal_interrupt.c +++ b/hw_if/hal/src/hal_interrupt.c @@ -521,6 +521,7 @@ static enum nrf_wifi_status hal_rpu_process_wdog(struct nrf_wifi_hal_dev_ctx *ha * PS_ACTIVE state for more than the timeout period */ if (!is_rpu_recovery_needed(hal_dev_ctx)) { + hal_dev_ctx->watchdog_timer_ignored++; #ifdef NRF_WIFI_RPU_RECOVERY_DEBUG nrf_wifi_osal_log_info("Ignore watchdog interrupt, RPU recovery not needed"); #else @@ -577,6 +578,7 @@ enum nrf_wifi_status hal_rpu_irq_process(struct nrf_wifi_hal_dev_ctx *hal_dev_ct num_events = hal_rpu_event_get_all(hal_dev_ctx); if (hal_rpu_irq_wdog_chk(hal_dev_ctx)) { + hal_dev_ctx->watchdog_timer_recieved++; nrf_wifi_osal_log_dbg("Received watchdog interrupt"); status = hal_rpu_process_wdog(hal_dev_ctx, do_rpu_recovery);