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=-3.9 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_PASS autolearn=ham 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 2DD8CC5CFFE for ; Mon, 10 Dec 2018 21:26:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id ED3D120821 for ; Mon, 10 Dec 2018 21:26:41 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org ED3D120821 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linutronix.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729551AbeLJV0k (ORCPT ); Mon, 10 Dec 2018 16:26:40 -0500 Received: from Galois.linutronix.de ([146.0.238.70]:34444 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729172AbeLJV0j (ORCPT ); Mon, 10 Dec 2018 16:26:39 -0500 Received: from p4fea4820.dip0.t-ipconnect.de ([79.234.72.32] helo=nanos) by Galois.linutronix.de with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1gWT4R-0004eE-R4; Mon, 10 Dec 2018 22:26:32 +0100 Date: Mon, 10 Dec 2018 22:26:30 +0100 (CET) From: Thomas Gleixner To: Robin Murphy cc: hch@lst.de, m.szyprowski@samsung.com, iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, cai@gmx.us, salil.mehta@huawei.com, john.garry@huawei.com, Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , x86@kernel.org Subject: Re: [PATCH v3 5/7] x86/dma/amd-gart: Stop resizing dma_debug_entry pool In-Reply-To: Message-ID: References: User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 10 Dec 2018, Robin Murphy wrote: > dma-debug is now capable of adding new entries to its pool on-demand if > the initial preallocation was insufficient, so the IOMMU_LEAK logic no > longer needs to explicitly change the pool size. This does lose it the > ability to save a couple of megabytes of RAM by reducing the pool size > below its default, but it seems unlikely that that is a realistic > concern these days (or indeed that anyone is actively debugging AGP > drivers' DMA usage any more). Getting rid of dma_debug_resize_entries() > will make room for further streamlining in the dma-debug code itself. > > Removing the call reveals quite a lot of cruft which has been useless > for nearly a decade since commit 19c1a6f5764d ("x86 gart: reimplement > IOMMU_LEAK feature by using DMA_API_DEBUG"), including the entire > 'iommu=leak' parameter, which controlled nothing except whether > dma_debug_resize_entries() was called or not. > > CC: Thomas Gleixner > CC: Ingo Molnar > CC: Borislav Petkov > CC: "H. Peter Anvin" > CC: x86@kernel.org > Reviewed-by: Christoph Hellwig > Signed-off-by: Robin Murphy Acked-by: Thomas Gleixner From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Gleixner Subject: Re: [PATCH v3 5/7] x86/dma/amd-gart: Stop resizing dma_debug_entry pool Date: Mon, 10 Dec 2018 22:26:30 +0100 (CET) Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Robin Murphy Cc: x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, cai-0UDz38MK/Mo@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org, Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , hch-jcswGhMUV9g@public.gmane.org List-Id: iommu@lists.linux-foundation.org On Mon, 10 Dec 2018, Robin Murphy wrote: > dma-debug is now capable of adding new entries to its pool on-demand if > the initial preallocation was insufficient, so the IOMMU_LEAK logic no > longer needs to explicitly change the pool size. This does lose it the > ability to save a couple of megabytes of RAM by reducing the pool size > below its default, but it seems unlikely that that is a realistic > concern these days (or indeed that anyone is actively debugging AGP > drivers' DMA usage any more). Getting rid of dma_debug_resize_entries() > will make room for further streamlining in the dma-debug code itself. > > Removing the call reveals quite a lot of cruft which has been useless > for nearly a decade since commit 19c1a6f5764d ("x86 gart: reimplement > IOMMU_LEAK feature by using DMA_API_DEBUG"), including the entire > 'iommu=leak' parameter, which controlled nothing except whether > dma_debug_resize_entries() was called or not. > > CC: Thomas Gleixner > CC: Ingo Molnar > CC: Borislav Petkov > CC: "H. Peter Anvin" > CC: x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org > Reviewed-by: Christoph Hellwig > Signed-off-by: Robin Murphy Acked-by: Thomas Gleixner