Re: [PATCH] fs: fix sysctls.c built

From: Kefeng Wang
Date: Thu Apr 13 2023 - 21:19:20 EST




On 2023/4/14 3:43, Luis Chamberlain wrote:
On Thu, Apr 13, 2023 at 11:46:24AM -0700, Luis Chamberlain wrote:
On Thu, Apr 13, 2023 at 10:06:35AM -0700, Luis Chamberlain wrote:
On Wed, Apr 12, 2023 at 11:19:56AM +0200, Christian Brauner wrote:
On Tue, Apr 11, 2023 at 12:14:44PM +0800, Kefeng Wang wrote:
/proc/sys/fs/overflowuid and overflowgid will be lost without
building this file, kindly ping, any comments, thanks.


...

Given the description in
ab171b952c6e ("fs: move namespace sysctls and declare fs base directory")
you probably want to move this earlier.

I was being *way* too cautious and I was wrong, so I'll take Kefang's patch as
I can verify now that order does not matter and his patch is correct.
I've corrected the documentation and clarified this on sysctl-next and
so reflected on linux-next too with these two patches:

sysctl: clarify register_sysctl_init() base directory order
https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git/commit/?h=sysctl-next-20230413&id=8ae59580f2b0529b6dd1a1cda6b838cfb268cb87

proc_sysctl: move helper which creates required subdirectories
https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git/commit/?h=sysctl-next-20230413&id=f4c09b14073513efd581459520a01c4c88cb24d7

proc_sysctl: update docs for __register_sysctl_table()
https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git/commit/?h=sysctl-next-20230413&id=d59d91edd67ec4cef62f26249510fe08b291ae72

proc_sysctl: enhance documentation
https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git/commit/?h=sysctl-next-20230413&id=eb472aa0678fd03321093bffeb9c7fd7f5035844

And so something we can do eventually is do away with all the base stuff.
For now it's fine, it's not creating an issue.

Come to think of it all the above patches except the one that moves code
("proc_sysctl: move helper which creates required subdirectories") are
stable fix candidates prior to Kefeng's patch. I'll also update Kefeng's
patch to mention stable down to v5.17 and update the other patches with
the respective stable tag as well.

Thanks for your detail explanation.


OK pushed to sysctl-next and updated the patches above also to refer to
stable and Cc you guys. Finally, a good reason or value to having Cc on
the commit log. It just tmeans you (Christian and Kefeng) will be be CC'd
once this trickles to stable kernel trees too.

Luis