From d128ded2d16f9163d225397a28132fabdd960fc2 Mon Sep 17 00:00:00 2001 From: Hongxu Jia Date: Mon, 20 Jul 2020 19:16:01 -0700 Subject: e2fsprogs: fix up check for hardlinks always false if inode > 0xFFFFFFFF While file has a large inode number (> 0xFFFFFFFF), mkfs.ext4 could not parse hardlink correctly. Prepare three hardlink files for mkfs.ext4 $ ls -il rootfs_ota/a rootfs_ota/boot/b rootfs_ota/boot/c 11026675846 -rw-r--r-- 3 hjia users 0 Jul 20 17:44 rootfs_ota/a 11026675846 -rw-r--r-- 3 hjia users 0 Jul 20 17:44 rootfs_ota/boot/b 11026675846 -rw-r--r-- 3 hjia users 0 Jul 20 17:44 rootfs_ota/boot/c $ truncate -s 1M rootfs_ota.ext4 $ mkfs.ext4 -F -i 8192 rootfs_ota.ext4 -L otaroot -U fd5f8768-c779-4dc9-adde-165a3d863349 -d rootfs_ota $ mkdir mnt && sudo mount rootfs_ota.ext4 mnt $ ls -il mnt/rootfs_ota/a mnt/rootfs_ota/boot/b 12 -rw-r--r-- 1 hjia users 0 Jul 20 17:44 mnt/a 14 -rw-r--r-- 1 hjia users 0 Jul 20 17:44 mnt/boot/b 15 -rw-r--r-- 1 hjia users 0 Jul 20 17:44 mnt/boot/c After applying this fix $ ls -il mnt/rootfs_ota/a mnt/rootfs_ota/boot/b 12 -rw-r--r-- 3 hjia users 0 Jul 20 17:44 mnt/a 12 -rw-r--r-- 3 hjia users 0 Jul 20 17:44 mnt/boot/b 12 -rw-r--r-- 3 hjia users 0 Jul 20 17:44 mnt/boot/c (From OE-Core rev: 3b2c7350a7f3fb20f2b61ddb41f81959a54bc873) Signed-off-by: Hongxu Jia Signed-off-by: Richard Purdie --- meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.6.bb | 1 + 1 file changed, 1 insertion(+) (limited to 'meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.6.bb') diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.6.bb b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.6.bb index 4ad5b03cac..15054768dd 100644 --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.6.bb +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.45.6.bb @@ -6,6 +6,7 @@ SRC_URI += "file://remove.ldconfig.call.patch \ file://mkdir_p.patch \ file://0001-configure.ac-correct-AM_GNU_GETTEXT.patch \ file://0001-intl-do-not-try-to-use-gettext-defines-that-no-longe.patch \ + file://0001-fix-up-check-for-hardlinks-always-false-if-inode-0xF.patch \ " SRC_URI_append_class-native = " file://e2fsprogs-fix-missing-check-for-permission-denied.patch \ -- cgit v1.2.3-54-g00ecf