From c1e143a6278d712df2d85cff4d1424a2df3c59ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Esteban=20Ag=C3=BCero=20P=C3=A9rez?= Date: Wed, 23 Oct 2024 17:01:36 -0600 Subject: [PATCH] feat: Added ext3 filesystem support MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Extend the supported fs with ext3 for legacy boards Changelog: Title Ticket: None Signed-off-by: Esteban Agüero Pérez --- mender-convert-package | 2 ++ modules/disk.sh | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/mender-convert-package b/mender-convert-package index 44abdf4738..363d779617 100755 --- a/mender-convert-package +++ b/mender-convert-package @@ -201,6 +201,8 @@ log_info "Rootfs filesystem size will be $(disk_sectors_to_mb ${rootfs_image_sec # Extract file-system type from rootfs if file ${root_part} | grep -q ext4; then image_fs_type="ext4" +elif file ${root_part} | grep -q ext3; then + image_fs_type="ext3" elif file ${root_part} | grep -q XFS; then image_fs_type="xfs" elif file ${root_part} | grep -q BTRFS; then diff --git a/modules/disk.sh b/modules/disk.sh index 88480346c6..b06f72ee15 100644 --- a/modules/disk.sh +++ b/modules/disk.sh @@ -127,6 +127,14 @@ disk_create_file_system_from_folder() { run_and_log_cmd "${MKFS_EXT4} -q -F ${2} ${EXTRA_OPTS}" ;; + "ext3") + MKFS_EXT3="/usr/bin/mkfs.ext3" + if [ ! -f ${MKFS_EXT3} ]; then + MKFS_EXT3="/sbin/mkfs.ext3" + fi + run_and_log_cmd "${MKFS_EXT3} -q -F ${2} ${EXTRA_OPTS}" + ;; + "xfs") MKFS_XFS="/usr/bin/mkfs.xfs" if [ ! -f ${MKFS_XFS} ]; then