summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/chips
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2012-02-13 16:12:24 +0100
committerDavid Woodhouse <David.Woodhouse@intel.com>2012-03-27 00:35:06 +0100
commit3410a711a52bdb5eac1395fc6734a3ef801f903b (patch)
tree35548820a65b027a56cb4752ea230dddbab5c6ad /drivers/mtd/chips
parent88dfda5f7463ce73f14f4eaf275284047f367570 (diff)
downloadtalos-obmc-linux-3410a711a52bdb5eac1395fc6734a3ef801f903b.tar.gz
talos-obmc-linux-3410a711a52bdb5eac1395fc6734a3ef801f903b.zip
mtd: simplify return logic in do_map_probe()
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/mtd/chips')
-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.
OpenPOWER on IntegriCloud