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.2 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 780B5C3A5A0 for ; Tue, 20 Aug 2019 02:15:00 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5190C22CE8 for ; Tue, 20 Aug 2019 02:15:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729154AbfHTCO5 (ORCPT ); Mon, 19 Aug 2019 22:14:57 -0400 Received: from verein.lst.de ([213.95.11.211]:52455 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729012AbfHTCO5 (ORCPT ); Mon, 19 Aug 2019 22:14:57 -0400 Received: by verein.lst.de (Postfix, from userid 2407) id B85B468B02; Tue, 20 Aug 2019 04:14:52 +0200 (CEST) Date: Tue, 20 Aug 2019 04:14:52 +0200 From: Christoph Hellwig To: Nicolin Chen Cc: Hillf Danton , Tobias Klausmann , Christoph Hellwig , kvalo@codeaurora.org, davem@davemloft.net, ath10k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, m.szyprowski@samsung.com, robin.murphy@arm.com, iommu@lists.linux-foundation.org, tobias.klausmann@freenet.de Subject: Re: regression in ath10k dma allocation Message-ID: <20190820021452.GA22792@lst.de> References: <8fe8b415-2d34-0a14-170b-dcb31c162e67@mni.thm.de> <20190816164301.GA3629@lst.de> <20190816222506.GA24413@Asurada-Nvidia.nvidia.com> <20190818031328.11848-1-hdanton@sina.com> <20190820015852.GA15830@Asurada-Nvidia.nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190820015852.GA15830@Asurada-Nvidia.nvidia.com> User-Agent: Mutt/1.5.17 (2007-11-01) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Mon, Aug 19, 2019 at 06:58:52PM -0700, Nicolin Chen wrote: > Right...the condition was in-between. However, not every caller > of dma_alloc_contiguous() is supposed to have a coherent check. > So we either add a 'bool coherent_ok' to the API or revert the > dma-direct part back to the original. Probably former option is > better? > > Thank you for the debugging. I have been a bit distracted, may > not be able to submit a fix very soon. Would you like to help? Yeah, it turns out that while the idea for the dma_alloc_contiguous helper was neat it didn't work out at all, and me pushing Nicolin down that route was not a very smart idea. Sorry for causing this mess. I think we'll just need to open code it for dma-direct for 5.3. Hillf do you want to cook up a patch or should I do it?