Date: Thu, 16 Apr 2026 15:12:16 +0000 From: Colin Percival <cperciva@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: a25f78eafe47 - stable/14 - clapic_handle_intr: KASSERT isrc != NULL Message-ID: <69e0fc50.1eeb8.36b2d901@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch stable/14 has been updated by cperciva: URL: https://cgit.FreeBSD.org/src/commit/?id=a25f78eafe472cb161d1405f63ad8c4491416a6b commit a25f78eafe472cb161d1405f63ad8c4491416a6b Author: Colin Percival <cperciva@FreeBSD.org> AuthorDate: 2026-03-14 01:03:44 +0000 Commit: Colin Percival <cperciva@FreeBSD.org> CommitDate: 2026-04-16 15:11:54 +0000 clapic_handle_intr: KASSERT isrc != NULL If an interrupt arrives at a CPU which isn't expecting that particular vector, intr_lookup_source will return an isrc of NULL and we'll panic when intr_execute_handlers increments *isrc->is_count. Place a KASSERT a few nanoseconds earlier in order to leave some more breadcrumbs for the next person to trip over this behaviour. Tested on: EC2 r8i.96xlarge MFC after: 3 weeks Sponsored by: Amazon Differential Revision: https://reviews.freebsd.org/D55851 (cherry picked from commit f350063a251c9da0c5ce437eb4c44a2d716b673e) --- sys/x86/x86/local_apic.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/x86/x86/local_apic.c b/sys/x86/x86/local_apic.c index bf05855439bc..2efa0b9b5c1d 100644 --- a/sys/x86/x86/local_apic.c +++ b/sys/x86/x86/local_apic.c @@ -1287,6 +1287,9 @@ lapic_handle_intr(int vector, struct trapframe *frame) isrc = intr_lookup_source(apic_idt_to_irq(PCPU_GET(apic_id), vector)); + KASSERT(isrc != NULL, + ("lapic_handle_intr: vector %d unrecognized at lapic %u", + vector, PCPU_GET(apic_id))); intr_execute_handlers(isrc, frame); }home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?69e0fc50.1eeb8.36b2d901>
