|
@@ -549,13 +549,13 @@ static void nfs_direct_write_result(struct rpc_task *task, void *calldata)
|
|
|
|
|
|
spin_lock(&dreq->lock);
|
|
spin_lock(&dreq->lock);
|
|
|
|
|
|
- if (unlikely(dreq->error != 0))
|
|
|
|
- goto out_unlock;
|
|
|
|
if (unlikely(status < 0)) {
|
|
if (unlikely(status < 0)) {
|
|
- /* An error has occured, so we should not commit */
|
|
|
|
|
|
+ /* An error has occurred, so we should not commit */
|
|
dreq->flags = 0;
|
|
dreq->flags = 0;
|
|
dreq->error = status;
|
|
dreq->error = status;
|
|
}
|
|
}
|
|
|
|
+ if (unlikely(dreq->error != 0))
|
|
|
|
+ goto out_unlock;
|
|
|
|
|
|
dreq->count += data->res.count;
|
|
dreq->count += data->res.count;
|
|
|
|
|