I want to flash the android ubifs images by fastboot,
my NAND flash is Samsung K9F4G08U0A, 512MiB 3,3V 8-bit, page size is 2k, each block contains 64 pages.
I create the ubi.img as follows,
$ sudo mkfs.ubifs -r temp/ -m 2048 -e 131072 -c 4096 -o ubifs.img
$ ubinize -o ubi.img -m 2048 -p 128KiB -s 512 ubinize.cfg
ubinize.cfg
[ubifs]
mode=ubi
image=ubifs.img
vol_id=0
vol_size=200MiB
vol_type=dynamic
vol_name=rootfs
vol_flags=autoresize
then,
$ sudo ./fastboot flash system <rootfs_image_path>/ubi.img
in u-boot,
# setenv nandboot 'echo Booting from nand ...; nand read ${loadaddr} ${boot_nand_offset} ${boot_nand_size}; bootm ${loadaddr}'
# setenv bootcmd 'run nandboot'
# setenv bootargs 'init=/init console=ttyS0,115200n8 noinitrd ip=off androidboot.console=ttyS0 rootwait mem=256M \
omap_vout.vid1_static_vrfb_alloc=y rw ubi.mtd=4 rootfstype=ubifs root=ubi0:rootfs bootdelay=2'
but the kernel can't mount the android ubifs system.
when I boot from MMC, I find just a /dev/ubi_ctrl, but no /dev/ubi0.
I am confused, but don't know what is the problem.
Regards,
Kevin