From mboxrd@z Thu Jan 1 00:00:00 1970 From: Randy Dunlap Subject: Re: [PATCH v12 11/12] open: openat2(2) syscall Date: Wed, 4 Sep 2019 14:00:20 -0700 Message-ID: <5e31b450-75b8-f037-dca7-b1bd547cf339@infradead.org> References: <20190904201933.10736-1-cyphar@cyphar.com> <20190904201933.10736-12-cyphar@cyphar.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20190904201933.10736-12-cyphar@cyphar.com> Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org To: Aleksa Sarai , Al Viro , Jeff Layton , "J. Bruce Fields" , Arnd Bergmann , David Howells , Shuah Khan , Shuah Khan , Ingo Molnar , Peter Zijlstra , Christian Brauner Cc: Eric Biederman , Andy Lutomirski , Andrew Morton , Alexei Starovoitov , Kees Cook , Jann Horn , Tycho Andersen , David Drysdale , Chanho Min , Oleg Nesterov , Rasmus Villemoes , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Aleksa Sarai , Linus Torvalds , containers@lists.linux-foundation.org, linux-alpha@vger.kernel.org, linux-api@vger.kernel.org, linux-arch@vger.kernel.org, linux-arm-kernel@lists.infradead. List-Id: linux-api@vger.kernel.org Hi, just noisy nits here: On 9/4/19 1:19 PM, Aleksa Sarai wrote: > diff --git a/include/uapi/linux/fcntl.h b/include/uapi/linux/fcntl.h > index 1d338357df8a..479baf2da10e 100644 > --- a/include/uapi/linux/fcntl.h > +++ b/include/uapi/linux/fcntl.h > @@ -93,5 +93,47 @@ > > #define AT_RECURSIVE 0x8000 /* Apply to the entire subtree */ > > +/** /** means "the following is kernel-doc", but it's not, so please either make it kernel-doc format or just use /* to begin the comment. > + * Arguments for how openat2(2) should open the target path. If @resolve is > + * zero, then openat2(2) operates identically to openat(2). > + * > + * However, unlike openat(2), unknown bits in @flags result in -EINVAL rather > + * than being silently ignored. In addition, @mode (or @upgrade_mask) must be > + * zero unless one of {O_CREAT, O_TMPFILE, O_PATH} are set. > + * > + * @flags: O_* flags. > + * @mode: O_CREAT/O_TMPFILE file mode. > + * @upgrade_mask: UPGRADE_* flags (to restrict O_PATH re-opening). > + * @resolve: RESOLVE_* flags. > + */ > +struct open_how { > + __u32 flags; > + union { > + __u16 mode; > + __u16 upgrade_mask; > + }; > + __u16 resolve; > +}; -- ~Randy