[PATCH RFC 22/41] sunrpc: use fc_init_pseudo() for rpc_pipefs

Alexander Mikhalitsyn alex at amutable.com
Fri Nov 13 02:13:00 PST 2026


On Tue, 2026-11-10 at 10:14 +0100, Christian Brauner wrote:
> Initialize rpc_pipefs as a pseudo filesystem. This raises SB_I_PSEUDO
> and
> also SB_I_NOEXEC and SB_I_NODEV. rpc_pipefs never holds executables
> or
> device nodes.
> 
> Signed-off-by: Christian Brauner (Amutable) <brauner at kernel.org>

Reviewed-by: Alexander Mikhalitsyn <alex at amutable.com>

> ---
>  net/sunrpc/rpc_pipe.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/net/sunrpc/rpc_pipe.c b/net/sunrpc/rpc_pipe.c
> index 9d349cfbc483..37277a6d2415 100644
> --- a/net/sunrpc/rpc_pipe.c
> +++ b/net/sunrpc/rpc_pipe.c
> @@ -15,6 +15,7 @@
>  #include <linux/pagemap.h>
>  #include <linux/mount.h>
>  #include <linux/fs_context.h>
> +#include <linux/pseudo_fs.h>
>  #include <linux/namei.h>
>  #include <linux/fsnotify.h>
>  #include <linux/kernel.h>
> @@ -1181,6 +1182,7 @@ static int rpc_init_fs_context(struct
> fs_context *fc)
>  {
>  	put_user_ns(fc->user_ns);
>  	fc->user_ns = get_user_ns(fc->net_ns->user_ns);
> +	fc_init_pseudo(fc);
>  	fc->ops = &rpc_fs_context_ops;
>  	return 0;
>  }



More information about the Linux-nvme mailing list