xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Tim Deegan <tim@xen.org>
To: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Cc: Ian.Campbell@citrix.com, xen-devel@lists.xensource.com,
	Tim.Deegan@citrix.com, david.vrabel@citrix.com
Subject: Re: [PATCH 3/5] xen/gic: support injecting IRQs even to VCPUs not currently running
Date: Thu, 7 Jun 2012 13:46:06 +0100	[thread overview]
Message-ID: <20120607124606.GT70339@ocelot.phlegethon.org> (raw)
In-Reply-To: <1338981730-14816-3-git-send-email-stefano.stabellini@eu.citrix.com>

At 12:22 +0100 on 06 Jun (1338985328), Stefano Stabellini wrote:
> +static void gic_restore_pending_irqs(struct vcpu *v)
> +{
> +    int i;
> +    struct pending_irq *p;
> +
> +    /* check for new pending irqs */
> +    if ( list_empty(&v->arch.vgic.lr_pending) )
> +        return;
> +
> +    list_for_each_entry ( p, &v->arch.vgic.lr_pending, lr_queue )
> +    {
> +        i = find_first_zero_bit(&gic.lr_mask, nr_lrs);
> +        if ( i < nr_lrs )
> +        {
> +            gic_set_lr(i, p->irq, GICH_LR_PENDING, p->priority);
> +            list_del_init(&p->lr_queue);
> +            set_bit(i, &gic.lr_mask);
> +            if ( p->irq == VGIC_IRQ_EVTCHN_CALLBACK )
> +                set_bit(i, &gic.event_mask);
> +        } else
> +        {
> +            return;
> +        }

This is a bit ugly - maybe "if ( i >= nr_lrs ) return" above and don't
indent the block?

  reply	other threads:[~2012-06-07 12:46 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-06 11:20 [PATCH 0/5] xen/arm: multiple guests support in the GIC and VGIC Stefano Stabellini
2012-06-06 11:22 ` [PATCH 1/5] arm/vtimer: do not let the guest interact with the physical timer Stefano Stabellini
2012-06-06 11:22   ` [PATCH 2/5] arm/gic: fix gic context switch Stefano Stabellini
2012-06-26 13:55     ` Ian Campbell
2012-06-06 11:22   ` [PATCH 3/5] xen/gic: support injecting IRQs even to VCPUs not currently running Stefano Stabellini
2012-06-07 12:46     ` Tim Deegan [this message]
2012-06-07 15:43       ` Stefano Stabellini
2012-06-26 14:07       ` Ian Campbell
2012-06-26 17:28         ` Stefano Stabellini
2012-06-06 11:22   ` [PATCH 4/5] xen/vgic: vgic: support irq enable/disable Stefano Stabellini
2012-06-26 14:05     ` Ian Campbell
2012-06-06 11:22   ` [PATCH 5/5] xen/vgic: initialize pending_irqs.lr_queue Stefano Stabellini
2012-06-26 14:08     ` Ian Campbell
2012-06-26 17:53       ` Stefano Stabellini
2012-06-27  8:52         ` Ian Campbell
2012-06-27 11:06           ` Stefano Stabellini
2012-06-26 13:55   ` [PATCH 1/5] arm/vtimer: do not let the guest interact with the physical timer Ian Campbell
2012-06-26 17:25     ` Stefano Stabellini
2012-06-07 12:47 ` [PATCH 0/5] xen/arm: multiple guests support in the GIC and VGIC Tim Deegan
2012-06-07 15:47   ` Stefano Stabellini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120607124606.GT70339@ocelot.phlegethon.org \
    --to=tim@xen.org \
    --cc=Ian.Campbell@citrix.com \
    --cc=Tim.Deegan@citrix.com \
    --cc=david.vrabel@citrix.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).