Patch Upstream: pnfs-obj: pNFS errors are communicated on iodata->pnfs_error
Subsystems (2)
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 6 lines · Greg KH
Care to provide me such a patch for 3.0?
thanks,
greg k-h
Hi this is a 3.1 and 3.0 version of this patch. It is based on todays stable tree checkout. It will apply cleanly to both linux-3.0.y and linux-3.1.y branches.
Thanks
Boaz
---
From: Boaz Harrosh <[email protected]>
Subject: pnfs-obj: pNFS errors are communicated on iodata->pnfs_error (linux-3.0.y)
Some time along the way pNFS IO errors were switched to communicate with a special iodata->pnfs_error member instead of the regular RPC members. But objlayout was not switched over.
Fix that!
Without this fix any IO error is hanged, because IO is not switched to MDS and pages are never cleared or read.
--- fs/nfs/objlayout/objlayout.c | 10 +++++++--- 1 files changed, 7 insertions(+), 3 deletions(-)
fs/nfs/objlayout/objlayout.c +7 -3
@@ -294,9 +294,11 @@ objlayout_read_done(struct objlayout_io_state *state, ssize_t status, bool sync)dprintk ("%s: Begin status=%zd eof=%d\n" , __func__, status, eof); rdata = state->rpcdata; rdata->task.tk_status = status; -if (status >=0 ) { +if (likely (status >=0 )) { rdata->res.count = status; rdata->res.eof = eof; + }else { + rdata->pnfs_error = status; }objlayout_iodone (state);/* must not use state after this point */
@@ -380,15 +382,17 @@ objlayout_write_done(struct objlayout_io_state *state, ssize_t status, wdata = state->rpcdata; state->status = status; wdata->task.tk_status = status; -if (status >=0 ) { +if (likely (status >=0 )) { wdata->res.count = status; wdata->verf.committed = state->committed;dprintk ("%s: Return status %d committed %d\n" , __func__, wdata->task.tk_status, wdata->verf.committed); - }else + }else { + wdata->pnfs_error = status;dprintk ("%s: Return status %d\n" , __func__, wdata->task.tk_status); + }objlayout_iodone (state);/* must not use state after this point */
Signature · 1 line
1.7.2.3
Quoted 11 lines · Boaz Harrosh
Quoted 6 lines · Greg KH
Care to provide me such a patch for 3.0?
thanks,
greg k-h
Hi this is a 3.1 and 3.0 version of this patch. It is based on todays stable tree checkout. It will apply cleanly to both linux-3.0.y and linux-3.1.y branches.
Thanks for the backport. As 3.1.y is now end-of-life, I've applied this to the 3.0.y tree only.
thanks,
greg k-h