[PATCH v2 1/3] mtd: spinand: Remove write_enable_op() in markbad()
Tudor Ambarus
tudor.ambarus at linaro.org
Fri Nov 22 01:37:45 PST 2024
On 11/21/24 2:08 AM, tkuw584924 at gmail.com wrote:
> From: Takahiro Kuwano <Takahiro.Kuwano at infineon.com>
>
> We don't have to call spinand_write_enable_op() in spinand_markbad() as
> it is called in spinand_write_page().
Indeed. The patch is a follow up for:
Fixes: b645ad39d568 ("mtd: spinand: Do not erase the block before
writing a bad block marker")
That commit removed spinand_erase_op(), but failed to remove
spinand_write_enable_op() with it.
Reviewed-by: Tudor Ambarus <tudor.ambarus at linaro.org>
Miquel, shall the spinand_write_enable_op() call be moved into
spinand_erase_op()?
>
> Signed-off-by: Takahiro Kuwano <Takahiro.Kuwano at infineon.com>
> ---
> drivers/mtd/nand/spi/core.c | 4 ----
> 1 file changed, 4 deletions(-)
>
> diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c
> index 4d76f9f71a0e..47c369f2925d 100644
> --- a/drivers/mtd/nand/spi/core.c
> +++ b/drivers/mtd/nand/spi/core.c
> @@ -942,10 +942,6 @@ static int spinand_markbad(struct nand_device *nand, const struct nand_pos *pos)
> if (ret)
> return ret;
>
> - ret = spinand_write_enable_op(spinand);
> - if (ret)
> - return ret;
> -
> return spinand_write_page(spinand, &req);
> }
>
More information about the linux-mtd
mailing list