diff --git a/board/myna-player-odyssey/rootfs_overlay/etc/fstab b/board/myna-player-odyssey/rootfs_overlay/etc/fstab index 97c2706..e69de29 100644 --- a/board/myna-player-odyssey/rootfs_overlay/etc/fstab +++ b/board/myna-player-odyssey/rootfs_overlay/etc/fstab @@ -1 +0,0 @@ -PARTLABEL=Rauc /rauc ext4 rw,relatime,data=journal,noauto,x-systemd.automount diff --git a/board/myna-player-odyssey/rootfs_overlay/etc/systemd/system/rauc-mark-good.service b/board/myna-player-odyssey/rootfs_overlay/etc/systemd/system/rauc-mark-good.service index 48d3db5..767988b 100644 --- a/board/myna-player-odyssey/rootfs_overlay/etc/systemd/system/rauc-mark-good.service +++ b/board/myna-player-odyssey/rootfs_overlay/etc/systemd/system/rauc-mark-good.service @@ -7,6 +7,7 @@ [Service] Type=oneshot +ExecStartPre=/usr/bin/mkdir -p /rauc ExecStart=/usr/bin/rauc status mark-good [Install] diff --git a/board/myna-player-odyssey/rootfs_overlay/usr/sbin/pre-init b/board/myna-player-odyssey/rootfs_overlay/usr/sbin/pre-init index 1c7fb61..56db8d9 100755 --- a/board/myna-player-odyssey/rootfs_overlay/usr/sbin/pre-init +++ b/board/myna-player-odyssey/rootfs_overlay/usr/sbin/pre-init @@ -19,13 +19,13 @@ mount -t tmpfs none /run # Step 2: Mount and initialize the data partition at /run/data -# For OverlayFS we need a partition (/dev/mmcblk2p6 in our case) and two +# For OverlayFS we need a partition (/dev/mmcblk2p5 in our case) and two # directories: overlay_root (contains the changes to the read-only root filesystem) # as well as overlay_work which is used as a temporary store when writing files # So mount and create these directories. mkdir /run/data -mount /dev/mmcblk2p6 /run/data +mount /dev/mmcblk2p5 /run/data for i in overlay_root overlay_work; do mkdir -p /run/data/$i; done diff --git a/board/myna-player-odyssey/scripts/rootfs_postimage.sh b/board/myna-player-odyssey/scripts/rootfs_postimage.sh index 67a85e0..59e9a07 100755 --- a/board/myna-player-odyssey/scripts/rootfs_postimage.sh +++ b/board/myna-player-odyssey/scripts/rootfs_postimage.sh @@ -2,11 +2,6 @@ set -e -# create filesystem for rauc slot status - -fallocate -l 2m "${BINARIES_DIR}/rauc.ext4" -mkfs.ext4 -F "${BINARIES_DIR}/rauc.ext4" - # prepare for genimage cd "${BINARIES_DIR}" export GENIMAGE_TMP=${BR2_EXTERNAL_MynaPlayer_PATH}/board/myna-player-odyssey/utilities/genimage.tmp diff --git a/board/myna-player-odyssey/utilities/genimage.tmp b/board/myna-player-odyssey/utilities/genimage.tmp index 4c883dc..bdd888a 100644 --- a/board/myna-player-odyssey/utilities/genimage.tmp +++ b/board/myna-player-odyssey/utilities/genimage.tmp @@ -1,3 +1,12 @@ +image overlayfs.ext4 { + ext4 { + use-mke2fs = "true" + label = "overlayfs" + } + empty = "true" + size = 2G +} + image MynaPlayer.img { name = "MynaPlayer-${GENIMAGE_BUILD_ID}" hdimage { @@ -17,23 +26,19 @@ } partition ssbl { - partition-type = 0x83 image = "barebox.bin" } partition PrimaryRootfs { - partition-type = 0x83 image = "rootfs.ext4" } partition SecondaryRootfs { - partition-type = 0x83 image = "rootfs.ext4" } - partition Rauc { - partition-type = 0x83 - image = "rauc.ext4" + partition overlayfs { + image = "overlayfs.ext4" } }