From 89f694e0791bb464096ea1526f25c4702aa38d61915cf3e4122fe5b0217a6ddd Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Fri, 28 Jul 2023 16:39:56 +0000 Subject: [PATCH] Accepting request 1101224 from home:goldwynr:branches:Base:System Readded patch because of https://build.opensuse.org/request/show/1100707#status-history-20975903 OBS-URL: https://build.opensuse.org/request/show/1101224 OBS-URL: https://build.opensuse.org/package/show/Base:System/util-linux?expand=0&rev=523 --- ...ibblkid-try-LUKS2-first-when-probing.patch | 43 +++++++++++++++++++ util-linux.changes | 6 +++ util-linux.spec | 2 + 3 files changed, 51 insertions(+) create mode 100644 0001-Revert-libblkid-try-LUKS2-first-when-probing.patch diff --git a/0001-Revert-libblkid-try-LUKS2-first-when-probing.patch b/0001-Revert-libblkid-try-LUKS2-first-when-probing.patch new file mode 100644 index 0000000..cb36dc9 --- /dev/null +++ b/0001-Revert-libblkid-try-LUKS2-first-when-probing.patch @@ -0,0 +1,43 @@ +From 93ba7961779789217a1f814ce3110ff8c040c8c3 Mon Sep 17 00:00:00 2001 +From: Fabian Vogt +Date: Wed, 12 Jul 2023 15:48:27 +0200 +Subject: [PATCH] Revert "libblkid: try LUKS2 first when probing" + +mdadm superblocks before 1.1 are placed at the end of the device, which +means that the data contained inside the array starts at offset 0. For +LUKS inside MD, blkid falsely detects this as plain LUKS instead of a +linux_raid_member. This causes e.g. dracut to not assemble the array +during boot and system startup fails. + +This reverts commit b8889c0a214aeb3dd47bf1ab280fe5534b64d2aa. +--- + libblkid/src/superblocks/superblocks.c | 6 +----- + 1 file changed, 1 insertion(+), 5 deletions(-) + +diff --git a/libblkid/src/superblocks/superblocks.c b/libblkid/src/superblocks/superblocks.c +index fb0392707..c7789a15b 100644 +--- a/libblkid/src/superblocks/superblocks.c ++++ b/libblkid/src/superblocks/superblocks.c +@@ -94,11 +94,6 @@ static int blkid_probe_set_usage(blkid_probe pr, int usage); + */ + static const struct blkid_idinfo *idinfos[] = + { +- /* In case the volume is locked with OPAL we are going to get +- * an I/O error when reading past the LUKS header, so try it +- * first. */ +- &luks_idinfo, +- + /* RAIDs */ + &linuxraid_idinfo, + &ddfraid_idinfo, +@@ -124,6 +119,7 @@ static const struct blkid_idinfo *idinfos[] = + &snapcow_idinfo, + &verity_hash_idinfo, + &integrity_idinfo, ++ &luks_idinfo, + &vmfs_volume_idinfo, + &ubi_idinfo, + &vdo_idinfo, +-- +2.41.0 + diff --git a/util-linux.changes b/util-linux.changes index 514e96f..65371cc 100644 --- a/util-linux.changes +++ b/util-linux.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Jul 28 14:47:15 UTC 2023 - Goldwyn Rodrigues + +- Re-add 0001-Revert-libblkid-try-LUKS2-first-when-probing.patch + because the patch is not in 2.39.1 + ------------------------------------------------------------------- Wed Jul 26 01:22:20 UTC 2023 - Neil Brown diff --git a/util-linux.spec b/util-linux.spec index d8f46c5..6b2efc7 100644 --- a/util-linux.spec +++ b/util-linux.spec @@ -110,6 +110,8 @@ Patch1: libmount-print-a-blacklist-hint-for-unknown-filesyst.patch Patch2: Add-documentation-on-blacklisted-modules-to-mount-8-.patch # PATCH-FIX-SUSE util-linux-bash-completion-su-chsh-l.patch bsc1172427 -- Fix "su -s" bash completion. Patch3: util-linux-bash-completion-su-chsh-l.patch +# https://github.com/util-linux/util-linux/pull/2373 +Patch4: 0001-Revert-libblkid-try-LUKS2-first-when-probing.patch BuildRequires: audit-devel BuildRequires: bc