From 4d21248c007f0b688d41d9282e69e0d6cbde3ece Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Sat, 26 Mar 2011 09:42:01 +0000 Subject: [PATCH] x86: __pirq_guest_eoi() must check it is called for a fully guest-bound irq before accessing desc->action. Signed-off-by: Keir Fraser --- xen/arch/x86/irq.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/xen/arch/x86/irq.c b/xen/arch/x86/irq.c index 3595ef5271..ab2e6c9993 100644 --- a/xen/arch/x86/irq.c +++ b/xen/arch/x86/irq.c @@ -1022,6 +1022,12 @@ static void __pirq_guest_eoi(struct domain *d, int pirq) if ( desc == NULL ) return; + if ( !(desc->status & IRQ_GUEST) ) + { + spin_unlock_irq(&desc->lock); + return; + } + action = (irq_guest_action_t *)desc->action; irq = desc - irq_desc; -- 2.39.5