1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

cpu/sam0_common: gpio: warn if EXTI line is re-used

This commit is contained in:
Benjamin Valentin 2023-09-04 15:43:06 +02:00
parent f1df27b381
commit 4ebf58d47a

View File

@ -333,6 +333,10 @@ int gpio_init_int(gpio_t pin, gpio_mode_t mode, gpio_flank_t flank,
return -1;
}
if (gpio_config[exti].cb) {
DEBUG("gpio: Warning - interrupt line %u already in use\n", exti);
}
/* save callback */
gpio_config[exti].cb = cb;
gpio_config[exti].arg = arg;