Skip to content

Commit 0c8527f

Browse files
Qinghao ShiQinghao Shi
authored andcommitted
add disable interrupt function in us_ticker_free()
1 parent 810d534 commit 0c8527f

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

targets/TARGET_ARM_FM/TARGET_FVP_MPS2/us_ticker.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,12 +62,9 @@ void us_ticker_init(void)
6262

6363
void us_ticker_free(void)
6464
{
65-
if (!us_ticker_inited) {
66-
return;
67-
}
68-
6965
US_TICKER_TIMER1->TimerControl &= ~CMSDK_DUALTIMER1_CTRL_EN_Msk; // disable TIMER1
7066
US_TICKER_TIMER2->TimerControl &= ~CMSDK_DUALTIMER2_CTRL_EN_Msk; // disable TIMER2
67+
us_ticker_disable_interrupt();
7168
us_ticker_inited = 0;
7269
}
7370

0 commit comments

Comments
 (0)