From: NeilBrown <neilb@ownmail.net>
To: Alexander Viro <viro@zeniv.linux.org.uk>,
Christian Brauner <brauner@kernel.org>,
Chuck Lever <cel@kernel.org>, Jeff Layton <jlayton@kernel.org>
Cc: linux-fsdevel@vger.kernel.org, linux-nfs@vger.kernel.org
Subject: [PATCH 1/7] vfs: add some allowed open flags to vfs_lookup_open()
Date: Thu, 10 Sep 2026 10:20:47 +1000 [thread overview]
Message-ID: <20260910002934.192979-2-neilb@ownmail.net> (raw)
In-Reply-To: <20260910002934.192979-1-neilb@ownmail.net>
From: NeilBrown <neil@brown.name>
vfs_lookup_open() must allow:
O_LARGEFILE so that large files can be opened.
O_NONBLOCK so that break_lease() can be asked to return -EWOULDBLOCK.
Signed-off-by: NeilBrown <neil@brown.name>
---
fs/namei.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/fs/namei.c b/fs/namei.c
index d95249dd527c..c9ac703110f8 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -4632,7 +4632,8 @@ struct file *vfs_lookup_open(struct path *parent, struct qstr *last,
int error = 0;
WARN_ONCE(mode & ~S_IALLUGO, "mode must only have permission bits");
- WARN_ONCE(open_flag & ~(O_ACCMODE|O_CREAT|O_EXCL|O_TRUNC|__O_REGULAR),
+ WARN_ONCE(open_flag & ~(O_ACCMODE|O_CREAT|O_EXCL|O_TRUNC|__O_REGULAR|
+ O_NONBLOCK|O_LARGEFILE),
"open_flag has unsupported flags");
mode |= S_IFREG;
base-commit: 9189e6a6f89e32d3a604b221ea64e67e1a35957c
--
2.50.0.107.gf914562f5916.dirty
next prev parent reply other threads:[~2026-09-10 0:29 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-10 0:20 [PATCH 0/7 RFC] fixes for vfs_lookup_open, and integration with nfsd NeilBrown
2026-09-10 0:20 ` NeilBrown [this message]
2026-09-10 0:20 ` [PATCH 2/7] vfs: O_NONBLOCK|O_CREAT open shouldn't wait for directory delegation NeilBrown
2026-09-10 0:20 ` [PATCH 3/7] vfs: vfs_lookup_open() should only return -EFTYPE for non-regular files NeilBrown
2026-09-10 0:20 ` [PATCH 4/7] vfs: change vfs_lookup_open() to return found dentry in path.dentry NeilBrown
2026-09-10 0:39 ` NeilBrown
2026-09-10 15:13 ` Chuck Lever
2026-09-10 0:20 ` [PATCH 5/7] nfsd: switch NFS4 OPEN to use vfs_lookup_open() NeilBrown
2026-09-10 15:41 ` Chuck Lever
2026-09-10 0:20 ` [PATCH 6/7] nfsd: nfsd_check_obj_isreg() to use nfs error codes NeilBrown
2026-09-10 0:20 ` [PATCH 7/7] nfsd: use vfs_lookup_open() for non-creating open requests too NeilBrown
2026-09-10 15:47 ` Chuck Lever
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=20260910002934.192979-2-neilb@ownmail.net \
--to=neilb@ownmail.net \
--cc=brauner@kernel.org \
--cc=cel@kernel.org \
--cc=jlayton@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-nfs@vger.kernel.org \
--cc=neil@brown.name \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.