Dear
How do you need to program a nand flash using u-boot? I have created an ubifs image using Yocto. This image is loaded using the mfgtool to RAM. I now want to program the nand flash and I'm facing trouble. This is the way I do it:
> setenv mtdparts mtdparts= nand_flash:32m(kernel),32m(dtb),64m(root),-(data)
> setenv mtdids nand0=nand_flash
> nand erase.chip
> mdtparts
> ubi part root
> ubi create root
> ubi write 0x8380 0000 root 0x12A0000
(0x83800000 => the ubifs image is loaded there and 0x12A0000 is the size of the image)
> bootz ${loadaddr} - ${fdt_addr}
I get:
VFS: Cannot open root device "ubi0:root" or unknown-block(0,0): error -19
[ 1.423467] Please append a correct "root=" boot option; here are the available partitions:
[ 1.431983] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
Is this a good way of working or is it preferred to use another method to progam my imx6ul device?
Best regards
Pieter
Hi Pieter
one can try patch for U-Boot that integrates nxp kobs utility into U-Boot
[U-Boot] i.MX6 nand bootupdate, reworked - Patchwork
nxp provides only mfg tools option for nand programming, use *.vbs
script for board with nand, like mfgtool2-yocto-mx-sabreauto-nand.vbs
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------