Re: [GIT PULL] execve updates for v6.8-rc1

From: Linus Torvalds
Date: Thu Jan 11 2024 - 12:38:14 EST


On Thu, 11 Jan 2024 at 01:47, Al Viro <viro@xxxxxxxxxxxxxxxxxx> wrote:
>
> Two things, both related to ->atomic_open():

Yeah, I was staring at the atomic_open() cases, and just thought that
we could allocate the filp early for that.

It wouldn't matter for normal filesystems, so from a performance
standpoint it would be ok.

My handwavy thinking was that we'd remove 'filp' from the arguments we
pass around, and instead make it be a member of 'struct nameidata',
and then the different codepaths could decide that "now I need the
filp, so I'll instantiate it".

But then I looked more at the code, and it seemed to get quite messy,
quite fast.

Linus