Re: [PATCH v2 17/21] backing-inode: add backing_inode_copyattr()
Joanne Koong <[email protected]> Mon, 18 May 2026 16:21:00 -0700
| Newsgroups | org.kernel.vger.linux-unionfs,dev.linux.lists.fuse-devel |
|---|---|
| Message-ID | <CAJnrk1bqfAczXnTxtb_rui2adksDpFKXOvJyj=zotGeWJoA5sw@mail.gmail.com> |
On Sat, May 16, 2026 at 2:33 PM Amir Goldstein <[email protected]> wrote: > > On Sat, May 16, 2026 at 2:53 AM Joanne Koong <[email protected]> wrote: > > > > Move logic in ovl_copyattr() to a generic backing_inode_copyattr() > > function in a new fs/backing-inode.c, which other filesystems that use > > backing inodes (eg fuse passthrough) will use. > > > > Signed-off-by: Joanne Koong <[email protected]> > > --- > > fs/Makefile | 2 +- > > fs/backing-inode.c | 43 +++++++++++++++++++++++++++++++++++ > > fs/overlayfs/util.c | 33 +++------------------------ > > include/linux/backing-inode.h | 14 ++++++++++++ > > > Nice! > > Please add these files to > FILESYSTEMS [STACKABLE] > section in MAINTAINERS. > > Otherwise, feel free to add: > Reviewed-by: Amir Goldstein <[email protected]> > > There is one more cleanup patch required, now or later, to get rid of > some awkwardness in kernel fs code. > If you don't want to deal with it, I can take this cleanup later. > > d_backing_inode() is a noop from the day it was added and has 177 > call sites. Those call sites should be converted to d_inode() and > d_backing_inode() should go away. > > backing_inode_security{,_novalidate}() are likewise unneeded > dups of inode_security{,_novalidate}() and should be removed. Awesome! I'm happy to remove these. You mentioned in v1 that fs/stack.c and the corresponding include/linux/fs_stack.h are pretty much only used by ecryptfs. It looks like there are only two pretty minimal functions in there. Do you think it's also worth moving that logic into ecryptfs and eliminating fs stack? Thanks, Joanne > > Thanks, > Amir.