[U-Boot] [PATCH v10] nand/denali: Adding Denali NAND driver support
Masahiro Yamada
yamada.m at jp.panasonic.com
Thu Sep 25 09:36:43 CEST 2014
Hi Scott,
On Wed, 24 Sep 2014 18:34:52 -0500
Scott Wood <scottwood at freescale.com> wrote:
> On Wed, 2014-09-24 at 23:05 +0900, Masahiro YAMADA wrote:
> > Hi Scott, Tom,
> >
> >
> > 2014-09-12 19:43 GMT+09:00 Masahiro Yamada <yamada.m at jp.panasonic.com>:
> > >
> > > On Fri, 12 Sep 2014 00:42:17 -0500
> > > Chin Liang See <clsee at altera.com> wrote:
> > >
> > >> To add the Denali NAND driver support into U-Boot.
> > >> This driver is leveraged from Linux with commit ID
> > >> fdbad98dff8007f2b8bee6698b5d25ebba0471c9. For Denali
> > >> controller 64 variance, you need to declare macro
> > >> CONFIG_SYS_NAND_DENALI_64BIT.
> > >>
> > >> Signed-off-by: Chin Liang See <clsee at altera.com>
> > >> Cc: Scott Wood <scottwood at freescale.com>
> > >> Cc: Masahiro Yamada <yamada.m at jp.panasonic.com>
> > >> ---
> > >> Changes for v10
> > >> - Updated the commit message to include Linux driver commit ID,
> > >> usage of macro CONFIG_SYS_NAND_DENALI_64BIT
> > >> - Removed casting for memcpy function
> > >> - Removed NAND_CMD_LOCK_TIGHT support as no longer in latest NAND driver
> > >
> > >
> > > Signed-off-by: Masahiro Yamada <yamada.m at jp.panasonic.com>
> > > Reviewed-by: Masahiro Yamada <yamada.m at jp.panasonic.com>
> > > Tested-by: Masahiro Yamada <yamada.m at jp.panasonic.com>
> > >
> > >
> > > I am looking forward to get this driver in.
> > >
> >
> >
> > How about this patch?
> >
> >
> > There are only some cosmetic updates in v10.
> > I think enough time has passed for the review.
> >
> > If Scott could apply it, that would be the best,
> > but he seems really busy for Linux work these days
> > as he stated in http://lists.denx.de/pipermail/u-boot/2014-May/180399.html.
> >
> > Tom,
> > If Scott is too busy to take care of this patch,
> > could you apply it directly onto u-boot/master, please?
>
> How would I go about testing that this builds? I don't see any code in
> the tree that defines CONFIG_NAND_DENALI, nor is it obvious which board
> I should add it to as a test.
If you want to do build test,
apply the following patches in this order:
[U-Boot,v10] nand/denali: Adding Denali NAND driver support
http://patchwork.ozlabs.org/patch/388486/
[U-Boot,v3,1/6] nand: denali: add Denali NAND driver for SPL
http://patchwork.ozlabs.org/patch/385078/
[U-Boot,v3,2/6] serial: add UniPhier serial driver
http://patchwork.ozlabs.org/patch/385077/
[U-Boot,v3,3/6] arm: uniphier: add UniPhier SoC support code
http://patchwork.ozlabs.org/patch/385082/
[U-Boot,v3,4/6] arm: uniphier: add Kconfig and defconfig
http://patchwork.ozlabs.org/patch/385080/
Or you can use a branch I prepared for you:
$ git clone git://github.com/masahir0y/u-boot-kbuild.git
Cloning into 'u-boot-kbuild'...
remote: Counting objects: 10073, done.
remote: Compressing objects: 100% (4378/4378), done.
remote: Total 10073 (delta 4231), reused 8489 (delta 3511)
Receiving objects: 100% (10073/10073), 1.84 MiB | 265.00 KiB/s, done.
Resolving deltas: 100% (4231/4231), done.
Checking connectivity... done.
$ cd u-boot-kbuild/
$ git checkout -b denali_test origin/denali_test
Branch denali_test set up to track remote branch denali_test from origin.
Switched to a new branch 'denali_test'
$ make ph1_ld4_defconfig
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
SHIPPED scripts/kconfig/zconf.tab.c
SHIPPED scripts/kconfig/zconf.lex.c
SHIPPED scripts/kconfig/zconf.hash.c
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
#
# configuration written to .config
#
#
# configuration written to spl/.config
#
$ make CROSS_COMPILE=arm-linux-gnueabi-
scripts/kconfig/conf --silentoldconfig Kconfig
scripts/kconfig/conf --silentoldconfig Kconfig
CHK include/config.h
UPD include/config.h
GEN include/autoconf.mk
GEN include/autoconf.mk.dep
GEN spl/include/autoconf.mk
CHK include/config/uboot.release
UPD include/config/uboot.release
CHK include/generated/version_autogenerated.h
UPD include/generated/version_autogenerated.h
CHK include/generated/timestamp_autogenerated.h
[ snip ]
CC drivers/mtd/mtdcore.o
CC drivers/mtd/cfi_flash.o
LD drivers/mtd/built-in.o
CC drivers/mtd/nand/nand.o
CC drivers/mtd/nand/nand_bbt.o
CC drivers/mtd/nand/nand_ids.o
CC drivers/mtd/nand/nand_util.o
CC drivers/mtd/nand/nand_ecc.o
CC drivers/mtd/nand/nand_base.o
CC drivers/mtd/nand/denali.o <=====
LD drivers/mtd/nand/built-in.o
LD drivers/mtd/onenand/built-in.o
LD drivers/mtd/spi/built-in.o
> Also, CONFIG_SYS_NAND_DENALI_64BIT should be documented in a README, not
> just in the git changelog.
>
I will send a follow up patch.
Anyway, it is an old style to document each option in README.
I will add it to Kconfig with a help doc, something like this:
config SYS_NAND_DENALI_64BIT
bool "Support Denali NAND controller with 64bit AXI interface"
depends on NAND_DENALI
help
The Denali NAND controller has some variations depending on the bus interface.
DMA setup sequence is completely differenct between 32bit / 64bit AXI bus version.
If you want to use the Denali NAND controller with 64bit AXI interface, say Y.
Otherwise (32bit AXI), say N.
Best Regards
Masahiro Yamada
More information about the U-Boot
mailing list