|
@@ -6359,12 +6359,8 @@ static void nfs4_layoutreturn_done(struct rpc_task *task, void *calldata)
|
|
|
return;
|
|
|
}
|
|
|
spin_lock(&lo->plh_inode->i_lock);
|
|
|
- if (task->tk_status == 0) {
|
|
|
- if (lrp->res.lrs_present) {
|
|
|
- pnfs_set_layout_stateid(lo, &lrp->res.stateid, true);
|
|
|
- } else
|
|
|
- BUG_ON(!list_empty(&lo->plh_segs));
|
|
|
- }
|
|
|
+ if (task->tk_status == 0 && lrp->res.lrs_present)
|
|
|
+ pnfs_set_layout_stateid(lo, &lrp->res.stateid, true);
|
|
|
lo->plh_block_lgets--;
|
|
|
spin_unlock(&lo->plh_inode->i_lock);
|
|
|
dprintk("<-- %s\n", __func__);
|