diff --git a/hw/mcu/native/src/hal_timer.c b/hw/mcu/native/src/hal_timer.c index 098ab8ddd5..77d3d0efea 100644 --- a/hw/mcu/native/src/hal_timer.c +++ b/hw/mcu/native/src/hal_timer.c @@ -331,7 +331,7 @@ int hal_timer_stop(struct hal_timer *timer) { struct native_timer *nt; - struct hal_timer *ht; + struct hal_timer *ht = NULL; int reset_ocmp; os_sr_t sr; diff --git a/hw/mcu/nordic/nrf51xxx/src/hal_timer.c b/hw/mcu/nordic/nrf51xxx/src/hal_timer.c index a99be65cb1..abcd7a9a47 100644 --- a/hw/mcu/nordic/nrf51xxx/src/hal_timer.c +++ b/hw/mcu/nordic/nrf51xxx/src/hal_timer.c @@ -939,7 +939,7 @@ hal_timer_stop(struct hal_timer *timer) { uint32_t ctx; int reset_ocmp; - struct hal_timer *entry; + struct hal_timer *entry = NULL; struct nrf51_hal_timer *bsptimer; if (timer == NULL) { diff --git a/hw/mcu/nordic/nrf52xxx/src/hal_timer.c b/hw/mcu/nordic/nrf52xxx/src/hal_timer.c index fc6fe834d1..75dec3c382 100644 --- a/hw/mcu/nordic/nrf52xxx/src/hal_timer.c +++ b/hw/mcu/nordic/nrf52xxx/src/hal_timer.c @@ -908,7 +908,7 @@ hal_timer_stop(struct hal_timer *timer) { uint32_t ctx; int reset_ocmp; - struct hal_timer *entry; + struct hal_timer *entry = NULL; struct nrf52_hal_timer *bsptimer; if (timer == NULL) { diff --git a/hw/mcu/nordic/nrf5340/src/hal_timer.c b/hw/mcu/nordic/nrf5340/src/hal_timer.c index cdc6c1ed0e..082567b9c4 100644 --- a/hw/mcu/nordic/nrf5340/src/hal_timer.c +++ b/hw/mcu/nordic/nrf5340/src/hal_timer.c @@ -860,7 +860,7 @@ hal_timer_stop(struct hal_timer *timer) { uint32_t ctx; int reset_ocmp; - struct hal_timer *entry; + struct hal_timer *entry = NULL; struct nrf5340_hal_timer *bsptimer; if (timer == NULL) { diff --git a/hw/mcu/nordic/nrf5340_net/src/hal_timer.c b/hw/mcu/nordic/nrf5340_net/src/hal_timer.c index 06884c61b3..9f6701520e 100644 --- a/hw/mcu/nordic/nrf5340_net/src/hal_timer.c +++ b/hw/mcu/nordic/nrf5340_net/src/hal_timer.c @@ -860,7 +860,7 @@ hal_timer_stop(struct hal_timer *timer) { uint32_t ctx; int reset_ocmp; - struct hal_timer *entry; + struct hal_timer *entry = NULL; struct nrf5340_hal_timer *bsptimer; if (timer == NULL) { diff --git a/hw/mcu/nordic/nrf91xx/src/hal_timer.c b/hw/mcu/nordic/nrf91xx/src/hal_timer.c index 61f87a10ed..5547a32818 100644 --- a/hw/mcu/nordic/nrf91xx/src/hal_timer.c +++ b/hw/mcu/nordic/nrf91xx/src/hal_timer.c @@ -894,7 +894,7 @@ hal_timer_stop(struct hal_timer *timer) { uint32_t ctx; int reset_ocmp; - struct hal_timer *entry; + struct hal_timer *entry = NULL; struct nrf91_hal_timer *bsptimer; if (timer == NULL) { diff --git a/hw/mcu/nxp/kinetis/src/hal_timer.c b/hw/mcu/nxp/kinetis/src/hal_timer.c index 4fadd01a2c..58cc02e3ee 100644 --- a/hw/mcu/nxp/kinetis/src/hal_timer.c +++ b/hw/mcu/nxp/kinetis/src/hal_timer.c @@ -405,7 +405,7 @@ int hal_timer_stop(struct hal_timer *timer) { struct kinetis_hal_tmr *tmr; - struct hal_timer *entry; + struct hal_timer *entry = NULL; bool reset_period; os_sr_t sr; diff --git a/hw/mcu/stm/stm32_common/src/hal_timer.c b/hw/mcu/stm/stm32_common/src/hal_timer.c index e5f4ed7ac9..b7c2206746 100644 --- a/hw/mcu/stm/stm32_common/src/hal_timer.c +++ b/hw/mcu/stm/stm32_common/src/hal_timer.c @@ -784,7 +784,7 @@ int hal_timer_stop(struct hal_timer *timer) { struct stm32_hal_tmr *tmr; - struct hal_timer *ht; + struct hal_timer *ht = NULL; int sr; int reset_ocmp;