[PATCH RESEND v2 10/23] treewide: let procfs own the seq_file of simple proc entries

sashiko-bot at kernel.org sashiko-bot at kernel.org
Thu Nov 5 11:35:33 PST 2026


> Most proc entries that bring their own struct proc_ops only call
> single_open(), seq_open() or seq_open_private() in ->proc_open() and
> free the seq_file with the matching helper. Declare the show function
> or the seq_operations instead and let procfs open and free the
> seq_file. Reading these files then no longer holds up their removal.
> 
> Done with the following semantic patch. The new initializers were
> aligned like their neighbours afterwards:
> 
>   // SPDX-License-Identifier: GPL-2.0-only
>   /// Let procfs open the seq_file of proc entries whose ->proc_open() only
>   /// calls single_open(), seq_open() or seq_open_private().
>   //
>   // Confidence: High
>   // Options: --no-includes --include-headers
> [ ... ]
>   identifier open_fn = {single.open_fn, seq.open_fn, priv.open_fn};
>   @@
>   - static int open_fn(...) { ... }
> 
> Signed-off-by: Christian Brauner (Amutable) <brauner at kernel.org>

Sashiko has reviewed this patch and found no issues.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261104-work-procfs-core-v2-0-76ace653a773@kernel.org?part=10




More information about the kexec mailing list