From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 1695ADDE05 for ; Wed, 21 May 2008 08:02:27 +1000 (EST) Subject: Re: [PATCH] [POWERPC] Improve (in|out)_beXX() asm code From: Benjamin Herrenschmidt To: Scott Wood In-Reply-To: <483344C0.3020703@freescale.com> References: <1211316025-29069-1-git-send-email-tpiepho@freescale.com> <1211318219.8297.177.camel@pasglop> <483344C0.3020703@freescale.com> Content-Type: text/plain Date: Tue, 20 May 2008 18:02:18 -0400 Message-Id: <1211320938.8297.179.camel@pasglop> Mime-Version: 1.0 Cc: linuxppc-dev@ozlabs.org, Trent Piepho , linux-kernel@vger.kernel.org Reply-To: benh@kernel.crashing.org List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On Tue, 2008-05-20 at 16:38 -0500, Scott Wood wrote: > It looks like we rely on -fno-strict-aliasing to prevent reordering > ordinary memory accesses (such as to DMA descriptors) past the I/O > access. It won't prevent reordering of memory reads around an I/O > read, > though, which could be a problem if the I/O read result determines > the > validity of the DMA buffer. IMHO, a memory clobber would be better. We probably want a full "memory" clobber then... Ben.