Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 294550
b: refs/heads/master
c: cb9c1c4
h: refs/heads/master
v: v3
  • Loading branch information
Stanislav Kinsbursky authored and Trond Myklebust committed Mar 11, 2012
1 parent 94e90ba commit d9a50be
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: d6d6dc7cdfda7c8f49a89a7b7261846f319da6d1
refs/heads/master: cb9c1c4a880bc734c2848f8647be2cfa336ee346
5 changes: 0 additions & 5 deletions trunk/fs/nfs/blocklayout/blocklayout.h
Original file line number Diff line number Diff line change
Expand Up @@ -153,11 +153,6 @@ BLK_LSEG2EXT(struct pnfs_layout_segment *lseg)
return BLK_LO2EXT(lseg->pls_layout);
}

struct bl_dev_msg {
int32_t status;
uint32_t major, minor;
};

struct bl_msg_hdr {
u8 type;
u16 totallen; /* length of entire message, including hdr itself */
Expand Down
9 changes: 5 additions & 4 deletions trunk/fs/nfs/blocklayout/blocklayoutdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,16 @@ int nfs4_blkdev_put(struct block_device *bdev)
return blkdev_put(bdev, FMODE_READ);
}

static struct bl_dev_msg bl_mount_reply;

ssize_t bl_pipe_downcall(struct file *filp, const char __user *src,
size_t mlen)
{
struct nfs_net *nn = net_generic(filp->f_dentry->d_sb->s_fs_info,
nfs_net_id);

if (mlen != sizeof (struct bl_dev_msg))
return -EINVAL;

if (copy_from_user(&bl_mount_reply, src, mlen) != 0)
if (copy_from_user(&nn->bl_mount_reply, src, mlen) != 0)
return -EFAULT;

wake_up(&bl_wq);
Expand Down Expand Up @@ -118,10 +119,10 @@ nfs4_blk_decode_device(struct nfs_server *server,
};
uint8_t *dataptr;
DECLARE_WAITQUEUE(wq, current);
struct bl_dev_msg *reply = &bl_mount_reply;
int offset, len, i, rc;
struct net *net = server->nfs_client->net;
struct nfs_net *nn = net_generic(net, nfs_net_id);
struct bl_dev_msg *reply = &nn->bl_mount_reply;

dprintk("%s CREATING PIPEFS MESSAGE\n", __func__);
dprintk("%s: deviceid: %s, mincount: %d\n", __func__, dev->dev_id.data,
Expand Down
6 changes: 6 additions & 0 deletions trunk/fs/nfs/netns.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,15 @@
#include <net/net_namespace.h>
#include <net/netns/generic.h>

struct bl_dev_msg {
int32_t status;
uint32_t major, minor;
};

struct nfs_net {
struct cache_detail *nfs_dns_resolve;
struct rpc_pipe *bl_device_pipe;
struct bl_dev_msg bl_mount_reply;
struct list_head nfs_client_list;
struct list_head nfs_volume_list;
#ifdef CONFIG_NFS_V4
Expand Down

0 comments on commit d9a50be

Please sign in to comment.