9

Can someone assist me in analyzing the data in this output from my /proc/interrupts file?

$ cat /proc/interrupts
           CPU0       CPU1
  0:         22          0  IR-IO-APIC   2-edge      timer
  1:          2          0  IR-IO-APIC   1-edge      i8042
  8:          1          0  IR-IO-APIC   8-edge      rtc0
  9:          0          0  IR-IO-APIC   9-fasteoi   acpi
 12:          4          0  IR-IO-APIC  12-edge      i8042
120:          0          0  DMAR-MSI   0-edge      dmar0
122:          0          0  IR-PCI-MSI 327680-edge      xhci_hcd
123:      25164    5760490  IR-PCI-MSI 1048576-edge      enp2s0
124:         17    5424414  IR-PCI-MSI 524288-edge      amdgpu

What I have compiled so far...

  • Column 1: IRQ number
  • Column 2&3: # of interrupts per CPU (variable # of columns depends on how many CPUs your system has)
  • Column 4: Type of interrupt
  • Column 5: ???
  • Column 6: Name of device

I'm interested in finding out what data the 5th column contains, i.e. 524288-edge, and if someone can break down what the number represents. From researching online I only see the interrupt type column followed by the name of the device, this column data is always missing. Is it simply more information about the interrupt type?

3
  • 2
    @Thomas did you bother to read the question or the link you provided?
    – Matt K
    Feb 12, 2018 at 19:02
  • 1
    I would guess that the number in column 5 is the hwirq local to the interrupt controller (as specified in column 4). The kernel maintains a mapping between the local hwirq of each interrupt controller (irqchip) to a global irq (aka virtual irq, which is specified in the 1st column), using a mechanism called irq domain.
    – bruin
    May 26, 2022 at 1:39

2 Answers 2

5

I am still poking around this area too.

This points to the "edge" meaning the type of irq is an "edge falling" irq: https://www.raspberrypi.org/forums/viewtopic.php?t=20931

Looking at mine, I have "18 edge" and that ties in with the GPIO-18 I expect the interrupt to come in on in my case :

       CPU0      CPU1   CPU2  CPU3
172:   1387      0      0     0     pinctrl-bcm2835  18 Edge      lirc_rpi
1
\/  ... linux global irq number
            \/  ...   number of occured irqs on CPU 0
                        \/  ...    number of occured irqs on CPU 1
                              \/  ...  irq chip receiving the irq
                                         \/ ... hw irq number and type of irq
                                                          \/  ... assigned action of irq 
                                                                  (-> irq handler inside a driver, can also be assigned to more then just one handler / driver) 

cat /proc/interrupts
           CPU0       CPU1
  0:         22          0  IR-IO-APIC   2-edge            timer
  1:          2          0  IR-IO-APIC   1-edge            i8042
  8:          1          0  IR-IO-APIC   8-edge            rtc0
  9:          0          0  IR-IO-APIC   9-fasteoi         acpi
 12:          4          0  IR-IO-APIC   12-edge           i8042
120:          0          0  DMAR-MSI     0-edge            dmar0
122:          0          0  IR-PCI-MSI   327680-edge       xhci_hcd
123:      25164    5760490  IR-PCI-MSI   1048576-edge      enp2s0
124:         17    5424414  IR-PCI-MSI   524288-edge       amdgpu

Same information is also in /sys/kernel/irq/<number of each irq>/<info files>, but more machine readable.

More irq infos can be retrieved, if kernel is compiled with e.g. CONFIG_IRQ_DOMAIN_DEBUG=y

A good introduction to linux IRQs is here: https://www.youtube.com/watch?v=LOCsN3V1ECE

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .