β¬’ DragonFlyBSD Kernel Audit
← triage Β· dashboard
DF-4954

mpr_pci_setup_interrupts: bus_setup_intr failure truncates msi_msgs before the failing queue, permanently leaking its allocated IRQ resource and (via ignored EBUSY) the MSI message

Summary

The error branch rewrites the loop bound the teardown depends on instead of releasing the just-allocated irq - the failing queue's SYS_RES_IRQ is never released and pci_release_msi hits EBUSY (ignored). Rman+vector exhaustion on attach-error/retry. Hw-gated. Release-before-break fix.

Discussion (0)

No comments yet.

PoC verification

Evidence pack

findings/poc/DF-4954 Β· 1 files
FileTypeDescriptionSize
verdict.json file 1.0 KB view raw

Fix verification

not_testable
per-fix-DF-4954

Confirmed kernel references

Detail

Exploit chain

attach-time bus_setup_intr failure under irq/vector pressure -> truncated msi_msgs skips queue i in every teardown -> IRQ rle + MSI message leaked for the device lifetime, blocking re-attach

Evidence (decisive lines)

findings/poc/DF-4954/ (this verdict; code-trace proof)

Verdict

Hardware-gated (no MPT3 HBA on guest): bus_setup_intr failure sets msi_msgs=i BEFORE releasing the just-allocated q->irq for queue i - every teardown loop iterates ires!=NULL -> EBUSY (ignored), so the MSI message leaks too. Rman resource + vector exhaustion on attach-error/retry paths. Release-before-break fix (mirrors upstream mps/mpr).