[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202104021157.7B388D1B2@keescook>
Date: Fri, 2 Apr 2021 12:01:05 -0700
From: Kees Cook <keescook@...omium.org>
To: Christoph Hellwig <hch@....de>
Cc: Al Viro <viro@...iv.linux.org.uk>, linux-fsdevel@...r.kernel.org,
linux-kernel@...r.kernel.org,
Andy Lutomirski <luto@...capital.net>,
Will Drewry <wad@...omium.org>
Subject: Re: [PATCH] fs: split receive_fd_replace from __receive_fd
On Thu, Mar 25, 2021 at 09:22:09AM +0100, Christoph Hellwig wrote:
> receive_fd_replace shares almost no code with the general case, so split
> it out. Also remove the "Bump the sock usage counts" comment from
> both copies, as that is now what __receive_sock actually does.
>
> Signed-off-by: Christoph Hellwig <hch@....de>
I'm okay with repeating code in fs/file.c. What I wanted to avoid was
open coded combinations in various callers.
So, sure, this can be split, but as-is the patch breaks SECCOMP_IOCTL_NOTIF_ADDFD:
https://lore.kernel.org/linux-fsdevel/20210329071939.GC3633@xsang-OptiPlex-9020/
-Kees
--
Kees Cook
Powered by blists - more mailing lists