summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/chips/chipreg.c
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2012-02-13 16:12:24 +0100
committerJiri Kosina <jkosina@suse.cz>2012-02-28 15:55:13 +0100
commit0a413d708a5df80f50b2fb8c24a32c559a06bffc (patch)
treec552413ed869985310f93ac70eb222bd695c0fcc /drivers/mtd/chips/chipreg.c
parentmm: fix comment typo of truncate_inode_pages_range (diff)
downloadlinux-0a413d708a5df80f50b2fb8c24a32c559a06bffc.tar.xz
linux-0a413d708a5df80f50b2fb8c24a32c559a06bffc.zip
mtd: simplify return logic in do_map_probe()
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/mtd/chips/chipreg.c')
-rw-r--r--drivers/mtd/chips/chipreg.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/mtd/chips/chipreg.c b/drivers/mtd/chips/chipreg.c
index da1f96f385c7..0bbc61ba9524 100644
--- a/drivers/mtd/chips/chipreg.c
+++ b/drivers/mtd/chips/chipreg.c
@@ -76,10 +76,7 @@ struct mtd_info *do_map_probe(const char *name, struct map_info *map)
*/
module_put(drv->module);
- if (ret)
- return ret;
-
- return NULL;
+ return ret;
}
/*
* Destroy an MTD device which was created for a map device.