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

Re: [Xen-devel] [PATCH 5/6] xen/arm: Only enable physical IRQs when the guest asks





On 12/06/2013 05:26 PM, Stefano Stabellini wrote:
From: Julien Grall <julien.grall@xxxxxxxxxx>

From: Julien Grall <julien.grall@xxxxxxxxxx>

Set/Unset IRQ_DISABLED from gic_irq_enable and gic_irq_disable.
Enable IRQs when the guest requests it, not unconditionally at boot time.

Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Signed-off-by: Julien Grall <julien.grall@xxxxxxxxxx>
---

[..]

@@ -605,6 +603,8 @@ int __init setup_dt_irq(const struct dt_irq *irq, struct 
irqaction *new)

      rc = __setup_irq(desc, irq->irq, new);

+    desc->handler->startup(desc);
+

You forgot to take the GIC lock here.

      spin_unlock_irqrestore(&desc->lock, flags);

      return rc;
@@ -743,6 +743,7 @@ int gic_route_irq_to_guest(struct domain *d, const struct 
dt_irq *irq,
      unsigned long flags;
      int retval;
      bool_t level;
+    struct pending_irq *p;

      action = xmalloc(struct irqaction);
      if (!action)
@@ -769,6 +770,10 @@ int gic_route_irq_to_guest(struct domain *d, const struct 
dt_irq *irq,
          goto out;
      }

+    /* do not assume delivery to vcpu0 */

I would add TODO: in the comment.

--
Julien Grall

_______________________________________________
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®.