# MX-UBIFS =# Setup environment ==================== export boardname=vmx51 export fs_direcotry=where_is_my_filesystem_direcotry export fs_ubi=my_${boardname} =# Make ubifs ============= cd fs_direcotry=${fs_direcotry} fs_ubi=${fs_ubi} \ sudo mkfs.ubifs -m 2KiB -e 124KiB -c 8160 -d ${fs_direcotry} -o ${fs_ubi}.ubifs =# Create ubi img config file ============================= cd cat << EOF_M > rootfs.cfg # Section header [rootfs] # Volume mode (other option is static) mode=ubi # Source image image=${fs_ubi}.ubifs # Volume ID in UBI image vol_id=0 # Volume size vol_size=64MiB # Allow for dynamic resize vol_type=dynamic # Volume name vol_name=rootfs # Autoresize volume at first mount vol_flags=autoresize EOF_M =# Make ubiimg ============== ubinize -o ${fs_ubi}.ubi.img -m 2KiB -p 128KiB -s 2KiB rootfs.cfg (Note) "fs_directory" represend the direcotry where the custom filesystem structure is storend in (/home/workdir/my_filesystem). (Note) *.ubi.img is the final filesystem which can be flashed to module NAND using barebox