Skip to content

Commit

Permalink
SUNRPC: create RPC pipefs superblock per network namespace context
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Stanislav Kinsbursky authored and Trond Myklebust committed Jan 31, 2012
1 parent 5bff038 commit 38b0da7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion net/sunrpc/rpc_pipe.c
Original file line number Diff line number Diff line change
Expand Up @@ -993,6 +993,7 @@ rpc_fill_super(struct super_block *sb, void *data, int silent)
{
struct inode *inode;
struct dentry *root;
struct net *net = data;

sb->s_blocksize = PAGE_CACHE_SIZE;
sb->s_blocksize_bits = PAGE_CACHE_SHIFT;
Expand All @@ -1017,7 +1018,7 @@ static struct dentry *
rpc_mount(struct file_system_type *fs_type,
int flags, const char *dev_name, void *data)
{
return mount_single(fs_type, flags, data, rpc_fill_super);
return mount_ns(fs_type, flags, current->nsproxy->net_ns, rpc_fill_super);
}

static struct file_system_type rpc_pipe_fs_type = {
Expand Down

0 comments on commit 38b0da7

Please sign in to comment.