Part Number: AM625
Other Parts Discussed in Thread: SK-AM62
Device: AM625 GP
Installer: ti-processor-sdk-linux-am62xx-evm-09.00.00.03-Linux-x86-Install.bin — 6664936 K
SD card image: tisdk-debian-bookworm-am62xx-evm.wic.xz — 1955030 K
I want to drive HID I2C touch screen, use main_i2c1, clock-frequency is 400kHz, use gpio1_31 as int pin.
request_irq returns -22, and I see the following error message:
[ 3.930778] genirq: Setting trigger mode 8 for irq 384 failed (gpio_irq_type+0x0/0x54)
I want to use IRQF_TRIGGER_LOW in request_irq.
(code url: line971-irq_set_type, line318-gpio_irq_type)
I found that __irq_set_trigger in kernel/irq/manage.c will call gpio_irq_type in drivers/gpio/gpio-davinci.c, and gpio_irq_type will return -22.
I tried commenting out the following line of code(kernel/irq/manage.c-line971):
ret = chip->irq_set_type(&desc->irq_data, flags);
And touchscreen will probe successfully, but interrupt cannot work correctly.
The int pin is high after power on, and it will be low continuously after touching the touchscreen for the first time.
1.irq 384 after I touch the touchscreen many times, the times of triggers keeps being 0.

2.int pin registered as gpio-397

Please assist me in my task.
Thanks,
Andrew




