mtd: error return -EIO instead of EIO
PATCH 3/4 mtd: error return -EIO instead of EIO
From: Roel Kluin <[email protected]>
Return a negative error value instead of a positive
Signed-off-by Roel Kluin <[email protected]>
Cc David Woodhouse <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
drivers/mtd/maps/physmap.c | 2 +- drivers/mtd/maps/vmu-flash.c | 2 +- drivers/mtd/nand/atmel_nand.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)
drivers/mtd/maps/physmap.c renamed from drivers/mtd/maps/physmap.c~mtd-error-return-eio-instead-of-eio +1 -1
@@ -129,7 +129,7 @@ static int physmap_flash_probe(struct pl info->map[i].size);if (info->map[i].virt ==NULL ) {dev_err (&dev->dev,"Failed to ioremap flash region\n" ); - err =EIO ; + err = -EIO ; goto err_out; }
drivers/mtd/maps/vmu-flash.c renamed from drivers/mtd/maps/vmu-flash.c~mtd-error-return-eio-instead-of-eio +1 -1
@@ -621,7 +621,7 @@ static int __devinit vmu_connect(struct card =kmalloc (sizeof (struct memcard ),GFP_KERNEL );if (!card) { - error =ENOMEM ; + error = -ENOMEM ; goto fail_nomem; }
drivers/mtd/nand/atmel_nand.c renamed from drivers/mtd/nand/atmel_nand.c~mtd-error-return-eio-instead-of-eio +2 -2
@@ -463,7 +463,7 @@ static int __init atmel_nand_probe(strucif (host->board->det_pin) {if (gpio_get_value (host->board->det_pin)) {printk (KERN_INFO "No SmartMedia card inserted.\n" ); - res =ENXIO ; + res = -ENXIO ; goto err_no_card; } }
@@ -534,7 +534,7 @@ static int __init atmel_nand_probe(strucif ((!partitions) || (num_partitions ==0 )) {printk (KERN_ERR "atmel_nand: No partitions defined, or unsupported device.\n" ); - res =ENXIO ; + res = -ENXIO ; goto err_no_partitions; }
_
Quoted 7 lines · On Tue, 2009-11-17 at 14:45 -0800, [email protected] wrote:
From: Roel Kluin <[email protected]>
Return a negative error value instead of a positive
Signed-off-by Roel Kluin <[email protected]>Cc David Woodhouse <[email protected]>Signed-off-by Andrew Morton <[email protected]>
This patch also sits in my tree, so this should not be forgotten.
Signature · 2 lines
Best Regards, Artem Bityutskiy (Артём Битюцкий)