From: Dmitry Eremin-Solenikov Date: Thu, 2 Jun 2011 14:00:37 +0000 (+0400) Subject: mtd: fsl_upm.c: use mtd_device_parse_register X-Git-Tag: next-20110912~52^2~70 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=73f36b3e251888ef224a3c90d3c408e02a1eb957;p=karo-tx-linux.git mtd: fsl_upm.c: use mtd_device_parse_register Replace custom invocations of parse_mtd_partitions and mtd_device_register with common mtd_device_parse_register call. This would bring: standard handling of all errors, fallback to default partitions, etc. Signed-off-by: Dmitry Eremin-Solenikov Signed-off-by: Artem Bityutskiy --- diff --git a/drivers/mtd/nand/fsl_upm.c b/drivers/mtd/nand/fsl_upm.c index 714d8318c6ad..da92fed9f27b 100644 --- a/drivers/mtd/nand/fsl_upm.c +++ b/drivers/mtd/nand/fsl_upm.c @@ -193,9 +193,7 @@ static int __devinit fun_chip_init(struct fsl_upm_nand *fun, goto err; ppdata.of_node = flash_np; - ret = parse_mtd_partitions(&fun->mtd, NULL, &fun->parts, &ppdata); - - ret = mtd_device_register(&fun->mtd, fun->parts, ret); + ret = mtd_device_parse_register(&fun->mtd, NULL, &ppdata, NULL, 0); err: of_node_put(flash_np); return ret;