HomeFreeBSD

xen/intr: add check for intr_register_source() errors

Description

xen/intr: add check for intr_register_source() errors

While unusual, intr_register_source() can return failure. A likely
cause might be another device grabbing from Xen's interrupt range.
This should NOT happen, but could happen due to a bug. As such check
for this and fail if it occurs.

This theoretical situation also effects xen_intr_find_unused_isrc().
There, .is_pic must be tested to ensure such an intrusion doesn't cause
misbehavior.

Reviewed by: royger
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D31995

Details

Provenance
ehem_freebsd_m5p.comAuthored on Sep 13 2021, 6:12 AM
roygerCommitted on Mar 29 2023, 7:51 AM
Reviewer
royger
Differential Revision
D31995: xen/intr: add check for intr_register_source() errors
Parents
rG1797ff962769: xen/intr: cleanup event channel number use
Branches
Unknown
Tags
Unknown