Subject: Re: linux-next: build failure after merge of the vfs-brauner tree

From: Christian Brauner <[email-masked]>
Date: Tue, 31 Mar 2026 11:21:38 +0200

On Mon, Mar 30, 2026 at 02:17:32PM +0100, Mark Brown wrote:
> On Fri, Mar 27, 2026 at 05:48:55PM +0000, Mark Brown wrote:
> > On Thu, Mar 26, 2026 at 02:36:50PM +0100, Christian Brauner wrote:
> > > On Wed, Mar 25, 2026 at 12:32:23PM +0000, Mark Brown wrote:
> > 
> > > > In file included from listns_efault_test.c:23:
> > > > ../pidfd/pidfd.h:229:19: error: static declaration of 'wait_for_pid' follows non-static declaration
> > > >   229 | static inline int wait_for_pid(pid_t pid)
> > > >       |                   ^~~~~~~~~~~~
> > 
> > > > I am continuing to use the tree from next-20260312.
> > 
> > > This should be fixed now. Sorry.
> > 
> > I'm still seeing this today.  I have:
> > 
> > 84f524dca4b8bc9e9aca8ea1dbbd2aa3a239d998 Merge branch 'namespaces-7.1.misc' into vfs.all
> > 
> > as the vfs-brauner tree, I'm not seeing any new patches to the test case
> > there.
> 
> Still seeing this today.

Sorry, this was _yet_ another callsite that completely duplicates
wait_for_pid() for whatever reason. The following patch should fix it.
I'm adding this to vfs-7.1.mount today.

>From ef6960362e5b33402b9977972ab2a9fabc4c8cb9 Mon Sep 17 00:00:00 2001
From: Christian Brauner <[email-masked]>
Date: Tue, 31 Mar 2026 10:58:58 +0200
Subject: [PATCH] selftests/namespaces: remove unused utils.h include from
 listns_efault_test

Remove the inclusion of ../filesystems/utils.h from listns_efault_test.c.
The test doesn't use any symbols from that header. Including it alongside
../pidfd/pidfd.h causes a build failure because both headers define
wait_for_pid() with conflicting linkage:

  ../filesystems/utils.h:  extern int wait_for_pid(pid_t pid);
  ../pidfd/pidfd.h:        static inline int wait_for_pid(pid_t pid)

All symbols the test actually uses (create_child, read_nointr,
write_nointr, sys_pidfd_send_signal) come from pidfd.h.

Reported-by: Mark Brown <[email-masked]>
Link: https://lore.kernel.org/all/[email-masked]
Fixes: 07d7ad46dad4 ("selftests/namespaces: test for efault")
Signed-off-by: Christian Brauner <[email-masked]>
---
 tools/testing/selftests/namespaces/listns_efault_test.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/tools/testing/selftests/namespaces/listns_efault_test.c b/tools/testing/selftests/namespaces/listns_efault_test.c
index c7ed4023d7a8..b570746e917c 100644
--- a/tools/testing/selftests/namespaces/listns_efault_test.c
+++ b/tools/testing/selftests/namespaces/listns_efault_test.c
@@ -19,7 +19,6 @@
 #include <sys/wait.h>
 #include <unistd.h>
 #include "../kselftest_harness.h"
-#include "../filesystems/utils.h"
 #include "../pidfd/pidfd.h"
 #include "wrappers.h"
 
-- 
2.47.3