public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xen: Use wmb instead of rmb in xen_evtchn_do_upcall().
@ 2008-06-10  7:35 Isaku Yamahata
  2008-06-10  7:41 ` Nick Piggin
  0 siblings, 1 reply; 7+ messages in thread
From: Isaku Yamahata @ 2008-06-10  7:35 UTC (permalink / raw)
  To: jeremy; +Cc: linux-kernel, virtualization, xen-ia64-devel, Samuel Thibault

This patch is ported one from 534:77db69c38249 of linux-2.6.18-xen.hg.
Use wmb instead of rmb to enforce ordering between
evtchn_upcall_pending and evtchn_pending_sel stores
in xen_evtchn_do_upcall().

Cc: Samuel Thibault <samuel.thibault@eu.citrix.com>
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
---
 drivers/xen/events.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/xen/events.c b/drivers/xen/events.c
index 73d78dc..332dd63 100644
--- a/drivers/xen/events.c
+++ b/drivers/xen/events.c
@@ -529,7 +529,7 @@ void xen_evtchn_do_upcall(struct pt_regs *regs)
 
 #ifndef CONFIG_X86 /* No need for a barrier -- XCHG is a barrier on x86. */
 		/* Clear master flag /before/ clearing selector flag. */
-		rmb();
+		wmb();
 #endif
 		pending_words = xchg(&vcpu_info->evtchn_pending_sel, 0);
 		while (pending_words != 0) {
-- 
1.5.3

^ permalink raw reply related	[flat|nested] 7+ messages in thread
* [PATCH] xen: Use wmb instead of rmb in xen_evtchn_do_upcall().
@ 2008-06-16 21:58 Jeremy Fitzhardinge
  0 siblings, 0 replies; 7+ messages in thread
From: Jeremy Fitzhardinge @ 2008-06-16 21:58 UTC (permalink / raw)
  To: the arch/x86 maintainers
  Cc: Linux Kernel Mailing List, Isaku Yamahata, Samuel Thibault,
	Nick Piggin

From: Isaku Yamahata <yamahata@valinux.co.jp>

This patch is ported one from 534:77db69c38249 of linux-2.6.18-xen.hg.
Use wmb instead of rmb to enforce ordering between
evtchn_upcall_pending and evtchn_pending_sel stores
in xen_evtchn_do_upcall().

Cc: Samuel Thibault <samuel.thibault@eu.citrix.com>
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
---
 drivers/xen/events.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

===================================================================
--- a/drivers/xen/events.c
+++ b/drivers/xen/events.c
@@ -529,7 +529,7 @@ void xen_evtchn_do_upcall(struct pt_regs *regs)
 
 #ifndef CONFIG_X86 /* No need for a barrier -- XCHG is a barrier on x86. */
 		/* Clear master flag /before/ clearing selector flag. */
-		rmb();
+		wmb();
 #endif
 		pending_words = xchg(&vcpu_info->evtchn_pending_sel, 0);
 		while (pending_words != 0) {
-- 
1.5.3




^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2008-06-16 21:59 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-10  7:35 [PATCH] xen: Use wmb instead of rmb in xen_evtchn_do_upcall() Isaku Yamahata
2008-06-10  7:41 ` Nick Piggin
2008-06-10  7:57   ` Jeremy Fitzhardinge
2008-06-10  8:15     ` Nick Piggin
2008-06-11  6:54       ` Jeremy Fitzhardinge
2008-06-10  8:01   ` Isaku Yamahata
  -- strict thread matches above, loose matches on Subject: below --
2008-06-16 21:58 Jeremy Fitzhardinge

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox