[PATCH 1/2] mtd: s3c2410: Change return type of s3c2410_nand_add_partition function

Sachin Kamat sachin.kamat at linaro.org
Thu Nov 8 05:08:43 EST 2012


The return value of s3c2410_nand_add_partition() is not checked for error
or success in the calling function. Hence change the return type to void.

Signed-off-by: Sachin Kamat <sachin.kamat at linaro.org>
---
 drivers/mtd/nand/s3c2410.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c
index 295e4be..dfb8636 100644
--- a/drivers/mtd/nand/s3c2410.c
+++ b/drivers/mtd/nand/s3c2410.c
@@ -726,15 +726,15 @@ static int s3c24xx_nand_remove(struct platform_device *pdev)
 	return 0;
 }
 
-static int s3c2410_nand_add_partition(struct s3c2410_nand_info *info,
+static void s3c2410_nand_add_partition(struct s3c2410_nand_info *info,
 				      struct s3c2410_nand_mtd *mtd,
 				      struct s3c2410_nand_set *set)
 {
 	if (set)
 		mtd->mtd.name = set->name;
 
-	return mtd_device_parse_register(&mtd->mtd, NULL, NULL,
-					 set->partitions, set->nr_partitions);
+	mtd_device_parse_register(&mtd->mtd, NULL, NULL,
+				  set->partitions, set->nr_partitions);
 }
 
 /**
-- 
1.7.4.1




More information about the linux-mtd mailing list