diff --git a/arch/arm/src/phy62xx/phy6222_patch.c b/arch/arm/src/phy62xx/phy6222_patch.c index bafa96fe84..6e60ce118a 100644 --- a/arch/arm/src/phy62xx/phy6222_patch.c +++ b/arch/arm/src/phy62xx/phy6222_patch.c @@ -1,19 +1,24 @@ -#include "types.h" -#include -#include "mcu_phy_bumbee.h" - -#ifndef CONFIG_PHY6222_SDK -void TIM1_IRQHandler1(void) -{ - /* HAL_ENTER_CRITICAL_SECTION() */ - - if (AP_TIM1->status & 0x1) - { - clear_timer_int(AP_TIM1); - clear_timer(AP_TIM1); - LL_evt_schedule(); - } - - /* HAL_EXIT_CRITICAL_SECTION(); */ -} -#endif +#include "types.h" +#include "rom_sym_def.h" +#include +#include "mcu_phy_bumbee.h" + +extern int clear_timer_int(AP_TIM_TypeDef* TIMx); +extern void clear_timer(AP_TIM_TypeDef* TIMx); +extern void LL_evt_schedule(void); + +#ifndef CONFIG_PHY6222_SDK +void TIM1_IRQHandler1(void) +{ + /* HAL_ENTER_CRITICAL_SECTION() */ + + if (AP_TIM1->status & 0x1) + { + clear_timer_int(AP_TIM1); + clear_timer(AP_TIM1); + LL_evt_schedule(); + } + + /* HAL_EXIT_CRITICAL_SECTION(); */ +} +#endif