We have attached ar1021 i2c touch controller to our product which uses Kontron SMARC Soc. How can I define it in device tree?
ar1021 i2c touch controller's interrupt line is connected to the pin P109 which is defined in 'SMARC sMAX6i' manual as
|Pin||Signal||Direction||Termination||Type/tol||Controller||Controller PIn name||Port dl||Port solo||iomux instance|
|P109||GPIO1 / CAM1_PWR#||Bi-Dir||PU-470k||CMOS / VDD_IO||iMX6||EIM_DA1||GPIO3_IO01||GPIO3_IO01||ALT5 / ALT5|
I have tried define ar1021 in device tree as below. Driver loads proberly but interrupt callback function is never called.
status = "okay";
compatible = "microchip,ar1021-i2c";
reg = <0x4D>;
interrupt-parent = <&gpio3>;
interrupts = <1 IRQ_TYPE_EDGE_FALLING>;
wakeup-gpios = <&gpio3 1 IRQ_TYPE_LEVEL_HIGH>;
Problem seems to be that interrupt for PIN P109 is not defined correctly. Any ideas?