I am using the uio_pci_generic driver to handle leagcy interrupts.
Issue: The interrupt is seen in the driver, but not delivered to user space and does not get reflected in cat /proc/interrupts; the resulting log for the interrupt is mentioned below:
233: 0 0 0 0 GICv3 158 Level uio_pci_generic
For the user space appication, have used the example code as available in the document:
I verified the interrupt is triggered from the pcie card connected.
00:00.0 PCI bridge: Synopsys, Inc. DWC_usb3 / PCIe bridge (rev 01)
01:00.0 Ethernet controller: Intel Corporation I210 Gigabit Network Connection (rev 03)
Can anyone help me resolve the issue?
Hardware: Variscite's imx8mp board
One needs to register interrupt using request_irq() to get the interrupt in the /proc/interrupts.
Could you please confirm if you have done that with the driver that you mentioned?
Please note that the example code to which you are referring to doesn't clear the interrupt_disable bit. It only reads the interrupt status bit.
As described in uio-howto,
"On each interrupt, uio_pci_generic sets the Interrupt Disable bit. This prevents the device from generating further interrupts until the bit is cleared. The user-space driver should clear this bit before blocking and waiting for more interrupts."
One should clear the interrupt_disable bit before waiting for interrupts.
Could you please try adding the above functionality in the user-space code?
Thanks & Regards,