[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v2] x86/irq: introduce APIC_VECTOR_VALID()
On Monday, March 24th, 2025 at 5:36 AM, Jan Beulich <jbeulich@xxxxxxxx> wrote: > > > On 21.03.2025 00:05, dmkhn@xxxxxxxxx wrote: > > > Add new macro APIC_VECTOR_VALID() to validate the interrupt vector > > range as per [1]. This macro replaces hardcoded checks against the > > open-coded value 16 in LAPIC and virtual LAPIC code and simplifies > > the code a bit. > > > > [1] Intel SDM volume 3A > > Chapter "ADVANCED PROGRAMMABLE INTERRUPT CONTROLLER" > > Section "Valid Interrupt Vectors" > > > > Signed-off-by: Denis Mukhin dmukhin@xxxxxxxx > > > Reviewed-by: Jan Beulich jbeulich@xxxxxxxx > > with ... > > > --- a/xen/arch/x86/include/asm/apicdef.h > > +++ b/xen/arch/x86/include/asm/apicdef.h > > @@ -78,6 +78,7 @@ > > #define APIC_DM_STARTUP 0x00600 > > #define APIC_DM_EXTINT 0x00700 > > #define APIC_VECTOR_MASK 0x000FF > > +#define APIC_VECTOR_VALID(x) (((x) & APIC_VECTOR_MASK) >= 16) > > > ... line length restrictions respected here. I'll see about taking care of > this while committing, provided other x86 maintainers wouldn't prefer this > to not go in in the first place (so I'll also give it another day or two). Thanks! > > Jan
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |