HomeFreeBSD

io_apic: Don't route to APIC ID > 255

Description

io_apic: Don't route to APIC ID > 255

I/O APIC Redirection Table Entries use 8 bits to encode the Destination
ID. Attempting to route an IRQ to a higher APIC ID would result in it
being silently routed to the value reduced modulo 256, causing a panic
if the IRQ fired since the receiving CPU would not expect that IRQ.

Instead, print a warning and mark the interrupt as invalid, resulting
in it being forcibly masked.

Reviewed by: kib
Tested on: EC2 r8i.96xlarge
MFC after: 3 weeks
Sponsored by: Amazon
Differential Revision: https://reviews.freebsd.org/D55857

Details

Provenance
cpercivaAuthored on Mar 14 2026, 5:51 AM
Reviewer
kib
Differential Revision
D55857: io_apic: Don't route to APIC ID > 255
Parents
rG1d0ccd61563d: x86: Add struct ioapic_intsrc.io_valid
Branches
Unknown
Tags
Unknown