By default, LS1043S and Five64 boards have a 512MB NAND flash.

NAND Partition Layout

Partition # Name Size (approximate)
0 U-Boot 1M
1 U-Boot Environment 400K
2 Frame Manager Firmware 132K
3 PPA/TrustZone Firmware 262K
4 Device Tree 132K
5 ubifs Remainder of flash ~500MB

By default, the ubifs partition is divided into two sets of kernel and rootfs. Kernel partitions are 8MB by default Rootfs partitions are 134MB by default.

The creation of the ubifs partitions can be done in U-Boot:

ubi part nandubi; ubi create kernel1 0x800000; ubi create rootfs1 0x8000000; ubi create kernel2 0x800000; ubi create rootfs2 0x8000000

or under Linux:

ubimkvol /dev/ubi0 -s 8MiB -N kernel1
ubimkvol /dev/ubi0 -s 134MiB -N rootfs1

ubimkvol /dev/ubi0 -s 8MiB -N kernel2
ubimkvol /dev/ubi0 -s 134MiB -N rootfs2

default mtdparts on the kernel command line

mtdparts=7e800000.flash:1m(nand_uboot),384k(nand_uboot_env),128k(fman_fw),256k(ppa),128k(dtb),400m(nandubi)

dmesg output:

[    2.474928] Creating 6 MTD partitions on "7e800000.flash":
[    2.480412] 0x000000000000-0x000000100000 : "nand_uboot"
[    2.486229] 0x000000100000-0x000000160000 : "nand_uboot_env"
[    2.492345] 0x000000160000-0x000000180000 : "fman_fw"
[    2.497835] 0x000000180000-0x0000001c0000 : "ppa"
[    2.502978] 0x0000001c0000-0x0000001e0000 : "dtb"
[    2.508123] 0x0000001e0000-0x0000191e0000 : "nandubi"