提交 654a01b7 编写于 作者: C Christophe JAILLET 提交者: Jens Axboe

lightnvm: Fix error handling

According to error handling in this function, it is likely that going to
'out' was expected here.
Signed-off-by: NChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: NMatias Bjørling <matias@cnexlabs.com>
Signed-off-by: NJens Axboe <axboe@fb.com>
上级 a88086e0
......@@ -1275,8 +1275,10 @@ static int rrpc_bb_discovery(struct nvm_tgt_dev *dev, struct rrpc_lun *rlun)
}
nr_blks = nvm_bb_tbl_fold(dev->parent, blks, nr_blks);
if (nr_blks < 0)
return nr_blks;
if (nr_blks < 0) {
ret = nr_blks;
goto out;
}
for (i = 0; i < nr_blks; i++) {
if (blks[i] == NVM_BLK_T_FREE)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册