From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751868AbdJCLnd (ORCPT ); Tue, 3 Oct 2017 07:43:33 -0400 Received: from verein.lst.de ([213.95.11.211]:43250 "EHLO newverein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751604AbdJCLnc (ORCPT ); Tue, 3 Oct 2017 07:43:32 -0400 Date: Tue, 3 Oct 2017 13:43:30 +0200 From: Christoph Hellwig To: Christophe LEROY Cc: Christoph Hellwig , iommu@lists.linux-foundation.org, Chris Zankel , Michal Simek , linux-ia64@vger.kernel.org, linux-mips@linux-mips.org, linux-sh@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-xtensa@linux-xtensa.org, x86@kernel.org, linux-kernel@vger.kernel.org, David Howells , Max Filippov , Guan Xuetao , Robin Murphy , Marek Szyprowski Subject: Re: [PATCH 07/11] powerpc: make dma_cache_sync a no-op Message-ID: <20171003114330.GA24592@lst.de> References: <20171003104311.10058-1-hch@lst.de> <20171003104311.10058-8-hch@lst.de> <670a0571-1a36-51a3-db52-64bc61184c35@c-s.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <670a0571-1a36-51a3-db52-64bc61184c35@c-s.fr> User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 03, 2017 at 01:24:57PM +0200, Christophe LEROY wrote: >> powerpc does not implement DMA_ATTR_NON_CONSISTENT allocations, so it >> doesn't make any sense to do any work in dma_cache_sync given that it >> must be a no-op when dma_alloc_attrs returns coherent memory. > What about arch/powerpc/mm/dma-noncoherent.c ? > > Powerpc 8xx doesn't have coherent memory. It doesn't implement the DMA_ATTR_NON_CONSISTENT interface either, so if it really doesn't have a way to provide dma coherent allocation (although the code in __dma_alloc_coherent suggests it does provide dma coherent allocations) I have no idea how it could ever have worked.