> Is there a reason why the upstream SPI-NAND framework isn't being used?
No, I didn't know about it. The patches I used are copied from a compex openwrt tree and have only been modified by me to run on kernel 4.19 I am going to checkout the new API and try to make the device work with it. On 10/30/19 4:15 PM, Jeff Kletsky wrote: > 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 <dan...@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 > https://github.com/openwrt/openwrt/pull/1428#issuecomment-441594401) > > and is available to the ipq40xx target and appears to already be in use by: > > qcom-ipq4018-rt-ac58u.dts > qcom-ipq4018-ea6350v3.dts > qcom-ipq4018-ap120c-ac.dts > qcom-ipq4018-jalapeno.dts > > > > Further, the mt29f driver has been removed from upstream Linux > > commit 647ad49ca672 > Author: Boris Brezillon <boris.brezil...@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 > drivers/mtd/nand/spi/micron.c. > > 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-comm...@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/ > 082-v4.20-mtd-spinand-winbond-Add-support-for-W25N01GV.patch > > 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 > > > > -- Regards Daniel Danzberger embeDD GmbH, Alter Postplatz 2, CH-6370 Stans _______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel