The ConnectCore MP13 uses a NAND flash as main storage media.
The flash is divided into logical partitions per the U-Boot variable mtdparts, which contains a string in the format described by the Linux kernel parameters in drivers/mtd/parsers/cmdlinepart.c.
Partition table
The default NAND partition table on the ConnectCore MP13 establishes the following partitions:

-
fsbl1, fsbl2: FSBL stands for First Stage Bootloader. These partitions contain (in duplicate) the Trusted Firmware-A (TF-A), which is the first piece of firmware that runs after the ROM loader. Its primary purpose is to perform any additional initialization required to load and authenticate all third-level firmware images into their executable RAM locations.
Partitions are redundant. If the ROM loader cannot boot from fsbl1, it will fall back to boot from fsbl2.
-
metadata1, metadata2: These partitions are currently not used.
-
fip-a, fip-b: FIP stands for Firmware Image Package. These partitions contain a FIP image that contains the Trusted Execution Environment (TEE) firmware and the U-Boot bootloader.
Partitions are redundant. If the TF-A cannot boot from fip-a, it will fall back to boot from fip-b.
-
UBI: This is a relatively small partition that contains UBI volumes for the U-Boot environment and the Linux kernel and device trees.
-
UBI_2: This partition extends to all the remaining space and contains UBI volumes for the Linux rootfs.
| U-Boot requires less time to attach UBI to a small partition than to a large one, so the main area of the NAND is comprised of two partitions. This results in a faster boot time than if only one partition occupies the whole NAND. |
| If you are transitioning from previous firmware where the partition table only had one UBI partition (dey-4.0-r3 or older), refer to Migrate to the new partition table for instructions on how to re-format the NAND to the new partition table. |
Dual boot UBI volumes (default)
The ConnectCore MP13 enables Dual boot by default. On a dual boot-enabled system the UBI and UBI_2 partitions contain the following UBI volumes:

-
UBI partition
-
uboot_config, uboot_config_r: (UBI volumes) Contain the U-Boot environment and its redundant copy.
-
linux_a: (UBI volume) Contains the Linux kernel, device tree files, and U-Boot boot scripts. U-Boot reads the operating system files from this default volume.
-
linux_b: (UBI volume) Same as linux_a (for system B).
-
-
UBI_2 partition
-
rootfs_a: (UBI volume) Linux root file system volume (for system A)
-
rootfs_b: (UBI volume) Linux root file system volume (for system B)
-
data: Placeholder volume for user data.
-
Single system UBI volumes
When the NAND capacity doesn’t allow for a dual boot UBI volumes layout, you can alternatively define a single system UBI volumes layout:

-
UBI partition
-
uboot_config, uboot_config_r: (UBI volumes) Contain the U-Boot environment and its redundant copy.
-
linux: (UBI volume) Contains the Linux kernel, device tree files, and U-Boot boot scripts. U-Boot reads the operating system files from this default volume.
-
recovery: (UBI volume) Contains a Linux kernel, device tree files, U-Boot boot scripts, and a recovery ramdisk image that can be launched (instead of the default operating system) to perform firmware updates on the device.
-
-
UBI_2 partition
-
rootfs: (UBI volume) Contains the Linux root file system.
-
update: (UBI volume) Placeholder volume to store firmware update files prior to launching a firmware update process on the device.
-
data: Placeholder volume for user data.
-
Change NAND layout
From dual boot to single system
To prepare your NAND for single system UBI volumes, run the following in U-Boot:
=> setenv dualboot no
=> run ubivolscript
=> saveenv
From single system to dual boot
To prepare your NAND for dual boot UBI volumes, run the following in U-Boot:
=> setenv dualboot yes
=> run ubivolscript
=> saveenv
Migrate to the new partition table
If your SOM has a U-Boot v2021.10-r3 or older, your NAND partition table only has one UBI partition with UBI volumes for all system partitions. Starting from dey-4.0-r4 and U-Boot v2021.10-r4, the partition table has been reworked to contain two partitions (UBI and UBI_2), as explained in Partition table.
The following instructions show how to re-format the NAND to the new partition table layout. If your system already has these two partitions, you can skip this procedure.
| The following procedure will destroy existing data in the NAND. |
-
Update the fip-a/fip-b partitions with the latest available FIP image (or one built by you based on dey-4.0-r4 or newer).
-
Restart the device to boot with the new U-Boot. U-Boot complains that it cannot attach the UBI partition to read the environment.
-
Run
env default -ato set the new U-Boot default environment. -
Run
mtdpartsto verify the new partition table contains both UBI and UBI_2 partitions:=> mtdparts device nand0 <nand0>, # parts = 8 #: name size offset mask_flags 0: fsbl1 0x00080000 0x00000000 0 1: fsbl2 0x00080000 0x00080000 0 2: metadata1 0x00080000 0x00100000 0 3: metadata2 0x00080000 0x00180000 0 4: fip-a 0x00300000 0x00200000 0 5: fip-b 0x00300000 0x00500000 0 6: UBI 0x01900000 0x00800000 0 7: UBI_2 0x0df00000 0x02100000 0 active partition: nand0,0 - (fsbl1) 0x00080000 @ 0x00000000 defaults: mtdids : nand0=nand0 mtdparts: mtdparts=nand0:512k(fsbl1),512k(fsbl2),512k(metadata1),512k(metadata2),3m(fip-a),3m(fip-b),25m(UBI),-(UBI_2) -
Run the
ubivolscriptscript to erase the system partitions and re-generate the UBI volumes:=> run ubivolscript -
The new partition table and UBI volumes are ready. Use the
updatecommand to program the firmware images into the linux and rootfs UBI volumes as usual,