diff options
author | Keir Fraser <keir@xen.org> | 2011-04-02 16:06:12 +0100 |
---|---|---|
committer | Keir Fraser <keir@xen.org> | 2011-04-02 16:06:12 +0100 |
commit | 78134e0480c642b82a2b753dd26fc4b848331c16 (patch) | |
tree | 1eaf7dab6bf74a2004c32ce25a77584048fcf3e1 | |
parent | 5670cfc8b61b349109dfd3ab9fbbc34e0dc9cae2 (diff) | |
download | xen-78134e0480c642b82a2b753dd26fc4b848331c16.tar.gz xen-78134e0480c642b82a2b753dd26fc4b848331c16.tar.bz2 xen-78134e0480c642b82a2b753dd26fc4b848331c16.zip |
x86: __pirq_guest_eoi() must check it is called for a fully
guest-bound irq before accessing desc->action.
Signed-off-by: Keir Fraser <keir@xen.org>
xen-unstable changeset: 23103:48dac730a93b
xen-unstable date: Sat Mar 26 09:42:01 2011 +0000
-rw-r--r-- | xen/arch/x86/irq.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/xen/arch/x86/irq.c b/xen/arch/x86/irq.c index 3275b2d07c..1fdc295138 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; |