From: Lukas Hejtmanek Subject: [ofa-general] Re: mthca use of dma_sync_single is bogus Date: Tue, 10 Jul 2007 21:16:39 +0200 Message-ID: <20070710191639.GL3885@ics.muni.cz> References: <20070709213913.GB20052@mellanox.co.il> <20070710141409.GH3885@ics.muni.cz> <20070710190018.GK3885@ics.muni.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Transfer-Encoding: quoted-printable Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: general-bounces@lists.openfabrics.org Errors-To: general-bounces@lists.openfabrics.org To: Roland Dreier Cc: Keir Fraser , xen-devel@lists.xensource.com, "Michael S. Tsirkin" , general@lists.openfabrics.org List-Id: xen-devel@lists.xenproject.org On Tue, Jul 10, 2007 at 12:08:43PM -0700, Roland Dreier wrote: > > I think he spoke about coherent, didn't he? On i386/x86_64, the cons= istent and > > coherent are the same but on some architectures they are not and I t= hink that > > using consistent (in particular pci_alloc_consistent) is exactly wha= t should > > be used. Keir also recommended to use this one. >=20 > coherent and consistent are synonyms. It's confusing because there is > pci_alloc_consistent(), which is in general just a wrapper for > dma_alloc_coherent(). According to DMA-mapping.txt they are not. Alpha, M68000 wihtout MMU, PPC= , Sparc, Sparc64, V850 have own implementation of pci_alloc_consistent(). Yes, on i386, the pci_alloc_consistent() is just wrapper for dma_alloc_coherent(). > > And moreover, it avoids using swiotlb and bounce buffers, I think. A= m I right, > > Keir? >=20 > Yes, but I'm not really willing to make things worse for standard i386 > just to make Xen work a little better. So, what about some #ifdefs ? E.g., allow config option - Xen optimizatio= ns? --=20 Luk=E1=B9 Hejtm=E1nek