From: Christoph Hellwig <hch@infradead.org>
To: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>,
Christoph Hellwig <hch@infradead.org>,
Dave Chinner <david@fromorbit.com>,
linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org,
Seth Forshee <seth.forshee@canonical.com>
Subject: Re: [PATCH 1/2] fs: add inode helpers for fsuid and fsgid
Date: Tue, 14 Feb 2017 00:00:16 -0800 [thread overview]
Message-ID: <20170214080016.GB12767@infradead.org> (raw)
In-Reply-To: <87lgt9mcyv.fsf@xmission.com>
On Tue, Feb 14, 2017 at 08:46:32PM +1300, Eric W. Biederman wrote:
> All of that said where are you getting sb->s_user_ns != &init_user_ns
> for an xfs filesystem? There are quite a few xfs interfaces that are
> not ready for that. xfs has a very wide userspace interface of ioctls
> that all needs to be looked at and addressed carefully if there is
> anything like this going on.
The only thing exposing uids/gid is the bulkstat code, and that's
easy to cover.
> > +/* return the current id in the filesystem view */
> > +#define i_fsuid(i) from_kuid((i)->i_sb->s_user_ns, current_fsuid())
> > +#define i_fsgid(i) from_kgid((i)->i_sb->s_user_ns, current_fsgid())
>
> Could we please place these helpers in fs.h?
> That should allow them to become inline functions and live with the
> existing filesystem helpers in there.
And give them better names, i_* is rather cryptic.
next prev parent reply other threads:[~2017-02-14 8:00 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-13 17:46 xfs: fix inode uid/gid initialization James Bottomley
2017-02-13 19:43 ` Christoph Hellwig
2017-02-13 20:33 ` James Bottomley
2017-02-13 21:34 ` Dave Chinner
2017-02-14 6:08 ` Christoph Hellwig
2017-02-14 6:27 ` James Bottomley
2017-02-14 6:28 ` [PATCH 1/2] fs: add inode helpers for fsuid and fsgid James Bottomley
2017-02-14 7:46 ` Eric W. Biederman
2017-02-14 8:00 ` Christoph Hellwig [this message]
2017-02-14 16:09 ` James Bottomley
2017-02-15 2:29 ` Eric W. Biederman
2017-02-16 15:43 ` James Bottomley
2017-02-17 1:15 ` Eric W. Biederman
2017-02-17 17:12 ` James Bottomley
2017-02-20 4:56 ` Eric W. Biederman
2017-02-14 6:29 ` [PATCH 2/2] xfs: fix inode uid/gid initialization James Bottomley
2017-02-14 7:58 ` Christoph Hellwig
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=20170214080016.GB12767@infradead.org \
--to=hch@infradead.org \
--cc=James.Bottomley@HansenPartnership.com \
--cc=david@fromorbit.com \
--cc=ebiederm@xmission.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-xfs@vger.kernel.org \
--cc=seth.forshee@canonical.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;
as well as URLs for NNTP newsgroup(s).