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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id E79C5CD1284 for ; Thu, 4 Apr 2024 16:58:13 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 4268E6B0093; Thu, 4 Apr 2024 12:58:13 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 3D64B6B0095; Thu, 4 Apr 2024 12:58:13 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 29E496B0098; Thu, 4 Apr 2024 12:58:13 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id 07C286B0093 for ; Thu, 4 Apr 2024 12:58:13 -0400 (EDT) Received: from smtpin29.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 91EE6A16BD for ; Thu, 4 Apr 2024 16:58:12 +0000 (UTC) X-FDA: 81972457224.29.F6E1126 Received: from mail-yw1-f182.google.com (mail-yw1-f182.google.com [209.85.128.182]) by imf17.hostedemail.com (Postfix) with ESMTP id C01214000F for ; Thu, 4 Apr 2024 16:58:10 +0000 (UTC) Authentication-Results: imf17.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=qaf412SF; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf17.hostedemail.com: domain of surenb@google.com designates 209.85.128.182 as permitted sender) smtp.mailfrom=surenb@google.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1712249890; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=SnNkrv9amLNSOChMZU1xiNRngWLHsWRGHJdyDWSVIjQ=; b=ysaU4mknL4Sto0Yrd+zOZRzo+ynndxNLxWWwW3UMyAMNpSFaSumvYB0yYl9jjMHFp0uoaO tWA7W+pujHB3a3hbFEjvKRp7yuAX0Zj8TibC/xhsEHy7POWhCnHbh/ehSq0QC9xaxbBNFI CkPyVmDaexf2jb6sc8D9GavYTz4VCy8= ARC-Authentication-Results: i=1; imf17.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=qaf412SF; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf17.hostedemail.com: domain of surenb@google.com designates 209.85.128.182 as permitted sender) smtp.mailfrom=surenb@google.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1712249890; a=rsa-sha256; cv=none; b=xpwOWrAzpg0Np++cclduZvXuTkKpYeebJhp69ZmxV58OQBfZfLGULVYlwuA7bBv41M9rs7 E+BTeclm367WM879RFT3eO5n+k9uKF1RLe527Oo31pOdu6Sn5iwppu7Yvw5UpKkr5mh8mB 7wlQnYe5kROh93QaR1OXaSNu9J4uflo= Received: by mail-yw1-f182.google.com with SMTP id 00721157ae682-614ec7ee902so12126277b3.2 for ; Thu, 04 Apr 2024 09:58:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1712249890; x=1712854690; darn=kvack.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=SnNkrv9amLNSOChMZU1xiNRngWLHsWRGHJdyDWSVIjQ=; b=qaf412SFSA44k8PxmgUxABUAOMrei31VK0jYxV51A3zHeAFip79KRIujfPay1VB+VW KuqSRmk7LJzJTble9uz63f0Mve/CmTRoU8dIlqfu/SUpfUbiQD1CKaTauAc+w67Hgvks 03Ue1vmiIxuDP+xxIEB56aKQabKViDFXyhvZHnxu0P9a4MLzFxvnH5wasRbNL92IUYwa lpxPC95KP+StEWBh6nGcXzyxRWupFTVHBYNp1ZAumF0aArZ6GKI7JVAdxNsUnt6xNiYT ONy612UI4kXnkGJuyjjXDtCKmJ4Tj1nzEV52+Z8QXHAnRU4saJ/YCh6J2MBEANvsyW7M QoJw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712249890; x=1712854690; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=SnNkrv9amLNSOChMZU1xiNRngWLHsWRGHJdyDWSVIjQ=; b=td/u359W14eLi97l6rCLS1A6HnfWOvob5/Qq9ShGldw2rJ67M0qqIBZswGSEaZSIu0 JnpKIiIave0BzHwu/noca3Gexl7DeQC+h5ST6+ZQhFdDP9R9e8wqtNvIDeQmQkJkMhfi U2qExlquQPbhpUqCEzuSv/sN1NFWmEP+KwO7874yVsBPalnNT6X0bBoPkUq/fE6i7N9s fE/ftI6dzKEirbAFdkjW0MrK/iFc/dYd7910zhyPvl+IGKbj4u40khpNvpo0Jqf1JUae PWlOLnjC3TV6ZM+omqbkh5i/CxmCOF1w8jEqg///d/RGNnR22xORIgw23xrYhyhzGnCt UBSw== X-Forwarded-Encrypted: i=1; AJvYcCXzdeg/GX2eBtC3TR9qh8NzIFLIa+xA79+U7NESRHaQ2zF4qrZ0OTYMeSDnYlAZLXO5Q0AGVCzJ9+cty9tTsEuz0yY= X-Gm-Message-State: AOJu0YwXdIci3gyftTCDyVY+Ug+Nbz0mjHXF3r69uVfgCeX47wIrQpiP 0OKzwgF6Rgxz5p3I5Q4LPY2gR2W+/RSHT7yMbW6mbfWH0UXfih+erQpgYlLJdrPegZBrcZgukL3 mBOOy6buPpM2n32RK80Y+9hhJ1SrBhuWCYfN7 X-Google-Smtp-Source: AGHT+IF7B3akhgfxRrnqjce/FXowsw1E3eakccZbE6M28J8HXpTOkV5OPQcXw5mCpvOPKhYETIzOkOwrlUerT+o2JDc= X-Received: by 2002:a5b:481:0:b0:dcc:9d30:58a0 with SMTP id n1-20020a5b0481000000b00dcc9d3058a0mr2683124ybp.64.1712249889460; Thu, 04 Apr 2024 09:58:09 -0700 (PDT) MIME-Version: 1.0 References: <20240321163705.3067592-1-surenb@google.com> <20240321163705.3067592-6-surenb@google.com> <20240321133147.6d05af5744f9d4da88234fb4@linux-foundation.org> <20240321150908.48283ba55a6c786dee273ec3@linux-foundation.org> In-Reply-To: From: Suren Baghdasaryan Date: Thu, 4 Apr 2024 09:57:55 -0700 Message-ID: Subject: Re: [PATCH v6 05/37] fs: Convert alloc_inode_sb() to a macro To: Kent Overstreet Cc: Andrew Morton , mhocko@suse.com, vbabka@suse.cz, hannes@cmpxchg.org, roman.gushchin@linux.dev, mgorman@suse.de, dave@stgolabs.net, willy@infradead.org, liam.howlett@oracle.com, penguin-kernel@i-love.sakura.ne.jp, corbet@lwn.net, void@manifault.com, peterz@infradead.org, juri.lelli@redhat.com, catalin.marinas@arm.com, will@kernel.org, arnd@arndb.de, tglx@linutronix.de, mingo@redhat.com, dave.hansen@linux.intel.com, x86@kernel.org, peterx@redhat.com, david@redhat.com, axboe@kernel.dk, mcgrof@kernel.org, masahiroy@kernel.org, nathan@kernel.org, dennis@kernel.org, jhubbard@nvidia.com, tj@kernel.org, muchun.song@linux.dev, rppt@kernel.org, paulmck@kernel.org, pasha.tatashin@soleen.com, yosryahmed@google.com, yuzhao@google.com, dhowells@redhat.com, hughd@google.com, andreyknvl@gmail.com, keescook@chromium.org, ndesaulniers@google.com, vvvvvv@google.com, gregkh@linuxfoundation.org, ebiggers@google.com, ytcoode@gmail.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, bristot@redhat.com, vschneid@redhat.com, cl@linux.com, penberg@kernel.org, iamjoonsoo.kim@lge.com, 42.hyeyoo@gmail.com, glider@google.com, elver@google.com, dvyukov@google.com, songmuchun@bytedance.com, jbaron@akamai.com, aliceryhl@google.com, rientjes@google.com, minchan@google.com, kaleshsingh@google.com, kernel-team@android.com, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, iommu@lists.linux.dev, linux-arch@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-modules@vger.kernel.org, kasan-dev@googlegroups.com, cgroups@vger.kernel.org, Alexander Viro Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Rspam-User: X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: C01214000F X-Stat-Signature: xiwoffr8mreuwjz5z7t5gau9jdcbettb X-HE-Tag: 1712249890-236484 X-HE-Meta: U2FsdGVkX18neXZN35ChbHtaoptI/DQoSd8ZMLtp9fBMphnc3u4MQ+MTHYzG2JEV5KM0WlXCCejEPmypKIY7UpLQwyRSr52K1MiQ5/0gv0XiuRwtSJL5KiKMohunC7KgMEpRRYOTavbEccxppDdI5HkPcUDIGJ3YYO/g63gj7TMn1MlISK+9QPwHVsX7RqJGxEpWgs58qB+Ufk3ktVTaSRdK3Zic9Hw9ipspR1pw45GPfFeL5VKe5ggLFZTl0WgSD4uOZ7Wumiogmez6dhhlRtAfi2K+fD7NgYcAR43cP5Apo3XOFyblhlrA9qOOAqeihiBXtNX2yg8Yn43WLXmuJEGrhTrVWvT/B3iJNgVFD+K/pFJQDHI8wUI1faxO/nX1HObQ2hodJG39IeBQb2skn6HieG8sZ9sn08DYrPVf2Oc5uNwt9BxUVtIeaea9qmcP0ZGU2xM59ZDFtuAa3lCrRkTK3iRmhmK7YYOxTiqQOvFvsUREfzV0guj19dzmKkpbt/KOzndaRbK8EfG0M++5PKShAI0TM1Mavgt90Jp5WIUmEtfgmIWVd8zsghAuhFjNPfe17A8FbK2I6Td5/F2VDovnd7eFhANKKWUU9an+kdboQmGcUbkq6he8LKD6ywn0i8j07KtTYJfTZqezW6jtaLkxGfS4mAuKYobPS/QRib0E/CQ4sbAd+y6ZA8LCP+I0nQ/+sRrLWNkFnbKysJ4xm51uXRp9fvbD73XgSy8ammnliqWhunrC3lzSz0Ib+MTMpiIJYJwjLV5H5y1OyuilnDvw+oYoavQ3lib2nsIxtW1+ZkpCNZWPeAi3Psm169ORpoBZXy8tUYSPD2rbP2l6NLJI920EGybjpHGh//2cDtrVmwX42LdrKVdf3XKJ/+1XnzvrhzpGeascivjNxP4ThnQFZE1fNWOrCr47KWwyXBwfiFHozJ+fHZpSriQzWD9oKXSJJSF9Xi2SKuN7Dml dpe5YSvR kGz8cPn4kC10pXzaHRqqIDhf9vPGxZ1Sc137xcfDOZVtuw9Q+O+wJMsBZ+cLgCu3jmYKmhyKzhQOEXFb3hDIH7uopUxnboTTWbgR1r/Vy+dV/HEckW92qE28Q0QunUcPH68aKqwyjrnt2VJOJ9n3nvmDfshSk8Jo99XZ2zV/m1bL7YASnFEEWy5MTzjJhvCL2xqDIOC31s5UwKa39x97oZZu8loLBcxCJ2M/P428zXHcRfq0Ydi1mIyQ+Pqhs9xxqEt4RfJzqkvJZ8vv6UToQ+9/fBEyNC3ELdgxNexywOdvpwELF4myNRkeMGnLHVw0IMOpqxbkrItrU5nBz448xXogTnJ5dl1ev6sNe6ebnKZcx7DEGNpibM+hESO4pZ1HccIloQf8aUZjtqYW+RemW6EkbIcLHjqR7XnhaNYfZLsosk+g= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: On Thu, Mar 21, 2024 at 3:47=E2=80=AFPM Suren Baghdasaryan wrote: > > On Thu, Mar 21, 2024 at 3:17=E2=80=AFPM Kent Overstreet > wrote: > > > > On Thu, Mar 21, 2024 at 03:09:08PM -0700, Andrew Morton wrote: > > > On Thu, 21 Mar 2024 17:15:39 -0400 Kent Overstreet wrote: > > > > > > > On Thu, Mar 21, 2024 at 01:31:47PM -0700, Andrew Morton wrote: > > > > > On Thu, 21 Mar 2024 09:36:27 -0700 Suren Baghdasaryan wrote: > > > > > > > > > > > From: Kent Overstreet > > > > > > > > > > > > We're introducing alloc tagging, which tracks memory allocation= s by > > > > > > callsite. Converting alloc_inode_sb() to a macro means allocati= ons will > > > > > > be tracked by its caller, which is a bit more useful. > > > > > > > > > > I'd have thought that there would be many similar > > > > > inlines-which-allocate-memory. Such as, I dunno, jbd2_alloc_inod= e(). > > > > > Do we have to go converting things to macros as people report > > > > > misleading or less useful results, or is there some more general > > > > > solution to this? > > > > > > > > No, this is just what we have to do. > > > > > > Well, this is something we strike in other contexts - kallsyms gives = us > > > an inlined function and it's rarely what we wanted. > > > > > > I think kallsyms has all the data which is needed to fix this - how > > > hard can it be to figure out that a particular function address lies > > > within an outer function? I haven't looked... > > > > This is different, though - even if a function is inlined in multiple > > places there's only going to be one instance of a static var defined > > within that function. > > I guess one simple way to detect the majority of these helpers would > be to filter all entries from /proc/allocinfo which originate from > header files. > > ~# grep ".*\.h:." /proc/allocinfo > 933888 228 include/linux/mm.h:2863 func:pagetable_alloc > 848 53 include/linux/mm_types.h:1175 func:mm_alloc_cid > 0 0 include/linux/bpfptr.h:70 func:kvmemdup_bpfptr > 0 0 include/linux/bpf.h:2237 func:bpf_map_kmalloc_node > 0 0 include/linux/bpf.h:2256 func:bpf_map_alloc_percpu > 0 0 include/linux/bpf.h:2256 func:bpf_map_alloc_percpu > 0 0 include/linux/bpf.h:2237 func:bpf_map_kmalloc_node > 0 0 include/linux/bpf.h:2249 func:bpf_map_kvcalloc > 0 0 include/linux/bpf.h:2243 func:bpf_map_kzalloc > 0 0 include/linux/bpf.h:2237 func:bpf_map_kmalloc_node > 0 0 include/linux/ptr_ring.h:471 > func:__ptr_ring_init_queue_alloc > 0 0 include/linux/bpf.h:2256 func:bpf_map_alloc_percpu > 0 0 include/linux/bpf.h:2237 func:bpf_map_kmalloc_node > 0 0 include/net/tcx.h:80 func:tcx_entry_create > 0 0 arch/x86/include/asm/pgalloc.h:156 func:p4d_alloc_o= ne > 487424 119 include/linux/mm.h:2863 func:pagetable_alloc > 0 0 include/linux/mm.h:2863 func:pagetable_alloc > 832 13 include/linux/jbd2.h:1607 func:jbd2_alloc_inode > 0 0 include/linux/jbd2.h:1591 func:jbd2_alloc_handle > 0 0 fs/nfs/iostat.h:51 func:nfs_alloc_iostats > 0 0 include/net/netlabel.h:281 func:netlbl_secattr_cach= e_alloc > 0 0 include/net/netlabel.h:381 func:netlbl_secattr_allo= c > 0 0 include/crypto/internal/acompress.h:76 > func:__acomp_request_alloc > 8064 84 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 1016 74 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 384 4 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 704 3 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 32 1 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 64 1 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 40 2 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 32 1 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 30000 625 include/acpi/platform/aclinuxex.h:67 > func:acpi_os_acquire_object > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:67 > func:acpi_os_acquire_object > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 512 1 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 192 6 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 192 3 include/acpi/platform/aclinuxex.h:52 func:acpi_os_a= llocate > 61992 861 include/acpi/platform/aclinuxex.h:67 > func:acpi_os_acquire_object > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 include/acpi/platform/aclinuxex.h:67 > func:acpi_os_acquire_object > 0 0 include/acpi/platform/aclinuxex.h:57 > func:acpi_os_allocate_zeroed > 0 0 drivers/iommu/amd/amd_iommu.h:141 func:alloc_pgtabl= e_page > 0 0 drivers/iommu/amd/amd_iommu.h:141 func:alloc_pgtabl= e_page > 0 0 drivers/iommu/amd/amd_iommu.h:141 func:alloc_pgtabl= e_page > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/hid_bpf.h:154 func:call_hid_bpf_rdesc= _fixup > 0 0 include/linux/skbuff.h:3392 func:__dev_alloc_pages > 114688 56 include/linux/ptr_ring.h:471 > func:__ptr_ring_init_queue_alloc > 0 0 include/linux/skmsg.h:415 func:sk_psock_init_link > 0 0 include/linux/bpf.h:2237 func:bpf_map_kmalloc_node > 0 0 include/linux/ptr_ring.h:628 func:ptr_ring_resize_m= ultiple > 24576 3 include/linux/ptr_ring.h:471 > func:__ptr_ring_init_queue_alloc > 0 0 include/net/netlink.h:1896 func:nla_memdup > 0 0 include/linux/sockptr.h:97 func:memdup_sockptr > 0 0 include/net/request_sock.h:131 func:reqsk_alloc > 0 0 include/net/tcp.h:2456 func:tcp_v4_save_options > 0 0 include/net/tcp.h:2456 func:tcp_v4_save_options > 0 0 include/crypto/hash.h:586 func:ahash_request_alloc > 0 0 include/linux/sockptr.h:97 func:memdup_sockptr > 0 0 include/linux/sockptr.h:97 func:memdup_sockptr > 0 0 net/sunrpc/auth_gss/auth_gss_internal.h:38 > func:simple_get_netobj > 0 0 include/crypto/hash.h:586 func:ahash_request_alloc > 0 0 include/net/netlink.h:1896 func:nla_memdup > 0 0 include/crypto/skcipher.h:869 func:skcipher_request= _alloc > 0 0 include/net/fq_impl.h:361 func:fq_init > 0 0 include/net/netlabel.h:316 func:netlbl_catmap_alloc > > and it finds our example: > > 832 13 include/linux/jbd2.h:1607 func:jbd2_alloc_inode > > Interestingly the inlined functions which are called from multiple > places will have multiple entries with the same file+line: > > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > 0 0 include/linux/dma-fence-chain.h:91 > func:dma_fence_chain_alloc > > So, duplicate entries can be also used as an indication of an inlined all= ocator. > I'll go chase these down and will post a separate patch converting them. I just posted https://lore.kernel.org/all/20240404165404.3805498-1-surenb@g= oogle.com/ to report allocations done from the inlined functions in the headers to their callers.