From c5f457c08d1f35073dd35eef360017c38ca9c559e158ac76ec5199f59766c5dc Mon Sep 17 00:00:00 2001 From: Joey Lee Date: Fri, 22 Sep 2023 08:46:59 +0000 Subject: [PATCH] Accepting request 1112452 from home:gary_lin:branches:devel:openSUSE:Factory - Update shim-install to fix boot failure of ext4 root file system on RAID10 (bsc#1205855) 226c94ca5cfca Use hint in looking for root if possible - Adopt the macros from fde-tpm-helper-macros to update the signature in the sealed key after a bootloader upgrade The macros package depends on the latest fde-tools: https://build.opensuse.org/request/show/1112138 OBS-URL: https://build.opensuse.org/request/show/1112452 OBS-URL: https://build.opensuse.org/package/show/devel:openSUSE:Factory/shim?expand=0&rev=203 --- shim-install | 13 ++++++++++++- shim.changes | 13 +++++++++++++ shim.spec | 9 +++++++++ 3 files changed, 34 insertions(+), 1 deletion(-) diff --git a/shim-install b/shim-install index 0d44d3d..fb56bf2 100644 --- a/shim-install +++ b/shim-install @@ -419,8 +419,19 @@ if [ x$GRUB_ENABLE_CRYPTODISK = xy ]; then done fi +hints="`"${grub_probe}" --target=hints_string "${grub_cfg_dirname}" 2> /dev/null`" + +if [ "x$hints" != x ]; then + echo "if [ x\$feature_platform_search_hint = xy ]; then" + echo " search --no-floppy --fs-uuid --set=root ${hints} ${cfg_fs_uuid}" + echo "else" + echo " search --no-floppy --fs-uuid --set=root ${cfg_fs_uuid}" + echo "fi" +else + echo "search --no-floppy --fs-uuid --set=root ${cfg_fs_uuid}" +fi + cat < + +- Update shim-install to fix boot failure of ext4 root file system + on RAID10 (bsc#1205855) + 226c94ca5cfca Use hint in looking for root if possible + +------------------------------------------------------------------- +Tue Sep 19 08:36:17 UTC 2023 - Gary Ching-Pang Lin + +- Adopt the macros from fde-tpm-helper-macros to update the + signature in the sealed key after a bootloader upgrade + ------------------------------------------------------------------- Mon May 15 03:28:47 UTC 2023 - Gary Ching-Pang Lin diff --git a/shim.spec b/shim.spec index bc8ed64..e395bee 100644 --- a/shim.spec +++ b/shim.spec @@ -83,6 +83,7 @@ BuildRequires: openssl >= 0.9.8 BuildRequires: pesign BuildRequires: pesign-obs-integration %if 0%{?suse_version} > 1320 +BuildRequires: fde-tpm-helper-rpm-macros BuildRequires: update-bootloader-rpm-macros %endif %if 0%{?update_bootloader_requires:1} @@ -90,6 +91,9 @@ BuildRequires: update-bootloader-rpm-macros %else Requires: perl-Bootloader %endif +%if 0%{?fde_tpm_update_requires:1} +%fde_tpm_update_requires +%endif BuildRoot: %{_tmppath}/%{name}-%{version}-build # For shim-install script Requires: grub2-%{grubplatform} @@ -286,6 +290,10 @@ cp -r source/* %{buildroot}/usr/src/debug/%{name}-%{version} %{?buildroot:%__rm -rf "%{buildroot}"} %post +%if 0%{?fde_tpm_update_post:1} +%fde_tpm_update_post shim +%endif + %if 0%{?update_bootloader_check_type_reinit_post:1} %update_bootloader_check_type_reinit_post grub2-efi %else @@ -316,6 +324,7 @@ fi %if %{defined update_bootloader_posttrans} %posttrans %{?update_bootloader_posttrans} +%{?fde_tpm_update_posttrans} %endif %files