From patchwork Mon Mar 23 14:49:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Vetter X-Patchwork-Id: 11453105 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8D4E592A for ; Mon, 23 Mar 2020 14:50:04 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 6BCC620753 for ; Mon, 23 Mar 2020 14:50:04 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=ffwll.ch header.i=@ffwll.ch header.b="BPGIbJ7z" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6BCC620753 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ffwll.ch Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=intel-gfx-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DD5236E12A; Mon, 23 Mar 2020 14:50:00 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by gabe.freedesktop.org (Postfix) with ESMTPS id 96E0A6E127 for ; Mon, 23 Mar 2020 14:50:00 +0000 (UTC) Received: by mail-wm1-x344.google.com with SMTP id r7so210957wmg.0 for ; Mon, 23 Mar 2020 07:50:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=tjiv7qMnzgqOGQnKm8diVuhQQwwy6h5FYe6sb8SS/Og=; b=BPGIbJ7zUeLKeMCPq3sTvwhWi2D36jWS3OLlIdaEwHqhCbqnJTzttVjGq1mCMgDw53 Ky4M0wRmf1jUv9n7w37UFxWMjX7B0KIWOWYQBgCTpNDpXDOa6ZYoPGZ3MbtLTD27elF6 sG6bBnDAUMGgjEPRVAVuPaiH+zAn3TITFyJb4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=tjiv7qMnzgqOGQnKm8diVuhQQwwy6h5FYe6sb8SS/Og=; b=n+NIpFX/E3eQxzXyaNAjIpi8b1e+2Bsu7RUnqg/fAMJqWdwgwHohm3MlnDrZ+TM2ct Ep7Zuc/xoM0MP/Yhtew0veri7nBmO5ff0pCxM90vfSRXGzbr53tbLk7w0/lZKAQp99mb vFRU/BNF9ifciewL6MFNqXtAKMF9RQ4Kdb9QEM+jMVJtV3ccTinWZtDs5X4z1X2jDffb 5HeJ0oRAGub25lLTVNDmkXwitlBmMrguZm3/HOK+xtoYX4rQxZ0LOBVq4Kgc/1T8aN/6 bzoOtzTUhvNLvnCmxolhV3VR5tFmfIKAqAWDWbgnVsDN6/+7POpo3sEP1VyBoTuGlIQF ilLw== X-Gm-Message-State: ANhLgQ1p32st78cKs7gPE5kg35+dF/Pz7q7Qqa2CmCddgm5ISVrAvxhy tRBxpMUMCNB6pAYYx7bHGAntXA== X-Google-Smtp-Source: ADFU+vuIcvgB7enp1CCTvo6W5k+yimEtNaCgQhAy5LcBILNPuMVXRkdi3TkezLvpFn4vmaOSttl9DA== X-Received: by 2002:a1c:b4d4:: with SMTP id d203mr28192120wmf.85.1584974998322; Mon, 23 Mar 2020 07:49:58 -0700 (PDT) Received: from phenom.ffwll.local ([2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa]) by smtp.gmail.com with ESMTPSA id s22sm20376522wmc.16.2020.03.23.07.49.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Mar 2020 07:49:57 -0700 (PDT) From: Daniel Vetter To: DRI Development Date: Mon, 23 Mar 2020 15:49:00 +0100 Message-Id: <20200323144950.3018436-2-daniel.vetter@ffwll.ch> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200323144950.3018436-1-daniel.vetter@ffwll.ch> References: <20200323144950.3018436-1-daniel.vetter@ffwll.ch> MIME-Version: 1.0 Subject: [Intel-gfx] [PATCH 01/51] mm/sl[uo]b: export __kmalloc_track(_node)_caller X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-mm@kvack.org, Daniel Vetter , Intel Graphics Development , Pekka Enberg , Joonsoo Kim , David Rientjes , Daniel Vetter , Christoph Lameter , Andrew Morton Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" slab does this already, and I want to use this in a memory allocation tracker in drm for stuff that's tied to the lifetime of a drm_device, not the underlying struct device. Kinda like devres, but for drm. Acked-by: Andrew Morton Signed-off-by: Daniel Vetter Cc: Christoph Lameter Cc: Pekka Enberg Cc: David Rientjes Cc: Joonsoo Kim Cc: Andrew Morton Cc: linux-mm@kvack.org --- I plan to merge this through drm-misc-next (with Andrew's ack) once the remainder of the drm series is in shape. -Daniel --- mm/slob.c | 2 ++ mm/slub.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/mm/slob.c b/mm/slob.c index fa53e9f73893..ac2aecfbc7a8 100644 --- a/mm/slob.c +++ b/mm/slob.c @@ -524,6 +524,7 @@ void *__kmalloc_track_caller(size_t size, gfp_t gfp, unsigned long caller) { return __do_kmalloc_node(size, gfp, NUMA_NO_NODE, caller); } +EXPORT_SYMBOL(__kmalloc_track_caller); #ifdef CONFIG_NUMA void *__kmalloc_node_track_caller(size_t size, gfp_t gfp, @@ -531,6 +532,7 @@ void *__kmalloc_node_track_caller(size_t size, gfp_t gfp, { return __do_kmalloc_node(size, gfp, node, caller); } +EXPORT_SYMBOL(__kmalloc_node_track_caller); #endif void kfree(const void *block) diff --git a/mm/slub.c b/mm/slub.c index 2988dae3f692..a937de5182cc 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -4377,6 +4377,7 @@ void *__kmalloc_track_caller(size_t size, gfp_t gfpflags, unsigned long caller) return ret; } +EXPORT_SYMBOL(__kmalloc_track_caller); #ifdef CONFIG_NUMA void *__kmalloc_node_track_caller(size_t size, gfp_t gfpflags, @@ -4407,6 +4408,7 @@ void *__kmalloc_node_track_caller(size_t size, gfp_t gfpflags, return ret; } +EXPORT_SYMBOL(__kmalloc_node_track_caller); #endif #ifdef CONFIG_SYSFS