Browse Source

[LPC176x] Fix switch fallthrough

Chris Pepper 6 years ago
parent
commit
451ea996c9
No account linked to committer's email address
1 changed files with 4 additions and 4 deletions
  1. 4
    4
      Marlin/src/HAL/HAL_LPC1768/HAL_timers.h

+ 4
- 4
Marlin/src/HAL/HAL_LPC1768/HAL_timers.h View File

@@ -126,15 +126,15 @@ FORCE_INLINE static hal_timer_t HAL_timer_get_count(const uint8_t timer_num) {
126 126
 
127 127
 FORCE_INLINE static void HAL_timer_enable_interrupt(const uint8_t timer_num) {
128 128
   switch (timer_num) {
129
-    case 0: NVIC_EnableIRQ(TIMER0_IRQn); // Enable interrupt handler
130
-    case 1: NVIC_EnableIRQ(TIMER1_IRQn); // Enable interrupt handler
129
+    case 0: NVIC_EnableIRQ(TIMER0_IRQn); break; // Enable interrupt handler
130
+    case 1: NVIC_EnableIRQ(TIMER1_IRQn); break; // Enable interrupt handler
131 131
   }
132 132
 }
133 133
 
134 134
 FORCE_INLINE static void HAL_timer_disable_interrupt(const uint8_t timer_num) {
135 135
   switch (timer_num) {
136
-    case 0: NVIC_DisableIRQ(TIMER0_IRQn); // Disable interrupt handler
137
-    case 1: NVIC_DisableIRQ(TIMER1_IRQn); // Disable interrupt handler
136
+    case 0: NVIC_DisableIRQ(TIMER0_IRQn); break; // Disable interrupt handler
137
+    case 1: NVIC_DisableIRQ(TIMER1_IRQn); break; // Disable interrupt handler
138 138
   }
139 139
 
140 140
   // We NEED memory barriers to ensure Interrupts are actually disabled!

Loading…
Cancel
Save