diff options
author | Stanislav Kinsbursky <skinsbursky@parallels.com> | 2011-12-26 07:38:56 -0500 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-01-31 18:20:23 -0500 |
commit | 38b0da7522c086f1dcdeda39a2d1849c6a31f518 (patch) | |
tree | 50a00ba4410645aa495a27dd274eb45f740494ef /net | |
parent | 5bff0386305461021bbef2d958fa0f0151f56a6f (diff) |
SUNRPC: create RPC pipefs superblock per network namespace context
This is the initial step of RPC pipefs virtualization. It changes nothing to
current pipefs behaviour except that mount of pipefs in other than init_net
network namespace context will provide only root tree. No other dentries will
be visible.
Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net')
-rw-r--r-- | net/sunrpc/rpc_pipe.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/sunrpc/rpc_pipe.c b/net/sunrpc/rpc_pipe.c index 8e3397fc0a7d..e32e6b8c006d 100644 --- a/net/sunrpc/rpc_pipe.c +++ b/net/sunrpc/rpc_pipe.c | |||
@@ -993,6 +993,7 @@ rpc_fill_super(struct super_block *sb, void *data, int silent) | |||
993 | { | 993 | { |
994 | struct inode *inode; | 994 | struct inode *inode; |
995 | struct dentry *root; | 995 | struct dentry *root; |
996 | struct net *net = data; | ||
996 | 997 | ||
997 | sb->s_blocksize = PAGE_CACHE_SIZE; | 998 | sb->s_blocksize = PAGE_CACHE_SIZE; |
998 | sb->s_blocksize_bits = PAGE_CACHE_SHIFT; | 999 | sb->s_blocksize_bits = PAGE_CACHE_SHIFT; |
@@ -1017,7 +1018,7 @@ static struct dentry * | |||
1017 | rpc_mount(struct file_system_type *fs_type, | 1018 | rpc_mount(struct file_system_type *fs_type, |
1018 | int flags, const char *dev_name, void *data) | 1019 | int flags, const char *dev_name, void *data) |
1019 | { | 1020 | { |
1020 | return mount_single(fs_type, flags, data, rpc_fill_super); | 1021 | return mount_ns(fs_type, flags, current->nsproxy->net_ns, rpc_fill_super); |
1021 | } | 1022 | } |
1022 | 1023 | ||
1023 | static struct file_system_type rpc_pipe_fs_type = { | 1024 | static struct file_system_type rpc_pipe_fs_type = { |