[OpenWrt-Devel] [PATCH 1/3] ipq40xx: Add gigadevice nandspi flash driver

Jeff Kletsky lede at allycomm.com
Wed Oct 30 11:15:49 EDT 2019

On 10/30/19 4:27 AM, Daniel Danzberger wrote:

> This patch adds support for Gigadevice SPI NAND device to the mt29f stagging driver.
> Signed-off-by: Daniel Danzberger <daniel at dd-wrt.com>
> ---
>   ...port-gigadevice-nandspi-flash-device.patch | 1778 +++++++++++++++++
>   1 file changed, 1778 insertions(+)
>   create mode 100644 target/linux/ipq40xx/patches-4.19/400-mtd-nand-support-gigadevice-nandspi-flash-device.patch
> [...]

Is there a reason why the upstream SPI-NAND framework isn't being used?

This has been demanded of the ath79 target (see, for example

and is available to the ipq40xx target and appears to already be in use by:


Further, the mt29f driver has been removed from upstream Linux

commit 647ad49ca672
Author: Boris Brezillon <boris.brezillon at bootlin.com>
Date:   Mon Oct 22 22:10:59 2018 +0200

     staging: Remove the mt29f_spinand driver

     A new SPI NAND subsystem has been added in drivers/mtd/nand/spi/ and
     Micron's MT29F devices are now supported in

     Remove the old driver.

The set of SPI-NAND chips supported by Linux 5.3 has already been
backported to OpenWrt `master`, including; GigaDevice, Macronix,
Micron, Paragon, Toshiba, and Winbond.

commit b9d58f7e06
Author: Jeff Kletsky <git-commits at allycomm.com>
Date:   Thu Oct 24 09:54:11 2019 -0700

     kernel: mtd: spinand: Backport chip definitions

     generic: Add/rename patches for upstream consistency

     ipq40xx: generic-level patch replaces same-source patches-4.19/

     The SPI-NAND framework from Linux uses common driver code that is then
     "tuned" by a tiny struct of chip-specific data that describes
     available commands, timing, and layout (data and OOB data). Several
     manufacturers and chips have been added since 4.19, several of which
     are used in devices already supported by OpenWrt (typically with no or
     "legacy" access to their NAND memory). This commit catches up the
     supported-chip definitions through Linux 5.2-rc6 and linux/next.

     The driver is only compiled for platforms with CONFIG_MTD_SPI_NAND=y.
     This presently includes ipq40xx and pistachio, with the addition of
     ath79-nand in these commits (and not ath79-generic or ath79-tiny).

     Upstream patches refreshed against 4.19.75

     Build-tested-on: ipq40xx
     Run-tested-on: ath79-nand

openwrt-devel mailing list
openwrt-devel at lists.openwrt.org

More information about the openwrt-devel mailing list