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=-7.0 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED 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 A3DBEC433E8 for ; Fri, 24 Jul 2020 09:37:04 +0000 (UTC) Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (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 69D71206EB for ; Fri, 24 Jul 2020 09:37:04 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 69D71206EB Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=iommu-bounces@lists.linux-foundation.org Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 1442B2044D; Fri, 24 Jul 2020 09:37:04 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id l4xucKu3V6e4; Fri, 24 Jul 2020 09:37:03 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by silver.osuosl.org (Postfix) with ESMTP id 1F5272033D; Fri, 24 Jul 2020 09:37:03 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 0369DC004D; Fri, 24 Jul 2020 09:37:03 +0000 (UTC) Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by lists.linuxfoundation.org (Postfix) with ESMTP id 8F2E6C004C for ; Fri, 24 Jul 2020 09:37:00 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 7A2E88846C for ; Fri, 24 Jul 2020 09:37:00 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tVSeKDKuFmcS for ; Fri, 24 Jul 2020 09:36:59 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by whitealder.osuosl.org (Postfix) with ESMTPS id 8579F88467 for ; Fri, 24 Jul 2020 09:36:59 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 28B63ACC5; Fri, 24 Jul 2020 09:37:06 +0000 (UTC) Message-ID: <0dc1e922bf87fa73790e7471b3974528dd261486.camel@suse.de> Subject: Re: [PATCH] dma-pool: Do not allocate pool memory from CMA From: Nicolas Saenz Julienne To: Amit Pundir Date: Fri, 24 Jul 2020 11:36:55 +0200 In-Reply-To: References: <20200708164936.9340-1-nsaenzjulienne@suse.de> <550b30a86c0785049d24c945e2c6628d491cee3a.camel@suse.de> <011994f8a717a00dcd9ed7682a1ddeb421c2c43f.camel@suse.de> <01831596e4a2a6c9c066138b23bd30435f8e5569.camel@suse.de> <6db722947546221ed99d3f473f78e1a6de65d7d6.camel@suse.de> User-Agent: Evolution 3.36.3-0ubuntu1 MIME-Version: 1.0 Cc: lkml , jeremy.linton@arm.com, Sumit Semwal , iommu@lists.linux-foundation.org, John Stultz , linux-rpi-kernel@lists.infradead.org, David Rientjes , Robin Murphy , Christoph Hellwig X-BeenThere: iommu@lists.linux-foundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Development issues for Linux IOMMU support List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: iommu-bounces@lists.linux-foundation.org Sender: "iommu" Hi Amit, On Thu, 2020-07-23 at 10:44 +0530, Amit Pundir wrote: > Hi Nicolas, > > Sorry I got stuck on other things yesterday. No worries :) > On Tue, 21 Jul 2020 at 21:57, Nicolas Saenz Julienne [...] > > > > Let's get a bigger hammer, I'm just looking for clues here. Can you > > apply this and provide the dmesg output. > > > > diff --git a/kernel/dma/pool.c b/kernel/dma/pool.c > > index 6bc74a2d5127..2160676bf488 100644 > > --- a/kernel/dma/pool.c > > +++ b/kernel/dma/pool.c > > @@ -268,6 +268,8 @@ void *dma_alloc_from_pool(struct device *dev, size_t size, > > schedule_work(&atomic_pool_work); > > } > > > > + dev_info(dev, "%s: size %lx, phys addr %llx, flags 0x%x\n", __func__, size, phys, flags); > > + > > return ptr; > > } > > I never made it to dma_alloc_from_pool() call from > dma_direct_alloc_pages(), dma_should_alloc_from_pool() returns False > from gfpflags_allow_blocking() block. I'm a little sceptical about this. The only way you can get memory from these pools is through dma_alloc_from_pool(), and given how changes in the pool initialization affected the phone, it's pretty clear some amount of pool allocation is happening. Regards, Nicolas _______________________________________________ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu