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
Answer from irdroid3 on serverfault.com
🌐
Hitchhikersguidetolearning
hitchhikersguidetolearning.com › 2021 › 03 › 28 › looking-at-proc-interrupts
Looking at /proc/interrupts | Hitch Hiker's Guide to Learning
The output of “/proc/interrupts” shows all the different interrupts that have handlers (Interrupt Service Routines – ISRs) registered for them. The first column indicates the IRQ number. Subsequent columns indicate how many interrupts have been generated for the IRQ number on different ...
🌐
Linux Man Pages
man7.org › linux › man-pages › man5 › proc_interrupts.5.html
proc_interrupts(5) - Linux manual page
/proc/interrupts This is used to record the number of interrupts per CPU per IO device.
Top answer
1 of 2
8

As you can see in the source of the kernel, it displays all possible irqs of the system.
In source/fs/proc/interrupts.c:39 a sequence operation is initialized to return as many elements as interrupts exist in the system for /proc/interrupts.

In source/kernel/irq/proc.c:479 we can see that the counters of every interrupt gets extracted from global counters via kstat_irqs_cpu(irq, cpu).
This means the interrupt count information gets updated in different counters, one for each cpu. The counters get summed upon reading the proc file. This is a common pattern in the kernel. It prevents contention on a global counter.

More onfo about per-cpu variables you can read here. More about interrupts in linux you can get here.

2 of 2
5

All files under /proc are pseudo files , which means there is no actual data present in them.

When you access any file under proc fs , proc methods linked with that particular proc file is invoked , and the proc methods , access certain related kernel data structures and generate data dynamically , which can be read and displayed. Data from proc file is generally used to display status information of the system , or the state of a device driver.

The proc fs is generally implemented as part of the driver , by adding the proc and the seq fs layer to the driver code , however proc is also used by the kernel , to display status information of the system in general.Since there is no general hierarchy or classification among the proc files , they are used rarely in comparison with the newer sysfs file system.

To know how the information is generated , you must study the proc layer implemented in fs/proc/interrupts.c

This website briefly explains some of those methods.

🌐
Clever Uptime
cleveruptime.com › docs › files › proc-interrupts
/proc/interrupts: Explanation & Insights - CleverUptime
This command refreshes the interrupt counts every second, allowing you to observe changes in real time. Opening the /proc/interrupts file reveals a table. Each row corresponds to an interrupt number (IRQ), and each column represents a CPU in ...
Find elsewhere
🌐
Ubuntu
manpages.ubuntu.com › noble › man(5)
Ubuntu Manpage: /proc/interrupts - number of interrupts
number of interrupts · Provided by: manpages (Version: 6.7-2) Report a bug · /proc/interrupts · This is used to record the number of interrupts per CPU per IO device.
🌐
Alibaba Cloud Community
alibabacloud.com › blog › understanding-cpu-interrupts-in-linux_597128
Understanding CPU Interrupts in Linux - Alibaba Cloud Community
January 11, 2021 - In this example, four queues are configured on four CPUs, but interrupts are handled by CPUs 0 and 2 by default. # grep -i "input" /proc/interrupts 27: 1932 0 0 0 PCI-MSI-edge virtio2-input.0 29: 2 0 1627 0 PCI-MSI-edge virtio2-input.1 32: 1974 0 0 0 PCI-MSI-edge virtio2-input.2 35: 3 0 284 0 PCI-MSI-edge virtio2-input.3 # for i in $(egrep "\-input."
🌐
Readthedocs
insights-core.readthedocs.io › en › latest › shared_parsers_catalog › interrupts.html
Interrupts - file /proc/interrupts — insights-core 3.99.0 documentation
CPU0 CPU1 CPU2 CPU3 0: 37 0 0 0 IR-IO-APIC 2-edge timer 1: 3 2 1 0 IR-IO-APIC 1-edge i8042 8: 0 1 0 0 IR-IO-APIC 8-edge rtc0 9: 11107 2316 4040 1356 IR-IO-APIC 9-fasteoi acpi NMI: 210 92 179 96 Non-maskable interrupts LOC: 7561411 2488524 6527767 2448192 Local timer interrupts ERR: 0 MIS: 0
🌐
NVIDIA Developer Forums
forums.developer.nvidia.com › infrastructure & networking › software and drivers › mellanox ofed
How to read /proc/interrupts? - Mellanox OFED - NVIDIA Developer Forums
September 2, 2013 - Hello, when I have a look at our Ubuntu 12.04 LTS (Kernel 3.5) /proc/interrupts output I see several interrupts for the installed ConnectX infiniband card: 73: 999+ 999+ 999+ 999+ … mlx4-ib-1-0@PCI Bus 0000:09 … 74: 0000 0000 0000 0000 … mlx4-ib-1-1@PCI Bus 0000:09 …
Top answer
1 of 1
7

You are correct: they relate to the IO-APIC system. ERR is documented in the kernel documentation in Documentation/filesystems/proc (lines 677-680):

ERR is incremented in the case of errors in the IO-APIC bus (the bus that connects the CPUs in a SMP system. This means that an error has been detected, the IO-APIC automatically retry the transmission, so it should not be a big problem, but you should read the SMP-FAQ.

AFAICT you shouldn't see this unless there is a hardware issue. As the documentation indicates, it's something that you show note and investigate if it happens frequently.

MIS doesn't show up in the documentation, but this Gentoo forum message from 2005 talks about it. The current arch/x86/apic/io_apic.c (lines 1797-1806) has the following comment:

It appears there is an erratum which affects at least version 0x11 of I/O APIC (that's the 82093AA and cores integrated into various chipsets). Under certain conditions a level-triggered interrupt is erroneously delivered as edge-triggered one but the respective IRR bit gets set nevertheless. As a result the I/O unit expects an EOI message but it will never arrive and further interrupts are blocked from the source. The exact reason is so far unknown, but the phenomenon was observed when two consecutive interrupt requests from a given source get delivered to the same CPU and the source is temporarily disabled in between.

As this comment (and code) haven't significantly changed in over 10 years (other than kernel restructuring), I'm not sure how relevant it is today, but it is very small and protects against a strange hardware quirk.

The files that I looked at were from version 4.15.10 of the kernel. Your sources may vary.

🌐
Arch Linux Man Pages
man.archlinux.org › man › proc_interrupts.5.en
proc_interrupts(5) — Arch manual pages
/proc/interrupts - number of interrupts · /proc/interrupts · This is used to record the number of interrupts per CPU per IO device.
🌐
Linux Kernel
kernel.org › doc › html › v6.5 › filesystems › proc.html
The /proc Filesystem — The Linux Kernel documentation
LOC is the local interrupt counter of the internal APIC of every CPU. ERR is incremented in the case of errors in the IO-APIC bus (the bus that connects the CPUs in a SMP system. This means that an error has been detected, the IO-APIC automatically retry the transmission, so it should not be a big problem, but you should read the SMP-FAQ. In 2.6.2* /proc/interrupts was expanded again.