Commit 6ecc2e79 authored by Jacob Pan's avatar Jacob Pan Committed by Thomas Gleixner

x86/irq: Use existing helper for pending vector check

lapic_vector_set_in_irr() is already available, use it for checking
pending vectors at the local APIC. No functional change.
Signed-off-by: default avatarJacob Pan <jacob.jun.pan@linux.intel.com>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Reviewed-by: default avatarImran Khan <imran.f.khan@oracle.com>
Link: https://lore.kernel.org/r/20240506175612.1141095-1-jacob.jun.pan@linux.intel.com
parent ed1e48ea
......@@ -503,13 +503,7 @@ static inline bool lapic_vector_set_in_irr(unsigned int vector)
static inline bool is_vector_pending(unsigned int vector)
{
unsigned int irr;
irr = apic_read(APIC_IRR + (vector / 32 * 0x10));
if (irr & (1 << (vector % 32)))
return true;
return pi_pending_this_cpu(vector);
return lapic_vector_set_in_irr(vector) || pi_pending_this_cpu(vector);
}
/*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment