public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH] mtd: readtest: don't clobber error reports
@ 2015-05-12 21:33 Brian Norris
  2015-05-14  8:26 ` Richard Weinberger
  0 siblings, 1 reply; 3+ messages in thread
From: Brian Norris @ 2015-05-12 21:33 UTC (permalink / raw)
  To: linux-mtd; +Cc: Richard Weinberger, Brian Norris

Commit 2a6a28e7922c ("mtd: Make MTD tests cancelable") accidentally
clobbered any read failure reports.

Coverity CID #1296020

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
---
regression in v4.1-rc1, so I'll probably want to queue this for 4.1

 drivers/mtd/tests/readtest.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/tests/readtest.c b/drivers/mtd/tests/readtest.c
index a3196b750a22..58df07acdbdb 100644
--- a/drivers/mtd/tests/readtest.c
+++ b/drivers/mtd/tests/readtest.c
@@ -191,9 +191,11 @@ static int __init mtd_readtest_init(void)
 				err = ret;
 		}
 
-		err = mtdtest_relax();
-		if (err)
+		ret = mtdtest_relax();
+		if (ret) {
+			err = ret;
 			goto out;
+		}
 	}
 
 	if (err)
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-05-14 16:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-12 21:33 [PATCH] mtd: readtest: don't clobber error reports Brian Norris
2015-05-14  8:26 ` Richard Weinberger
2015-05-14 16:57   ` Brian Norris

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox