From: "Arnd Bergmann" <arnd@arndb.de>
To: "Dorjoy Chowdhury" <dorjoychy111@gmail.com>
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
"Alexander Viro" <viro@zeniv.linux.org.uk>,
"Christian Brauner" <brauner@kernel.org>,
"Jan Kara" <jack@suse.cz>, "Jeff Layton" <jlayton@kernel.org>,
"Chuck Lever" <chuck.lever@oracle.com>,
"Alexander Aring" <alex.aring@gmail.com>
Subject: Re: [PATCH 1/2] open: new O_REGULAR flag support
Date: Mon, 26 Jan 2026 09:00:35 +0100 [thread overview]
Message-ID: <a3a9ea10-ae0f-4258-9950-89c2bdfa05b1@app.fastmail.com> (raw)
In-Reply-To: <CAFfO_h7ttQPVCR-yQ_=h4BLoHYW3QZOWQ+oSNSFvY-7NOxxeHw@mail.gmail.com>
On Sun, Jan 25, 2026, at 16:41, Dorjoy Chowdhury wrote:
>
> Thanks for pointing this out. I will fix up in v2 along with other
> comments (if any). I looked at the existing error codes in
> uapi/asm-generic/errno.h and didn't notice anything that I could
> reuse. So if I understand correctly, I will need this new error code
> in both uapi/asm-generic/errno.h (not in errno-base.h) and in
> arch/*/include/uapi/asm/errno.h (I see some parallel
> tools/arch/*/include/uapi/asm/errno.h files too) just after EHWPOISON,
> right?
Yes, sounds good to me.
>> > diff --git a/include/uapi/asm-generic/fcntl.h b/include/uapi/asm-generic/fcntl.h
>> > index 613475285643..11e5eadab868 100644
>> > --- a/include/uapi/asm-generic/fcntl.h
>> > +++ b/include/uapi/asm-generic/fcntl.h
>> > @@ -88,6 +88,10 @@
>> > #define __O_TMPFILE 020000000
>> > #endif
>> >
>> > +#ifndef O_REGULAR
>> > +#define O_REGULAR 040000000
>> > +#endif
>>
>> This in turn clashes with O_PATH on alpha, __O_TMPFILE on
>> parisc, and __O_SYNC on sparc. We can probably fill the holes
>> in asm/fcntl.h to define this.
>>
>
> And for this, I will need to just define O_REGULAR in alpha, parisc
> and sparc too, right?
Yes, the only question is whether to use the first available
bit, or the one after the previously last one.
> Good catch on the sparc file, some are octal, some are hexadecimal,
> easy to miss. Thanks!
Right, I wonder if there are any downsides to redefining them
all the same way.
Arnd
next prev parent reply other threads:[~2026-01-26 8:00 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-25 14:14 [PATCH 0/2] O_REGULAR flag support for open Dorjoy Chowdhury
2026-01-25 14:14 ` [PATCH 1/2] open: new O_REGULAR flag support Dorjoy Chowdhury
2026-01-25 14:40 ` Arnd Bergmann
2026-01-25 15:41 ` Dorjoy Chowdhury
2026-01-25 16:28 ` Jeff Layton
2026-01-25 16:59 ` Dorjoy Chowdhury
2026-01-26 8:00 ` Arnd Bergmann [this message]
2026-01-25 16:22 ` kernel test robot
2026-01-25 14:14 ` [PATCH 2/2] kselftest/openat2: test for O_REGULAR flag Dorjoy Chowdhury
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=a3a9ea10-ae0f-4258-9950-89c2bdfa05b1@app.fastmail.com \
--to=arnd@arndb.de \
--cc=alex.aring@gmail.com \
--cc=brauner@kernel.org \
--cc=chuck.lever@oracle.com \
--cc=dorjoychy111@gmail.com \
--cc=jack@suse.cz \
--cc=jlayton@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=viro@zeniv.linux.org.uk \
/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
all inboxes | Powered by JetHome®