[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240319-sobald-reagenzglas-d4c5b1c644ad@brauner>
Date: Tue, 19 Mar 2024 07:58:07 +0100
From: Christian Brauner <brauner@...nel.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [GIT PULL] vfs fixes
On Mon, Mar 18, 2024 at 12:41:49PM -0700, Linus Torvalds wrote:
> On Mon, 18 Mar 2024 at 12:14, Linus Torvalds
> <torvalds@...ux-foundation.org> wrote:
> >
> > IOW, isn't the 'get()' always basically paired with the mounting? And
> > the 'put()' would probably be best done iin kill_block_super()?
>
> .. or alternative handwavy approach:
>
> The fundamental _reason_ for the ->get/put seems to be to make the
> 'holder' lifetime be at least as long as the 'struct file' it is
> associated with. No?
>
> So how about we just make the 'holder' always *be* a 'struct file *'? That
>
> (a) gets rid of the typeless 'void *' part
>
> (b) is already what it is for normal cases (ie O_EXCL file opens).
>
> wouldn't it be lovely if we just made the rule be that 'holder' *is*
> the file pointer, and got rid of a lot of typeless WTF code?
>
> Again, this comment (and the previous email) is more based on "this
> does not feel right to me" than anything else.
>
> That code just makes my skin itch. I can't say it's _wrong_, but it
> just FeelsWrongToMe(tm).
So, initially I think the holder ops were intended to be generic by
Christoph but I agree that it's probably not needed. I just didn't
massage that code yet. Now on my todo for this cycle!
Powered by blists - more mailing lists