summaryrefslogtreecommitdiff
path: root/drivers/mtd
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2016-11-04 13:43:09 +0300
committerBoris Brezillon <boris.brezillon@free-electrons.com>2016-11-07 16:48:52 +0300
commitc75183020fca0229fce1fd6ba21ae840b41d79e9 (patch)
tree076f2e157a90ec019ee077f8b18d38683a02ec02 /drivers/mtd
parent133fe8fa614175eb7e59599dbfe357c7bc7da851 (diff)
downloadlinux-c75183020fca0229fce1fd6ba21ae840b41d79e9.tar.xz
mtd: nand: nandsim: remove unneeded checks for nand_scan_ident/tail()
The nand_scan_ident/tail() never returns a positive value when it fails. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/nand/nandsim.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/mtd/nand/nandsim.c b/drivers/mtd/nand/nandsim.c
index 1eb934414eb5..c76287a69663 100644
--- a/drivers/mtd/nand/nandsim.c
+++ b/drivers/mtd/nand/nandsim.c
@@ -2313,8 +2313,6 @@ static int __init ns_init_module(void)
retval = nand_scan_ident(nsmtd, 1, NULL);
if (retval) {
NS_ERR("cannot scan NAND Simulator device\n");
- if (retval > 0)
- retval = -ENXIO;
goto error;
}
@@ -2350,8 +2348,6 @@ static int __init ns_init_module(void)
retval = nand_scan_tail(nsmtd);
if (retval) {
NS_ERR("can't register NAND Simulator\n");
- if (retval > 0)
- retval = -ENXIO;
goto error;
}