Re: [PATCH 02/10] fs: move mapping helpers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Nov 30, 2021 at 08:35:56AM +0200, Amir Goldstein wrote:
> On Tue, Nov 23, 2021 at 3:29 PM Christian Brauner <brauner@xxxxxxxxxx> wrote:
> >
> > From: Christian Brauner <christian.brauner@xxxxxxxxxx>
> >
> > The low-level mapping helpers were so far crammed into fs.h. They are
> > out of place there. The fs.h header should just contain the higher-level
> > mapping helpers that interact directly with vfs objects such as struct
> > super_block or struct inode and not the bare mapping helpers. Similarly,
> > only vfs and specific fs code shall interact with low-level mapping
> > helpers. And so they won't be made accessible automatically through
> > regular {g,u}id helpers.
> >
> > Cc: Seth Forshee <sforshee@xxxxxxxxxxxxxxxx>
> > Cc: Christoph Hellwig <hch@xxxxxx>
> > Cc: Al Viro <viro@xxxxxxxxxxxxxxxxxx>
> > CC: linux-fsdevel@xxxxxxxxxxxxxxx
> > Signed-off-by: Christian Brauner <christian.brauner@xxxxxxxxxx>
> > ---
> >  include/linux/fs.h          |  91 +-------------------------------
> >  include/linux/mnt_mapping.h | 101 ++++++++++++++++++++++++++++++++++++
> >  2 files changed, 102 insertions(+), 90 deletions(-)
> >  create mode 100644 include/linux/mnt_mapping.h
> >
> > diff --git a/include/linux/fs.h b/include/linux/fs.h
> > index 192242476b2b..eb69e8b035fa 100644
> > --- a/include/linux/fs.h
> > +++ b/include/linux/fs.h
> > @@ -41,6 +41,7 @@
> >  #include <linux/stddef.h>
> >  #include <linux/mount.h>
> >  #include <linux/cred.h>
> > +#include <linux/mnt_mapping.h>
> 
> If I grepped correctly, there are ~20 files that use these helpers.
> Please put the include in those files, so changes to this header
> will not compile the world.

Ok, happy to.

> 
> And how about mnt_idmapping.h or idmapped_mnt.h?

I think then I'll opt for mnt_idmapping.h.

> Not sure if this naming issue was discussed already.

Nope!

Thanks!
Christian



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux