All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/12] irqchip: validate remaining MADT records before use
@ 2026-10-28  5:00 ` Jiale Yao
  0 siblings, 0 replies; 16+ messages in thread
From: Jiale Yao @ 2026-10-28  5:00 UTC (permalink / raw)
  To: Paul Walmsley, Palmer Dabbelt, Albert Ou, Alexandre Ghiti,
	Marc Zyngier, Lorenzo Pieralisi, Thomas Gleixner, Radu Rendec,
	Huacai Chen, WANG Xuerui, Jiaxun Yang, Anup Patel,
	Rafael J. Wysocki, Sunil V L, Andrew Jones, Jonathan Cameron,
	Hanjun Guo, Tomasz Nowicki, Grant Likely, Jason Cooper,
	Robert Richter, Catalin Marinas, Liupu Wang, Tianyang Zhang,
	Jianmin Lv, Conor Dooley, linux-riscv, linux-kernel,
	linux-arm-kernel, loongarch, linux-mips

Several ACPI interrupt-controller callbacks cast generic MADT subtable
headers to controller-specific records and access typed fields without
first checking that the firmware supplied the complete structure. A
truncated entry can therefore cause an out-of-bounds read during early
interrupt-controller and CPU discovery.

Add the missing minimum-size checks at the callback boundaries. Records
which are passed from a probe validator to an initialization callback are
validated once in the validator, before either callback accesses them.

The issues were found by code inspection and have not been tested on real
hardware.

Jiale Yao (12):
  riscv: acpi: validate RINTC entries before use
  irqchip/gic-v5-irs: validate MADT GICC entries
  irqchip/gic-v5-irs: validate MADT IRS entries
  irqchip/gic-v5: validate MADT IRS records
  irqchip/gic: validate MADT distributor records
  irqchip/loongarch-avec: validate MADT MSI-PIC entries
  irqchip/loongarch-ir: validate MADT MSI-PIC entries
  irqchip/loongson-htvec: validate MADT BIO-PIC entries
  irqchip/loongson-htvec: validate MADT MSI-PIC entries
  irqchip/loongson-liointc: validate MADT HT-PIC entries
  irqchip/loongson-pch-pic: validate MADT LPC-PIC entries
  irqchip/riscv-intc: validate MADT RINTC entries

 arch/riscv/kernel/acpi.c               | 3 +++
 drivers/irqchip/irq-gic-v5-irs.c       | 6 ++++++
 drivers/irqchip/irq-gic-v5.c           | 3 +++
 drivers/irqchip/irq-gic.c              | 3 +++
 drivers/irqchip/irq-loongarch-avec.c   | 3 +++
 drivers/irqchip/irq-loongarch-ir.c     | 3 +++
 drivers/irqchip/irq-loongson-htvec.c   | 6 ++++++
 drivers/irqchip/irq-loongson-liointc.c | 3 +++
 drivers/irqchip/irq-loongson-pch-pic.c | 3 +++
 drivers/irqchip/irq-riscv-intc.c       | 5 ++++-
 10 files changed, 37 insertions(+), 1 deletion(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2026-10-29  4:06 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-28  5:00 [PATCH 00/12] irqchip: validate remaining MADT records before use Jiale Yao
2026-10-28  5:00 ` Jiale Yao
2026-10-28  5:00 ` [PATCH 01/12] riscv: acpi: validate RINTC entries " Jiale Yao
2026-10-28  5:00 ` [PATCH 02/12] irqchip/gic-v5-irs: validate MADT GICC entries Jiale Yao
2026-10-28  5:00 ` [PATCH 03/12] irqchip/gic-v5-irs: validate MADT IRS entries Jiale Yao
2026-10-28  5:00 ` [PATCH 04/12] irqchip/gic-v5: validate MADT IRS records Jiale Yao
2026-10-28  5:00 ` [PATCH 05/12] irqchip/gic: validate MADT distributor records Jiale Yao
2026-10-28  5:00 ` [PATCH 06/12] irqchip/loongarch-avec: validate MADT MSI-PIC entries Jiale Yao
2026-10-28  5:00 ` [PATCH 07/12] irqchip/loongarch-ir: " Jiale Yao
2026-10-28  5:00 ` [PATCH 08/12] irqchip/loongson-htvec: validate MADT BIO-PIC entries Jiale Yao
2026-10-28  5:00 ` [PATCH 09/12] irqchip/loongson-htvec: validate MADT MSI-PIC entries Jiale Yao
2026-10-28  5:00 ` [PATCH 10/12] irqchip/loongson-liointc: validate MADT HT-PIC entries Jiale Yao
2026-10-28  8:23 ` [PATCH 00/12] irqchip: validate remaining MADT records before use Marc Zyngier
2026-10-28  8:23   ` Marc Zyngier
2026-10-29  4:01   ` jiale yao
2026-10-29  4:01     ` jiale yao

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.