Skip to content

Latest commit

 

History

History
30 lines (20 loc) · 2.22 KB

README-data-partition.md

File metadata and controls

30 lines (20 loc) · 2.22 KB

Data partition

Sometimes it is useful (or even required) to have an additional partition to store application data and other software artifacts:

  • If the tdxref-signed class is used to enable secure boot, the rootfs partition will be read-only, and an additional partition might be needed to store persistent data.
  • If the tdx-encrypted class is used to enable encryption, an additional partition in the eMMC can be used to store the encrypted data.

For these and other use cases, this layer supports creating an additional data partition in the eMMC via the tdx-tezi-data-partition class.

Important: This class only works with Toradex Easy Installer images.

Enabling the data partition

To enable the creation of the data partition in Toradex Easy Installer images, one needs to globally inherit the tdx-tezi-data-partition class by adding the following line to an OE configuration file (e.g. your local.conf):

INHERIT += "tdx-tezi-data-partition"

Additional variables can be used to customize the behavior of this feature:

Variable Description Default value
TDX_TEZI_DATA_PARTITION_TYPE Data partition filesystem type. Supported values are ext2, ext3, ext4, fat and ubifs. The supported values are limited to what Toradex Easy Installer supports ext4
TDX_TEZI_DATA_PARTITION_LABEL Label that will be used to format and mount the data partition DATA
TDX_TEZI_DATA_PARTITION_AUTOMOUNT Set to 1 to automatically mount the data partition at boot time, or 0 to disable automouting the partition 1
TDX_TEZI_DATA_PARTITION_MOUNTPOINT Directory where the data partition should be mounted /data
TDX_TEZI_DATA_PARTITION_MOUNT_FLAGS Flags used to mount the data partition. See the mount man page for more information on the available mount flags rw,nosuid,nodev,noatime, errors=remount-ro

Additional variables from the image_type_tezi class in the meta-toradex-bsp-common layer can be used to customize the creation of the data partition. Please see the source code of this class for more information.