From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.3 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1D60DC433FF for ; Wed, 14 Aug 2019 14:34:56 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id AE2E52083B for ; Wed, 14 Aug 2019 14:34:55 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org AE2E52083B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 467sYT1yDNzDqv1 for ; Thu, 15 Aug 2019 00:34:53 +1000 (AEST) Authentication-Results: lists.ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lst.de (client-ip=213.95.11.211; helo=verein.lst.de; envelope-from=hch@lst.de; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=lst.de Received: from verein.lst.de (verein.lst.de [213.95.11.211]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 467sJc2NLLzDqs8 for ; Thu, 15 Aug 2019 00:23:38 +1000 (AEST) Received: by verein.lst.de (Postfix, from userid 2407) id 6C2D668B02; Wed, 14 Aug 2019 16:23:32 +0200 (CEST) Date: Wed, 14 Aug 2019 16:23:32 +0200 From: Christoph Hellwig To: Christophe Leroy Subject: Re: [PATCH] powerpc: use the generic dma coherent remap allocator Message-ID: <20190814142332.GA8873@lst.de> References: <20190814132230.31874-1-hch@lst.de> <20190814132230.31874-2-hch@lst.de> <34961f3c-e859-49a0-834f-0342bf1f7974@c-s.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <34961f3c-e859-49a0-834f-0342bf1f7974@c-s.fr> User-Agent: Mutt/1.5.17 (2007-11-01) X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linuxppc-dev@lists.ozlabs.org, Paul Mackerras , Christoph Hellwig Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" On Wed, Aug 14, 2019 at 04:20:34PM +0200, Christophe Leroy wrote: >> index 56a7c814160d..afe71b89dec3 100644 >> --- a/arch/powerpc/platforms/Kconfig.cputype >> +++ b/arch/powerpc/platforms/Kconfig.cputype >> @@ -450,8 +450,10 @@ config NOT_COHERENT_CACHE >> depends on 4xx || PPC_8xx || E200 || PPC_MPC512x || \ >> GAMECUBE_COMMON || AMIGAONE >> select ARCH_HAS_DMA_COHERENT_TO_PFN > > You drop arch_dma_coherent_to_pfn(), it's surprising to see > ARCH_HAS_DMA_COHERENT_TO_PFN remains. At first I thought I'd get a build > failure. > > After looking more, I see there is a arch_dma_coherent_to_pfn() > defined in kernel/dma/remap.c when DMA_DIRECT_REMAP is selected. > > I think the naming is not really consistant and should be fixed some how, > because that's misleading to have an arch_something() being common to all. I actually have patches in the queue kill arch_dma_coherent_to_pfn off entirely, as we can always just get back to the physical address and thus pfn from the dma address using dma_to_phys for dma-direct. But there is a huge review backlog for my outstanding dma patcheset, so it might take a bit until it is posted.