Subject: linux-next: build failure in the vfs tree

From: Mark Brown <[email-masked]>
Date: Mon, 15 Sep 2025 21:14:03 +0100

Hi all,

After merging the vfs tree, today's linux-next build (arm64 defconfig)
failed like this:

/tmp/next/build/fs/nsfs.c:582:27: error: initialization of 'struct file * (*)(const struct path *, unsigned int)' from incompatible pointer type 'struct file * (*)(struct path *, unsigned int)' [-Wincompatible-pointer-types]
  582 |         .open           = nsfs_export_open,
      |                           ^~~~~~~~~~~~~~~~
/tmp/next/build/fs/nsfs.c:582:27: note: (near initialization for 'nsfs_export_operations.open')

Caused by an interaction with commit

  06c4ff965e95b ("nsfs: support file handles")

from the vfs-brauner tree and

  efa6ab3688a54 ("export_operations->open(): constify path argument")

I've fixed it up as below and can carry as required.

From 56e625f1566ee6e3940c625a393b3b4e75806b3f Mon Sep 17 00:00:00 2001
From: Mark Brown <[email-masked]>
Date: Mon, 15 Sep 2025 21:03:13 +0100
Subject: [PATCH] nsfs: Fix up merge

Signed-off-by: Mark Brown <[email-masked]>
---
 fs/nsfs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/nsfs.c b/fs/nsfs.c
index 8484bc4dd3deb..32cb8c835a2ba 100644
--- a/fs/nsfs.c
+++ b/fs/nsfs.c
@@ -571,7 +571,7 @@ static int nsfs_export_permission(struct handle_to_path_ctx *ctx,
 	return 0;
 }
 
-static struct file *nsfs_export_open(struct path *path, unsigned int oflags)
+static struct file *nsfs_export_open(const struct path *path, unsigned int oflags)
 {
 	return file_open_root(path, "", oflags, 0);
 }
-- 
2.47.2

.