Skip to content

Commit ce83371

Browse files
authored
Merge pull request #3663 from nongxiaoming/fix_bug
[bsp][imxrt] fix the gpio drivers warning,'int_mode' may be used unin…
2 parents 08a8e75 + 3ded26a commit ce83371

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

bsp/imxrt/libraries/drivers/drv_gpio.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -559,6 +559,9 @@ static rt_err_t imxrt_pin_irq_enable(struct rt_device *device, rt_base_t pin, rt
559559
case PIN_IRQ_MODE_LOW_LEVEL:
560560
int_mode = kGPIO_IntLowLevel;
561561
break;
562+
default:
563+
int_mode = kGPIO_IntRisingEdge;
564+
break;
562565
}
563566
irq_index = (port << 1) + (pin_num >> 4);
564567
GPIO_PinSetInterruptConfig(mask_tab[port].gpio, pin_num, int_mode);

0 commit comments

Comments
 (0)