From: Raito Bezarius Date: Fri, 29 Sep 2023 01:51:54 +0000 (+0200) Subject: secure-boot: print just before cold-resetting to help diagnose hangs X-Git-Tag: v255-rc1~99 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b9a0a13f7ad71896c8382968e492a94922b0d744;p=thirdparty%2Fsystemd.git secure-boot: print just before cold-resetting to help diagnose hangs When testing the secureboot enroll feature, it can be hard to distinguish without using the QMP API of QEMU whether we are in a hang situation of the UEFI firmware. Making it clear that we reached the `ResetSystem` can be helpful towards that need. --- diff --git a/src/boot/efi/secure-boot.c b/src/boot/efi/secure-boot.c index f6776af9178..370064fa089 100644 --- a/src/boot/efi/secure-boot.c +++ b/src/boot/efi/secure-boot.c @@ -117,6 +117,10 @@ EFI_STATUS secure_boot_enroll_at(EFI_FILE *root_dir, const char16_t *path, bool } } + if (!is_safe) + printf("\n"); + + printf("Custom Secure Boot keys successfully enrolled, rebooting the system now!"); /* The system should be in secure boot mode now and we could continue a regular boot. But at least * TPM PCR7 measurements should change on next boot. Reboot now so that any OS we load does not end * up relying on the old PCR state. */