lkml.org 
[lkml]   [2008]   [Apr]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Subject[PATCH 08 of 24] Re: [PATCH 08/12] xen: add resend_irq_on_evtchn() definition into events.c
    Date
    From
    From: Isaku Yamahata <yamahata@valinux.co.jp>

    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>
    ---
    drivers/xen/events.c | 16 ++++++++++++++++
    include/xen/events.h | 3 +--
    2 files changed, 17 insertions(+), 2 deletions(-)

    diff --git a/drivers/xen/events.c b/drivers/xen/events.c
    --- a/drivers/xen/events.c
    +++ b/drivers/xen/events.c
    @@ -586,6 +586,22 @@
    rebind_irq_to_cpu(irq, tcpu);
    }

    +int resend_irq_on_evtchn(unsigned int irq)
    +{
    + int masked, evtchn = evtchn_from_irq(irq);
    + struct shared_info *s = HYPERVISOR_shared_info;
    +
    + if (!VALID_EVTCHN(evtchn))
    + return 1;
    +
    + masked = sync_test_and_set_bit(evtchn, s->evtchn_mask);
    + sync_set_bit(evtchn, s->evtchn_pending);
    + if (!masked)
    + unmask_evtchn(evtchn);
    +
    + return 1;
    +}
    +
    static void enable_dynirq(unsigned int irq)
    {
    int evtchn = evtchn_from_irq(irq);
    diff --git a/include/xen/events.h b/include/xen/events.h
    --- a/include/xen/events.h
    +++ b/include/xen/events.h
    @@ -31,6 +31,7 @@
    void unbind_from_irqhandler(unsigned int irq, void *dev_id);

    void xen_send_IPI_one(unsigned int cpu, enum ipi_vector vector);
    +int resend_irq_on_evtchn(unsigned int irq);

    static inline void notify_remote_via_evtchn(int port)
    {



    \
     
     \ /
      Last update: 2008-04-02 20:45    [W:0.020 / U:0.580 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site