From f3236cef5a206c27a624b8a813ddc1ebc4c6637a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20Gonz=C3=A1lez?= Date: Sat, 22 Apr 2017 01:32:46 +0200 Subject: [PATCH] lightnvm: pblk: fix bad error check MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix bad error check Fixes: a4bd217b4326 "lightnvm: physical block device (pblk) target" Signed-off-by: Javier González Reviewed-by: Matias Bjørling Signed-off-by: Jens Axboe --- drivers/lightnvm/pblk-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/lightnvm/pblk-core.c b/drivers/lightnvm/pblk-core.c index 7065658fd7ee..7eb62ec6c583 100644 --- a/drivers/lightnvm/pblk-core.c +++ b/drivers/lightnvm/pblk-core.c @@ -1273,7 +1273,7 @@ retry_meta: retry_setup: if (!pblk_line_set_metadata(pblk, new, cur)) { new = pblk_line_retry(pblk, new); - if (new) + if (!new) return NULL; goto retry_setup;