[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20210315084033.GB28612@lst.de>
Date: Mon, 15 Mar 2021 09:40:33 +0100
From: Christoph Hellwig <hch@....de>
To: Christian Brauner <christian.brauner@...ntu.com>
Cc: Vivek Goyal <vgoyal@...hat.com>, Christoph Hellwig <hch@....de>,
Alexander Viro <viro@...iv.linux.org.uk>,
linux-fsdevel@...r.kernel.org, Andy Lutomirski <luto@...nel.org>,
Theodore Tso <tytso@....edu>, Alban Crequy <alban@...volk.io>,
Tycho Andersen <tycho@...ho.ws>,
Seth Forshee <seth.forshee@...onical.com>,
Stéphane Graber <stgraber@...ntu.com>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Aleksa Sarai <cyphar@...har.com>,
"Eric W. Biederman" <ebiederm@...ssion.com>,
Serge Hallyn <serge@...lyn.com>, linux-ext4@...r.kernel.org,
linux-xfs@...r.kernel.org
Subject: Re: [PATCH v6 02/40] fs: add id translation helpers
> + struct user_namespace *s_user_ns = sb->s_user_ns;
> + if (!kuid_has_mapping(s_user_ns,
> + kuid_from_mnt(mnt_userns, current_fsuid())))
> + return false;
> + if (!kgid_has_mapping(s_user_ns,
> + kgid_from_mnt(mnt_userns, current_fsgid())))
> + return false;
> + return true;
Please don't use one tab indents for conditional continuations, as
that looks really weird. Always use two tabs or align to the
opening brace.
Otherwise these helpers looks really useful.
Powered by blists - more mailing lists