[PATCH 2/2] MIPS/mtd: Handle READY GPIO in generic NAND platform data

Miquel Raynal miquel.raynal at bootlin.com
Mon Mar 30 01:04:30 PDT 2026


On 28/03/2026 at 16:55:48 +01, Linus Walleij <linusw at kernel.org> wrote:

> The callbacks into the MIPS RB532 platform to read the GPIO pin
> indicating that the NAND chip is ready are oldschool and does
> not assign GPIOs as properties to the NAND device.
>
> Add a capability to the generic platform NAND chip driver to use
> a GPIO line to detect if a NAND chip is ready and override the
> platform-local drv_ready() callback with this check if the GPIO
> is present.
>
> This makes it possible to drop the legacy include header
> <linux/gpio.h> from the RB532 devices.
>
> Signed-off-by: Linus Walleij <linusw at kernel.org>
> ---
>  arch/mips/rb532/devices.c        | 36 +++++++++++++++++++++---------------
>  drivers/mtd/nand/raw/plat_nand.c | 24 +++++++++++++++++++++++-

Fine by me for the MTD bits!

Acked-by: Miquel Raynal <miquel.raynal at bootlin.com>

Thanks,
Miquèl



More information about the linux-mtd mailing list