I want to make the GPIO pin assigned to my RTC a falling edge interrupt.
This is what I have done so far:
Defined the pin node
Defined I2C node for the RTC and designated interrupt info
Compile new .dtb and scp the file to the board
Finally, when I execute a ' cat /proc/interrupts' the interrupt always shows up as a level interrupt and never and edge like I defined it to be.
Looking at the datasheet, it appears each pin can be assigned as a high or low level as well as falling or rising edge interrupt.
When I test the interrupt functionality this is what I see:
Can someone point me in the right direction to identify what I am doing wrong or missing here?
Thanks,
Dan
I think I figured out what's going on. I believe the device tree interrupt configuration be overwritten by the device driver.
I am fairly new to embedded Linux applications, but I assume a device driver can overwrite the info the device tree is telling the kernel. Can you confirm?
Hi
NO, device tree can not be changed by driver.The code you show just judge the trigger type to handle irq.For example, if you define the gpio irq is type of low trigger.The driver find current irq is low and it will call m4lt80_handle_irq.
BR
Zhiming
Hi
You can use our gpio config tool to generate dts code https://www.nxp.com/design/designs/pins-tool-for-i-mx-application-processors:PINS-TOOL-IMX
BR
Zhiming