From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:51858) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0s2v-0002BG-AJ for qemu-devel@nongnu.org; Tue, 06 Sep 2011 05:34:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R0s2u-0003zJ-3k for qemu-devel@nongnu.org; Tue, 06 Sep 2011 05:34:21 -0400 Received: from mx1.redhat.com ([209.132.183.28]:26601) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0s2t-0003zF-SB for qemu-devel@nongnu.org; Tue, 06 Sep 2011 05:34:20 -0400 Date: Tue, 6 Sep 2011 12:35:14 +0300 From: "Michael S. Tsirkin" Message-ID: <20110906093514.GD16091@redhat.com> References: <20110901163359.GB11620@redhat.com> <786649703.1049386.1314909069542.JavaMail.root@zmail07.collab.prod.int.phx2.redhat.com> <20110902154549.GA18368@redhat.com> <20110903144635.GD12965@yookeroo.fritz.box> <20110904091643.GA20795@redhat.com> <20110905044316.GD30278@yookeroo.fritz.box> <20110905091945.GC16038@redhat.com> <20110906031224.GH30278@yookeroo.fritz.box> <4E65C3EE.1090407@redhat.com> <4E65E7C8.4080602@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4E65E7C8.4080602@redhat.com> Subject: Re: [Qemu-devel] [PATCH] virtio: Make memory barriers be memory barriers List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Avi Kivity Cc: aliguori@us.ibm.com, aik@ozlabs.ru, rusty@rustcorp.com.au, qemu-devel@nongnu.org, agraf@suse.de, Paolo Bonzini On Tue, Sep 06, 2011 at 12:28:40PM +0300, Avi Kivity wrote: > On 09/06/2011 09:55 AM, Paolo Bonzini wrote: > >On 09/06/2011 05:12 AM, David Gibson wrote: > >>I'm not "fixing ppc". I'm fixing a fundamental flaw in the protocol > >>implementation._So far_ I've only observed the effects on ppc, but > >>that doesn't mean they don't exist. > > > >Actually Michael is right. The implementation is correct on x86, > >though wrong anywhere else (perhaps s390?). On those > >architectures you do not need rmb() and wmb(). > > Are we sure? Nothing prevents the guest from using weakly-ordered > writes, is there? For example, using MOVNTDQ. Yes but the macros in question are here to order qemu accesses, not guest accesses. > > Although in that case the guest is probably required to issue an SFENCE. > -- > error compiling committee.c: too many arguments to function