From: Christian Brauner <brauner@kernel.org>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Xiubo Li <xiubli@redhat.com>, Ilya Dryomov <idryomov@gmail.com>,
Jan Harkes <jaharkes@cs.cmu.edu>,
Namjae Jeon <linkinjeon@kernel.org>,
Sungjong Seo <sj1557.seo@samsung.com>,
Dave Kleikamp <shaggy@kernel.org>,
Anton Altaparmakov <anton@tuxera.com>,
Mark Fasheh <mark@fasheh.com>, Joel Becker <jlbec@evilplan.org>,
Joseph Qi <joseph.qi@linux.alibaba.com>,
Miklos Szeredi <miklos@szeredi.hu>,
Amir Goldstein <amir73il@gmail.com>,
Hans de Goede <hdegoede@redhat.com>,
Mateusz Guzik <mjguzik@gmail.com>, Jens Axboe <axboe@kernel.dk>,
Christoph Hellwig <hch@lst.de>, Aleksa Sarai <cyphar@cyphar.com>,
Al Viro <viro@zeniv.linux.org.uk>,
Seth Forshee <sforshee@kernel.org>,
linux-fsdevel@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH] file: always lock position
Date: Sun, 6 Aug 2023 15:25:51 +0200 [thread overview]
Message-ID: <20230806-appell-heulen-61fc63545739@brauner> (raw)
In-Reply-To: <20230806-mundwinkel-wenig-d1c9dcb2c595@brauner>
On Sun, Aug 06, 2023 at 08:10:40AM +0200, Christian Brauner wrote:
> > Yes, some filesystems then still get the inode lock in write mode, but
> > now it's the filesystem itself that wraps its own iterator, rather
> > than cause pain for the callers.
>
> And, btrfs already does this in some cases where it first upgrades from
> shared to non-shared and then downgrades again before returning in
> btrfs_real_readdir(). So it's not like this isn't already happening.
>
> >
> > So no more "Do you have an ->iterate() _or_ ->iterate_shared()
> > function?" and associated "I need to do locking differently"
> > nastiness. Only odd filesystems that never got the memo on "don't use
> > .iterate".
>
> Ack. It's not pretty but that hasn't stopped us before and it's less
> ugly than double inode methods which pass exactly the same parameters. I
> think removing the double methods is good and I see no problem in
> shaming filesystems that didn't manage to convert properly in the last 7
> years.
>
> And let's please not get stuck on incoming pinky promises that everyone
> will have converted before the next 7 years are over. I'd prefer to see
> the iop wiped and leave the ugliness to the individual filesystems rn.
We got sent a fix for a wrong check for O_TMPFILE during RESOLVE_CACHED
lookup which I've put on vfs.fixes yesterday:
git@gitolite.kernel.org:pub/scm/linux/kernel/git/vfs/vfs tags/v6.5-rc5.vfs.resolve_cached.fix
But in case you planned on applying this directly instead of waiting for
next cycle I've added your two appended patches on top of it and my
earlier patch for massaging the file_needs_f_pos_lock() check that
triggered this whole thing:
git@gitolite.kernel.org:pub/scm/linux/kernel/git/vfs/vfs tags/v6.5-rc5.vfs.fixes
next prev parent reply other threads:[~2023-08-06 13:26 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20230804-turnverein-helfer-ef07a4d7bbec@brauner>
2023-08-05 11:46 ` [PATCH] file: always lock position Christian Brauner
2023-08-05 18:47 ` Linus Torvalds
2023-08-05 19:46 ` Linus Torvalds
2023-08-06 6:10 ` Christian Brauner
2023-08-06 13:25 ` Christian Brauner [this message]
2023-08-06 17:48 ` Linus Torvalds
2023-07-24 15:00 Christian Brauner
2023-07-24 15:53 ` Linus Torvalds
2023-07-24 16:19 ` Christian Brauner
2023-07-24 16:36 ` Linus Torvalds
2023-07-24 16:51 ` Linus Torvalds
2023-09-02 4:44 ` Al Viro
2023-07-24 17:23 ` Christian Brauner
2023-07-24 17:34 ` Linus Torvalds
2023-07-24 17:46 ` Christian Brauner
2023-07-24 18:01 ` Linus Torvalds
2023-07-24 18:05 ` Jens Axboe
2023-07-24 18:27 ` Linus Torvalds
2023-07-24 18:48 ` Christian Brauner
2023-07-24 22:25 ` Linus Torvalds
2023-07-24 22:56 ` Jens Axboe
2023-07-25 18:30 ` Linus Torvalds
2023-07-25 20:41 ` Jens Axboe
2023-07-25 20:51 ` Linus Torvalds
2023-07-25 20:58 ` Jens Axboe
2023-07-26 8:36 ` Christian Brauner
2023-07-26 10:31 ` David Laight
2023-07-26 12:53 ` Christian Brauner
2023-07-26 8:07 ` Christian Brauner
2023-07-24 16:46 ` Christian Brauner
2023-07-24 16:59 ` Linus Torvalds
2023-07-24 17:18 ` Linus Torvalds
2023-08-03 9:53 ` Mateusz Guzik
2023-08-03 14:15 ` Christian Brauner
2023-08-03 15:17 ` Mateusz Guzik
2023-08-03 15:18 ` Mateusz Guzik
2023-08-03 15:45 ` Linus Torvalds
2023-08-03 17:54 ` Mateusz Guzik
2023-08-03 18:02 ` Christian Brauner
2023-08-03 18:35 ` Linus Torvalds
2023-08-04 13:43 ` Christian Brauner
2023-08-04 13:59 ` Christoph Hellwig
2023-09-02 3:43 ` Al Viro
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=20230806-appell-heulen-61fc63545739@brauner \
--to=brauner@kernel.org \
--cc=amir73il@gmail.com \
--cc=anton@tuxera.com \
--cc=axboe@kernel.dk \
--cc=cyphar@cyphar.com \
--cc=hch@lst.de \
--cc=hdegoede@redhat.com \
--cc=idryomov@gmail.com \
--cc=jaharkes@cs.cmu.edu \
--cc=jlbec@evilplan.org \
--cc=joseph.qi@linux.alibaba.com \
--cc=linkinjeon@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=mark@fasheh.com \
--cc=miklos@szeredi.hu \
--cc=mjguzik@gmail.com \
--cc=sforshee@kernel.org \
--cc=shaggy@kernel.org \
--cc=sj1557.seo@samsung.com \
--cc=stable@vger.kernel.org \
--cc=torvalds@linux-foundation.org \
--cc=viro@zeniv.linux.org.uk \
--cc=xiubli@redhat.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