Commit 5ede804e authored by Emil Dahl Juhl's avatar Emil Dahl Juhl Committed by Alberto Escolar
Browse files

drivers: gpio: mspm0: Mask interrupts correctly



Reading back the raw interrupt status from the gpio controller, provides
the interrupt mask _without_ the controller's masking registers applied.
This means that e.g. a rising edge would trigger an interrupt even on
pins that are configured for falling edge only.

Fix this by reading the "enabled" interrupt status instead of the raw
one.

Signed-off-by: default avatarEmil Dahl Juhl <emdj@bang-olufsen.dk>
parent 3e5b9728
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -246,7 +246,7 @@ static void gpio_mspm0_isr(const struct device *port)
		data = dev_list[i]->data;
		config = dev_list[i]->config;

		status = DL_GPIO_getRawInterruptStatus(config->base,
		status = DL_GPIO_getEnabledInterruptStatus(config->base,
							   0xFFFFFFFF);

		DL_GPIO_clearInterruptStatus(config->base, status);