aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/xen
diff options
context:
space:
mode:
authorIsaku Yamahata <yamahata@valinux.co.jp>2008-04-02 13:53:57 -0400
committerIngo Molnar <mingo@elte.hu>2008-04-24 17:57:32 -0400
commit642e0c882cd5369429c833d97e4804c8be473e8a (patch)
treec9032832801bd68379b30983ce61fd80f823adb0 /drivers/xen
parente849c3e9e0b786619c451d89ef0c47ac9a28fbc1 (diff)
xen: add resend_irq_on_evtchn() definition into events.c
Define resend_irq_on_evtchn() which ia64/xen uses. Although it isn't used by current x86/xen code, it's arch generic so that put it into common code. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'drivers/xen')
-rw-r--r--drivers/xen/events.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/xen/events.c b/drivers/xen/events.c
index 2396b4492f70..4f0f22b020ea 100644
--- a/drivers/xen/events.c
+++ b/drivers/xen/events.c
@@ -586,6 +586,22 @@ static void set_affinity_irq(unsigned irq, cpumask_t dest)
586 rebind_irq_to_cpu(irq, tcpu); 586 rebind_irq_to_cpu(irq, tcpu);
587} 587}
588 588
589int resend_irq_on_evtchn(unsigned int irq)
590{
591 int masked, evtchn = evtchn_from_irq(irq);
592 struct shared_info *s = HYPERVISOR_shared_info;
593
594 if (!VALID_EVTCHN(evtchn))
595 return 1;
596
597 masked = sync_test_and_set_bit(evtchn, s->evtchn_mask);
598 sync_set_bit(evtchn, s->evtchn_pending);
599 if (!masked)
600 unmask_evtchn(evtchn);
601
602 return 1;
603}
604
589static void enable_dynirq(unsigned int irq) 605static void enable_dynirq(unsigned int irq)
590{ 606{
591 int evtchn = evtchn_from_irq(irq); 607 int evtchn = evtchn_from_irq(irq);