diff options
Diffstat (limited to 'drivers/xen/events.c')
-rw-r--r-- | drivers/xen/events.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/drivers/xen/events.c b/drivers/xen/events.c index 2f57276e87a2..db8f506817f0 100644 --- a/drivers/xen/events.c +++ b/drivers/xen/events.c | |||
@@ -27,6 +27,7 @@ | |||
27 | #include <linux/module.h> | 27 | #include <linux/module.h> |
28 | #include <linux/string.h> | 28 | #include <linux/string.h> |
29 | #include <linux/bootmem.h> | 29 | #include <linux/bootmem.h> |
30 | #include <linux/slab.h> | ||
30 | 31 | ||
31 | #include <asm/ptrace.h> | 32 | #include <asm/ptrace.h> |
32 | #include <asm/irq.h> | 33 | #include <asm/irq.h> |
@@ -474,6 +475,9 @@ static void unbind_from_irq(unsigned int irq) | |||
474 | bind_evtchn_to_cpu(evtchn, 0); | 475 | bind_evtchn_to_cpu(evtchn, 0); |
475 | 476 | ||
476 | evtchn_to_irq[evtchn] = -1; | 477 | evtchn_to_irq[evtchn] = -1; |
478 | } | ||
479 | |||
480 | if (irq_info[irq].type != IRQT_UNBOUND) { | ||
477 | irq_info[irq] = mk_unbound_info(); | 481 | irq_info[irq] = mk_unbound_info(); |
478 | 482 | ||
479 | dynamic_irq_cleanup(irq); | 483 | dynamic_irq_cleanup(irq); |
@@ -646,9 +650,13 @@ void xen_evtchn_do_upcall(struct pt_regs *regs) | |||
646 | int bit_idx = __ffs(pending_bits); | 650 | int bit_idx = __ffs(pending_bits); |
647 | int port = (word_idx * BITS_PER_LONG) + bit_idx; | 651 | int port = (word_idx * BITS_PER_LONG) + bit_idx; |
648 | int irq = evtchn_to_irq[port]; | 652 | int irq = evtchn_to_irq[port]; |
653 | struct irq_desc *desc; | ||
649 | 654 | ||
650 | if (irq != -1) | 655 | if (irq != -1) { |
651 | handle_irq(irq, regs); | 656 | desc = irq_to_desc(irq); |
657 | if (desc) | ||
658 | generic_handle_irq_desc(irq, desc); | ||
659 | } | ||
652 | } | 660 | } |
653 | } | 661 | } |
654 | 662 | ||