xen-devel
[Xen-devel] Re: [PATCH 10/13] xen/pvticket: allow interrupts to be enabl
To: |
Jeremy Fitzhardinge <jeremy@xxxxxxxx> |
Subject: |
[Xen-devel] Re: [PATCH 10/13] xen/pvticket: allow interrupts to be enabled while blocking |
From: |
Peter Zijlstra <peterz@xxxxxxxxxxxxx> |
Date: |
Fri, 02 Sep 2011 16:48:25 +0200 |
Cc: |
Xen Devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, Marcelo Tosatti <mtosatti@xxxxxxxxxx>, Nick Piggin <npiggin@xxxxxxxxx>, KVM <kvm@xxxxxxxxxxxxxxx>, maintainers <x86@xxxxxxxxxx>, Linux Kernel Mailing List <linux-kernel@xxxxxxxxxxxxxxx>, Andi Kleen <andi@xxxxxxxxxxxxxx>, Avi Kivity <avi@xxxxxxxxxx>, Jeremy Fitzhardinge <jeremy.fitzhardinge@xxxxxxxxxx>, "H. Peter Anvin" <hpa@xxxxxxxxx>, Ingo Molnar <mingo@xxxxxxx>, Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>, the |
Delivery-date: |
Fri, 02 Sep 2011 07:50:15 -0700 |
Envelope-to: |
www-data@xxxxxxxxxxxxxxxxxxx |
In-reply-to: |
<17a0f6177a71190dad30a6dcd1da93bec13a7836.1314922370.git.jeremy.fitzhardinge@xxxxxxxxxx> |
List-help: |
<mailto:xen-devel-request@lists.xensource.com?subject=help> |
List-id: |
Xen developer discussion <xen-devel.lists.xensource.com> |
List-post: |
<mailto:xen-devel@lists.xensource.com> |
List-subscribe: |
<http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe> |
List-unsubscribe: |
<http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe> |
References: |
<cover.1314922370.git.jeremy.fitzhardinge@xxxxxxxxxx> <17a0f6177a71190dad30a6dcd1da93bec13a7836.1314922370.git.jeremy.fitzhardinge@xxxxxxxxxx> |
Sender: |
xen-devel-bounces@xxxxxxxxxxxxxxxxxxx |
On Thu, 2011-09-01 at 17:55 -0700, Jeremy Fitzhardinge wrote:
> + /* Make sure an interrupt handler can't upset things in a
> + partially setup state. */
> local_irq_save(flags);
>
> + /*
> + * We don't really care if we're overwriting some other
> + * (lock,want) pair, as that would mean that we're currently
> + * in an interrupt context, and the outer context had
> + * interrupts enabled. That has already kicked the VCPU out
> + * of xen_poll_irq(), so it will just return spuriously and
> + * retry with newly setup (lock,want).
> + *
> + * The ordering protocol on this is that the "lock" pointer
> + * may only be set non-NULL if the "want" ticket is correct.
> + * If we're updating "want", we must first clear "lock".
> + */
> + w->lock = NULL;
I mean, I don't much care about Xen code, but that's two different
comment styles.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- [Xen-devel] [PATCH 03/13] xen/pvticketlock: Xen implementation for PV ticket locks, (continued)
- [Xen-devel] [PATCH 03/13] xen/pvticketlock: Xen implementation for PV ticket locks, Jeremy Fitzhardinge
- [Xen-devel] [PATCH 04/13] x86/pvticketlock: use callee-save for lock_spinning, Jeremy Fitzhardinge
- [Xen-devel] [PATCH 01/13] x86/spinlocks: replace pv spinlocks with pv ticketlocks, Jeremy Fitzhardinge
- [Xen-devel] [PATCH 11/13] x86/ticketlock: only do kick after doing unlock, Jeremy Fitzhardinge
- [Xen-devel] [PATCH 12/13] x86/pvticketlock: make sure unlock_kick pvop call is inlined, Jeremy Fitzhardinge
- [Xen-devel] [PATCH 09/13] x86/pvticketlocks: we only need to kick if there's waiters, Jeremy Fitzhardinge
- [Xen-devel] [PATCH 05/13] x86/ticketlocks: when paravirtualizing ticket locks, increment by 2, Jeremy Fitzhardinge
- [Xen-devel] [PATCH 10/13] xen/pvticket: allow interrupts to be enabled while blocking, Jeremy Fitzhardinge
- [Xen-devel] Re: [PATCH 10/13] xen/pvticket: allow interrupts to be enabled while blocking,
Peter Zijlstra <=
- [Xen-devel] [PATCH 08/13] xen/pvticketlock: disable interrupts while blocking, Jeremy Fitzhardinge
|
|
|