[U-Boot] mtd: spi-nor: new NXP FlexSPI driver location & framework to use ?
Boris Brezillon
boris.brezillon at bootlin.com
Sat May 12 05:50:23 UTC 2018
Hi Jagan,
On Fri, 11 May 2018 11:30:43 +0530
Jagan Teki <jagannadh.teki at gmail.com> wrote:
> On Fri, May 11, 2018 at 11:08 AM, Prabhakar Kushwaha
> <prabhakar.kushwaha at nxp.com> wrote:
> > Dear Jagan,
> >
> > NXP is coming up with new FlexSPI controller. It is similar to existing QSPI with enhanced feature-set.
> > We have the driver ready as per existing framework i.e. driver/spi.
> >
> > From recend discussion, we go to know about framework change. Migration of qspi drivers in u-boot-spi/drivers/mtd/spi-nor/
> > git://git.denx.de/u-boot-spi.git branch mtd-spinor-working.
> >
> > We are in dilemma for sending FlexSPI driver upstream.
> > Do we follow existing framework i.e. driver/spi or new proposed framework i.e. u-boot-spi/drivers/mtd/spi-nor/
> >
> > Also, do we have any timeline of u-boot-spi/drivers/mtd/spi-nor/ to become default.
>
> Idea is to move spi-nor, mtd-spinor-working is paused because of
> non-dm drivers accessing. We are clear that we can't create another
> legacy layer to access spi-nor for the sake of non-dm driver to work
> which eventually ended-up another mess and also no one take care of
> non-dm conversion to dm if we give such feasibility. So we exported a
> deadline for full SPI/SPI_FLASH DM conversion till v2018.09. Once all
> these relevant conversion done, will try to move.
Just for the record, the spi-mem interface has been accepted in Linux
[1] (should be there in 4.18). From now on, I'll try to encourage people
move existing spi-nor controller drivers to the SPI subsystem, and I'll
definitely ask new QPSI drivers to use this interface (and extend it if
needed).
So, I'm not sure creating this spi-nor subsystem in uboot is a good
idea anymore. Of course, it's up to you to decide, but if you take this
path you'll run into the same problem we had in Linux:
- how to support SPI NANDs in a clean and efficient way
- how to support both memory-like operations and regular SPI transfers
with the same driver
Regards,
Boris
[1]https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git/commit/?h=for-4.18&id=c36ff266dc82f4ae797a6f3513c6ffa344f7f1c7
More information about the U-Boot
mailing list