Re: [PATCH v3] vfs: don't unnecessarily clone write access for writable fds

2021-01-04 Thread Al Viro
On Mon, Jan 04, 2021 at 10:55:15AM -0800, Eric Biggers wrote: > On Tue, Sep 22, 2020 at 09:44:18AM -0700, Eric Biggers wrote: > > From: Eric Biggers > > > > There's no need for mnt_want_write_file() to increment mnt_writers when > > the file is already open for writing, provided that > >

Re: [PATCH v3] vfs: don't unnecessarily clone write access for writable fds

2021-01-04 Thread Eric Biggers
On Tue, Sep 22, 2020 at 09:44:18AM -0700, Eric Biggers wrote: > From: Eric Biggers > > There's no need for mnt_want_write_file() to increment mnt_writers when > the file is already open for writing, provided that > mnt_drop_write_file() is changed to conditionally decrement it. > > We seem to

[PATCH v3] vfs: don't unnecessarily clone write access for writable fds

2020-09-22 Thread Eric Biggers
From: Eric Biggers There's no need for mnt_want_write_file() to increment mnt_writers when the file is already open for writing, provided that mnt_drop_write_file() is changed to conditionally decrement it. We seem to have ended up in the current situation because mnt_want_write_file() used to