mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dev Jain <dev.jain@arm.com>
To: Shivank Garg <shivankg@amd.com>,
	"Matthew Wilcox (Oracle)" <willy@infradead.org>,
	Jan Kara <jack@suse.cz>,
	Andrew Morton <akpm@linux-foundation.org>,
	Chris Li <chrisl@kernel.org>, Kairui Song <kasong@tencent.com>,
	Kemeng Shi <shikemeng@huaweicloud.com>,
	Nhat Pham <nphamcs@gmail.com>, Baoquan He <baoquan.he@linux.dev>,
	Barry Song <baohua@kernel.org>,
	Youngjun Park <youngjun.park@lge.com>,
	Minchan Kim <minchan@kernel.org>,
	Sergey Senozhatsky <senozhatsky@chromium.org>,
	"Liam R. Howlett" <liam@infradead.org>,
	Lorenzo Stoakes <ljs@kernel.org>,
	Vlastimil Babka <vbabka@kernel.org>, Jann Horn <jannh@google.com>,
	Pedro Falcato <pfalcato@suse.de>
Cc: linux-fsdevel@vger.kernel.org, linux-mm@kvack.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH mm-new v2 0/5] mm: remove unused functions
Date: Wed, 18 Nov 2026 22:35:32 +0530	[thread overview]
Message-ID: <f3219880-c944-473e-82cc-bd6b4196badf@arm.com> (raw)
In-Reply-To: <20261117-unused-sym-mm-v2-0-2f845e94dd50@amd.com>



On 17/11/26 12:46 pm, Shivank Garg wrote:
> This series removes five functions and one variable in mm that have no
> users left anywhere in the tree. I found them with the kunused scripts
> [1], which I wrote with LLM's help. The v1 cover letter [2] has more
> details on the scripts and how LLM was used.
> 
> Changes in v2:
> - Split v1 [2] up by MM tree, as David suggested. These five patches
>   are based on mm-new. 
> - No changes to the patches themselves.
> 
> [1] https://github.com/AMDESE/linux-mm/tree/shivank/kunused
> [2] https://lore.kernel.org/r/20261026-unused-sym-v1-0-82ca2dceabe1@amd.com
> 
> Signed-off-by: Shivank Garg <shivankg@amd.com>
> ---

Okay I just recalled that there have been numerous cases where people ran
scripts / compiler with flags etc and sent patches to remove unused functions,
but maintainers rejected them citing they are there for a future use. Here
are some of those instances:

https://lore.kernel.org/all/20240907021506.4018676-1-Liam.Howlett@oracle.com/
https://lore.kernel.org/linux-mm/20100211052247.GA15392@localhost/

So I think the commit messages need to do more, they need to prove that the
unused function was a genuine oversight.



> Shivank Garg (5):
>       mm: remove unused helpers from pagemap.h
>       mm/swapops: remove unused make_guard_swp_entry()
>       mm/swap: remove unused folio_to_swp_tb()
>       mm/zsmalloc: remove unused zpdesc_lock()
>       mm: nommu: remove unused heap_stack_gap
> 
>  include/linux/pagemap.h | 11 -----------
>  include/linux/swapops.h |  5 -----
>  mm/nommu.c              |  1 -
>  mm/swap_table.h         |  5 -----
>  mm/zpdesc.h             |  5 -----
>  5 files changed, 27 deletions(-)
> ---
> base-commit: 67f3b04b277373438f17300e056306adbd9edf7b
> change-id: 20261109-unused-sym-mm-8fa76462573e
> 
> Best regards,


  parent reply	other threads:[~2026-11-18 17:05 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-17  7:16 Shivank Garg
2026-11-17  7:16 ` [PATCH mm-new v2 1/5] mm: remove unused helpers from pagemap.h Shivank Garg
2026-11-17 10:01   ` Barry Song
2026-11-18 16:11   ` Dev Jain
2026-11-17  7:16 ` [PATCH mm-new v2 2/5] mm/swapops: remove unused make_guard_swp_entry() Shivank Garg
2026-11-17 10:02   ` Barry Song
2026-11-17  7:16 ` [PATCH mm-new v2 3/5] mm/swap: remove unused folio_to_swp_tb() Shivank Garg
2026-11-17 10:03   ` Barry Song
2026-11-18 16:13   ` Dev Jain
2026-11-18 16:23   ` Nhat Pham
2026-11-17  7:16 ` [PATCH mm-new v2 4/5] mm/zsmalloc: remove unused zpdesc_lock() Shivank Garg
2026-11-17 10:04   ` Barry Song
2026-11-18  2:17   ` Sergey Senozhatsky
2026-11-17  7:16 ` [PATCH mm-new v2 5/5] mm: nommu: remove unused heap_stack_gap Shivank Garg
2026-11-17 10:07   ` Barry Song
2026-11-18 17:05 ` Dev Jain [this message]
2026-11-18 17:14   ` [PATCH mm-new v2 0/5] mm: remove unused functions Dev Jain
2026-11-18 18:55     ` Garg, Shivank

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f3219880-c944-473e-82cc-bd6b4196badf@arm.com \
    --to=dev.jain@arm.com \
    --cc=akpm@linux-foundation.org \
    --cc=baohua@kernel.org \
    --cc=baoquan.he@linux.dev \
    --cc=chrisl@kernel.org \
    --cc=jack@suse.cz \
    --cc=jannh@google.com \
    --cc=kasong@tencent.com \
    --cc=liam@infradead.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=ljs@kernel.org \
    --cc=minchan@kernel.org \
    --cc=nphamcs@gmail.com \
    --cc=pfalcato@suse.de \
    --cc=senozhatsky@chromium.org \
    --cc=shikemeng@huaweicloud.com \
    --cc=shivankg@amd.com \
    --cc=vbabka@kernel.org \
    --cc=willy@infradead.org \
    --cc=youngjun.park@lge.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®