[U-Boot] [PATCH v3 0/4] sunxi: nand: Basic NAND driver for SPL

Hans de Goede hdegoede at redhat.com
Sat Aug 1 14:15:53 CEST 2015


Hi,

On 23-07-15 14:33, Piotr Zierhoffer wrote:
> This is a basic driver for the sunxi NAND controller for Allwinner A20.
> It supports only SPL.
>
> The driver uses DMA for data transfers. It does not support writing.

Thanks for your work on this.

I've merged patches 1 - 3 in my sunxi-wip branch,
and I'll include them in the next u-boot-sunxi pull-req.

We do need to do some more work on this, to support
more different sunxi SoCs, and to add some retry logic
in case the default boot pages of the nand are bad,
but that can both be done in follow-up commits.

Regards,

Hans



>
> Changes in v3:
> - moved pinmux and clock to board level
> - code cleanup with significant size reduction
> - renamed the driver file
> - renamed constants to match Kconfig convention
> - moved defines from .h to .c, and renamed them to be consistent with
>    each other
> - removed more magic values
> - changed ecc_errors from static to local variable
> - other minor changes
> - added new options in Kconfig to support different chips
> - changed descriptions to comply with patman rules
>
> Changes in v2:
> - removed traces of non-SPL-specific code
> - moved the driver from boards/sunxi to drivers/mtd/nand
> - moved magic values to defines (whenever possible)
> - removed unnecesary late initialisation code
> - code style changes as suggested for the first patch set:
>    - changed visibility of some symbols
>    - renamed unclear variables
>    - renamed header protector
>    - changed types of pointer variables
>    - other minor changes
> - removed traces of non-SPL specific code
> - renamed defines to be more relevant
> - moved Kconfig entry for the driver to drivers/mtd/nand
> - reworded Kconfig entry help
>
> Karol Gugala (1):
>    sunxi: nand: Add pinmux and clock settings for NAND support
>
> Piotr Zierhoffer (3):
>    sunxi: nand: Add basic sunxi NAND driver for SPL with DMA support
>    sunxi: nand: Add board configuration options
>    sunxi: nand: Add information to sunxi that it was run from NAND in SPL
>
>   arch/arm/cpu/armv7/sunxi/board.c              |   4 +
>   arch/arm/include/asm/arch-sunxi/clock_sun4i.h |   2 +
>   arch/arm/include/asm/arch-sunxi/gpio.h        |   1 +
>   board/sunxi/board.c                           |  27 ++
>   drivers/mtd/nand/Kconfig                      |  40 +++
>   drivers/mtd/nand/Makefile                     |   1 +
>   drivers/mtd/nand/sunxi_nand_spl.c             | 353 ++++++++++++++++++++++++++
>   include/configs/sunxi-common.h                |  10 +
>   8 files changed, 438 insertions(+)
>   create mode 100644 drivers/mtd/nand/sunxi_nand_spl.c
>


More information about the U-Boot mailing list