diff options
Diffstat (limited to 'fs/nfs/filelayout/filelayout.c')
-rw-r--r-- | fs/nfs/filelayout/filelayout.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/fs/nfs/filelayout/filelayout.c b/fs/nfs/filelayout/filelayout.c index 91e88a7ecef0..a46bf6de9ce4 100644 --- a/fs/nfs/filelayout/filelayout.c +++ b/fs/nfs/filelayout/filelayout.c | |||
@@ -258,7 +258,8 @@ filelayout_set_layoutcommit(struct nfs_pgio_header *hdr) | |||
258 | hdr->res.verf->committed != NFS_DATA_SYNC) | 258 | hdr->res.verf->committed != NFS_DATA_SYNC) |
259 | return; | 259 | return; |
260 | 260 | ||
261 | pnfs_set_layoutcommit(hdr); | 261 | pnfs_set_layoutcommit(hdr->inode, hdr->lseg, |
262 | hdr->mds_offset + hdr->res.count); | ||
262 | dprintk("%s inode %lu pls_end_pos %lu\n", __func__, hdr->inode->i_ino, | 263 | dprintk("%s inode %lu pls_end_pos %lu\n", __func__, hdr->inode->i_ino, |
263 | (unsigned long) NFS_I(hdr->inode)->layout->plh_lwb); | 264 | (unsigned long) NFS_I(hdr->inode)->layout->plh_lwb); |
264 | } | 265 | } |
@@ -373,7 +374,7 @@ static int filelayout_commit_done_cb(struct rpc_task *task, | |||
373 | } | 374 | } |
374 | 375 | ||
375 | if (data->verf.committed == NFS_UNSTABLE) | 376 | if (data->verf.committed == NFS_UNSTABLE) |
376 | pnfs_commit_set_layoutcommit(data); | 377 | pnfs_set_layoutcommit(data->inode, data->lseg, data->lwb); |
377 | 378 | ||
378 | return 0; | 379 | return 0; |
379 | } | 380 | } |
@@ -1086,7 +1087,7 @@ filelayout_alloc_deviceid_node(struct nfs_server *server, | |||
1086 | } | 1087 | } |
1087 | 1088 | ||
1088 | static void | 1089 | static void |
1089 | filelayout_free_deveiceid_node(struct nfs4_deviceid_node *d) | 1090 | filelayout_free_deviceid_node(struct nfs4_deviceid_node *d) |
1090 | { | 1091 | { |
1091 | nfs4_fl_free_deviceid(container_of(d, struct nfs4_file_layout_dsaddr, id_node)); | 1092 | nfs4_fl_free_deviceid(container_of(d, struct nfs4_file_layout_dsaddr, id_node)); |
1092 | } | 1093 | } |
@@ -1137,7 +1138,8 @@ static struct pnfs_layoutdriver_type filelayout_type = { | |||
1137 | .read_pagelist = filelayout_read_pagelist, | 1138 | .read_pagelist = filelayout_read_pagelist, |
1138 | .write_pagelist = filelayout_write_pagelist, | 1139 | .write_pagelist = filelayout_write_pagelist, |
1139 | .alloc_deviceid_node = filelayout_alloc_deviceid_node, | 1140 | .alloc_deviceid_node = filelayout_alloc_deviceid_node, |
1140 | .free_deviceid_node = filelayout_free_deveiceid_node, | 1141 | .free_deviceid_node = filelayout_free_deviceid_node, |
1142 | .sync = pnfs_nfs_generic_sync, | ||
1141 | }; | 1143 | }; |
1142 | 1144 | ||
1143 | static int __init nfs4filelayout_init(void) | 1145 | static int __init nfs4filelayout_init(void) |