Messages in this thread | | | From | Peter Pan 潘栋 (peterpandong) <> | Subject | [PATCH 0/3] An alternative to SPI NAND | Date | Thu, 8 Jan 2015 00:47:24 +0000 |
| |
This patchset is an alternative to Ezequiel's series[1].
This patchset separate SPI NAND code and Parallel NAND code, make SPI NAND have its own spi_nand_scan, read, write, BBM mechanism, so that it would be better for code maintenance in the future.
TODO - 1. This patchset is validated only on Micron SPI NAND device MT29F2G01AAAED by run mtdtest program, and mount UBIFS on SPI NAND, further testing on other Manufactory SPI NAND is needed. 2. Although this patchset's framework separate SPI NAND and Parall NAND code, some code do is common that can share by SPI NAND and Parallel NAND at same time. For view the code structure might be more make sense as below diagram, so that SPI NAND and Parallel NAND can have their own specific code and meanwhile can share Common code. But may bring a lot change for current code, I am glad to discuss this structure if any guys are interested.
|------------------------------------------------------------------| | MTD/NAND folder | | |-------------| |---------------| |-------------------------| | | | Common code | | SPI NAND code | | Parallel NAND code | | | |-------------| | --------------| |-------------------------| | | | Nand_bch.c | |spi_nand_base.c| | parallel_nand_base.c | | | | Nand_ecc.c | | ......... | |specific controllers code| | | | Nand_bbt.c | | | | | | |------------------------------------------------------------------|
This series is based on v3.19-rc1. [1] http://lists.infradead.org/pipermail/linux-mtd/2014-December/056763.html
Peter Pan (3): mtd: spi-nand framework mtd: spi-nand: support spi-nand devices mtd: spi-nand: add devicetree binding
Documentation/devicetree/bindings/mtd/spi-nand.txt | 22 + drivers/mtd/Kconfig | 2 + drivers/mtd/Makefile | 1 + drivers/mtd/spi-nand/Kconfig | 7 + drivers/mtd/spi-nand/Makefile | 3 + drivers/mtd/spi-nand/spi-nand-base.c | 2034 ++++++++++++++++++++ drivers/mtd/spi-nand/spi-nand-bbt.c | 1279 ++++++++++++ drivers/mtd/spi-nand/spi-nand-device.c | 281 +++ include/linux/mtd/spi-nand.h | 317 +++ 9 files changed, 3946 insertions(+) create mode 100644 Documentation/devicetree/bindings/mtd/spi-nand.txt create mode 100644 drivers/mtd/spi-nand/Kconfig create mode 100644 drivers/mtd/spi-nand/Makefile create mode 100644 drivers/mtd/spi-nand/spi-nand-base.c create mode 100644 drivers/mtd/spi-nand/spi-nand-bbt.c create mode 100644 drivers/mtd/spi-nand/spi-nand-device.c create mode 100644 include/linux/mtd/spi-nand.h
-- 1.9.1
| |