[PATCH] NAND: fix nand_write_oob_std return value

Thomas Gleixner tglx at linutronix.de
Wed Jun 21 07:43:02 EDT 2006


On Wed, 2006-06-21 at 15:36 +0400, Alexander Belyakov wrote:
> It seems nand_write_oob_std should not return just status value
> 
> Signed-off-by: Alexander Belyakov <alexander.belyakov at intel.com>
> 
> diff --git a/drivers/mtd/nand/nand_base.c b/drivers/mtd/nand/nand_base.c
> index 27083ed..79eae5d 100644
> --- a/drivers/mtd/nand/nand_base.c
> +++ b/drivers/mtd/nand/nand_base.c
> @@ -1176,7 +1176,7 @@ static int nand_write_oob_std(struct mtd
> 
>  	status = chip->waitfunc(mtd, chip);
> 
> -	return status;
> +	return status & NAND_STATUS_FAIL ? -EIO : 0;
>  }

You are the second one to notice. Already fixed.

Thanks anyway,

	tglx


	





More information about the linux-mtd mailing list