aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nfs')
-rw-r--r--fs/nfs/nfs4filelayout.c6
-rw-r--r--fs/nfs/pnfs.c14
-rw-r--r--fs/nfs/pnfs.h6
3 files changed, 18 insertions, 8 deletions
diff --git a/fs/nfs/nfs4filelayout.c b/fs/nfs/nfs4filelayout.c
index 194c48410336..49eeb044c109 100644
--- a/fs/nfs/nfs4filelayout.c
+++ b/fs/nfs/nfs4filelayout.c
@@ -99,7 +99,8 @@ static void filelayout_reset_write(struct nfs_write_data *data)
99 99
100 task->tk_status = pnfs_write_done_resend_to_mds(hdr->inode, 100 task->tk_status = pnfs_write_done_resend_to_mds(hdr->inode,
101 &hdr->pages, 101 &hdr->pages,
102 hdr->completion_ops); 102 hdr->completion_ops,
103 hdr->dreq);
103 } 104 }
104} 105}
105 106
@@ -119,7 +120,8 @@ static void filelayout_reset_read(struct nfs_read_data *data)
119 120
120 task->tk_status = pnfs_read_done_resend_to_mds(hdr->inode, 121 task->tk_status = pnfs_read_done_resend_to_mds(hdr->inode,
121 &hdr->pages, 122 &hdr->pages,
122 hdr->completion_ops); 123 hdr->completion_ops,
124 hdr->dreq);
123 } 125 }
124} 126}
125 127
diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c
index 6be70f622b62..97767c8683f9 100644
--- a/fs/nfs/pnfs.c
+++ b/fs/nfs/pnfs.c
@@ -1422,13 +1422,15 @@ EXPORT_SYMBOL_GPL(pnfs_generic_pg_test);
1422 1422
1423int pnfs_write_done_resend_to_mds(struct inode *inode, 1423int pnfs_write_done_resend_to_mds(struct inode *inode,
1424 struct list_head *head, 1424 struct list_head *head,
1425 const struct nfs_pgio_completion_ops *compl_ops) 1425 const struct nfs_pgio_completion_ops *compl_ops,
1426 struct nfs_direct_req *dreq)
1426{ 1427{
1427 struct nfs_pageio_descriptor pgio; 1428 struct nfs_pageio_descriptor pgio;
1428 LIST_HEAD(failed); 1429 LIST_HEAD(failed);
1429 1430
1430 /* Resend all requests through the MDS */ 1431 /* Resend all requests through the MDS */
1431 nfs_pageio_init_write(&pgio, inode, FLUSH_STABLE, compl_ops); 1432 nfs_pageio_init_write(&pgio, inode, FLUSH_STABLE, compl_ops);
1433 pgio.pg_dreq = dreq;
1432 while (!list_empty(head)) { 1434 while (!list_empty(head)) {
1433 struct nfs_page *req = nfs_list_entry(head->next); 1435 struct nfs_page *req = nfs_list_entry(head->next);
1434 1436
@@ -1463,7 +1465,8 @@ static void pnfs_ld_handle_write_error(struct nfs_write_data *data)
1463 if (!test_and_set_bit(NFS_IOHDR_REDO, &hdr->flags)) 1465 if (!test_and_set_bit(NFS_IOHDR_REDO, &hdr->flags))
1464 data->task.tk_status = pnfs_write_done_resend_to_mds(hdr->inode, 1466 data->task.tk_status = pnfs_write_done_resend_to_mds(hdr->inode,
1465 &hdr->pages, 1467 &hdr->pages,
1466 hdr->completion_ops); 1468 hdr->completion_ops,
1469 hdr->dreq);
1467} 1470}
1468 1471
1469/* 1472/*
@@ -1578,13 +1581,15 @@ EXPORT_SYMBOL_GPL(pnfs_generic_pg_writepages);
1578 1581
1579int pnfs_read_done_resend_to_mds(struct inode *inode, 1582int pnfs_read_done_resend_to_mds(struct inode *inode,
1580 struct list_head *head, 1583 struct list_head *head,
1581 const struct nfs_pgio_completion_ops *compl_ops) 1584 const struct nfs_pgio_completion_ops *compl_ops,
1585 struct nfs_direct_req *dreq)
1582{ 1586{
1583 struct nfs_pageio_descriptor pgio; 1587 struct nfs_pageio_descriptor pgio;
1584 LIST_HEAD(failed); 1588 LIST_HEAD(failed);
1585 1589
1586 /* Resend all requests through the MDS */ 1590 /* Resend all requests through the MDS */
1587 nfs_pageio_init_read(&pgio, inode, compl_ops); 1591 nfs_pageio_init_read(&pgio, inode, compl_ops);
1592 pgio.pg_dreq = dreq;
1588 while (!list_empty(head)) { 1593 while (!list_empty(head)) {
1589 struct nfs_page *req = nfs_list_entry(head->next); 1594 struct nfs_page *req = nfs_list_entry(head->next);
1590 1595
@@ -1615,7 +1620,8 @@ static void pnfs_ld_handle_read_error(struct nfs_read_data *data)
1615 if (!test_and_set_bit(NFS_IOHDR_REDO, &hdr->flags)) 1620 if (!test_and_set_bit(NFS_IOHDR_REDO, &hdr->flags))
1616 data->task.tk_status = pnfs_read_done_resend_to_mds(hdr->inode, 1621 data->task.tk_status = pnfs_read_done_resend_to_mds(hdr->inode,
1617 &hdr->pages, 1622 &hdr->pages,
1618 hdr->completion_ops); 1623 hdr->completion_ops,
1624 hdr->dreq);
1619} 1625}
1620 1626
1621/* 1627/*
diff --git a/fs/nfs/pnfs.h b/fs/nfs/pnfs.h
index 97cb358bb882..94ba80417748 100644
--- a/fs/nfs/pnfs.h
+++ b/fs/nfs/pnfs.h
@@ -230,9 +230,11 @@ struct pnfs_layout_segment *pnfs_update_layout(struct inode *ino,
230 230
231void nfs4_deviceid_mark_client_invalid(struct nfs_client *clp); 231void nfs4_deviceid_mark_client_invalid(struct nfs_client *clp);
232int pnfs_read_done_resend_to_mds(struct inode *inode, struct list_head *head, 232int pnfs_read_done_resend_to_mds(struct inode *inode, struct list_head *head,
233 const struct nfs_pgio_completion_ops *compl_ops); 233 const struct nfs_pgio_completion_ops *compl_ops,
234 struct nfs_direct_req *dreq);
234int pnfs_write_done_resend_to_mds(struct inode *inode, struct list_head *head, 235int pnfs_write_done_resend_to_mds(struct inode *inode, struct list_head *head,
235 const struct nfs_pgio_completion_ops *compl_ops); 236 const struct nfs_pgio_completion_ops *compl_ops,
237 struct nfs_direct_req *dreq);
236struct nfs4_threshold *pnfs_mdsthreshold_alloc(void); 238struct nfs4_threshold *pnfs_mdsthreshold_alloc(void);
237 239
238/* nfs4_deviceid_flags */ 240/* nfs4_deviceid_flags */