[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [RFC PATCH V5 06/14] xen: replace raw bit ops with functions



There is already a function called set_evtchn() for that job.

Signed-off-by: Wei Liu <wei.liu2@xxxxxxxxxx>
---
 drivers/xen/events.c |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/xen/events.c b/drivers/xen/events.c
index eca6488..6e226c3 100644
--- a/drivers/xen/events.c
+++ b/drivers/xen/events.c
@@ -1507,13 +1507,12 @@ static int set_affinity_irq(struct irq_data *data, 
const struct cpumask *dest,
 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 = test_and_set_mask(evtchn);
-       sync_set_bit(evtchn, BM(s->evtchn_pending));
+       set_evtchn(evtchn);
        if (!masked)
                unmask_evtchn(evtchn);
 
@@ -1555,14 +1554,13 @@ static void mask_ack_dynirq(struct irq_data *data)
 static int retrigger_dynirq(struct irq_data *data)
 {
        int evtchn = evtchn_from_irq(data->irq);
-       struct shared_info *sh = HYPERVISOR_shared_info;
        int ret = 0;
 
        if (VALID_EVTCHN(evtchn)) {
                int masked;
 
                masked = test_and_set_mask(evtchn);
-               sync_set_bit(evtchn, BM(sh->evtchn_pending));
+               set_evtchn(evtchn);
                if (!masked)
                        unmask_evtchn(evtchn);
                ret = 1;
-- 
1.7.10.4


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.