Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1570820

[PATCH 7/7] efi: Print the secure boot status in x86 setup_arch() [ver #7]

From David Howells <dhowells@redhat.com>
Newsgroups linux.kernel
Subject [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch() [ver #7]
Date 2017-01-31 16:20 +0100
Message-ID <t5InT-2gX-13@gated-at.bofh.it> (permalink)
References <t5InT-2gX-3@gated-at.bofh.it>
Organization Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903

Show all headers | View raw


Print the secure boot status in the x86 setup_arch() but otherwise do
nothing more for now.  More functionality will be added later, but this at
least allows for testing.

Signed-off-by: David Howells <dhowells@redhat.com>
---

 arch/x86/kernel/setup.c |   14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index 4cfba947d774..22e4b47a5c14 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -1176,6 +1176,20 @@ void __init setup_arch(char **cmdline_p)
 	/* Allocate bigger log buffer */
 	setup_log_buf(1);
 
+	if (IS_ENABLED(CONFIG_EFI)) {
+		switch (boot_params.secure_boot) {
+		case efi_secureboot_mode_disabled:
+			pr_info("Secure boot disabled\n");
+			break;
+		case efi_secureboot_mode_enabled:
+			pr_info("Secure boot enabled\n");
+			break;
+		default:
+			pr_info("Secure boot could not be determined\n");
+			break;
+		}
+	}
+
 	reserve_initrd();
 
 	acpi_table_upgrade();

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[PATCH 7/7] efi: Print the secure boot status in x86 setup_arch()  [ver #7] David Howells <dhowells@redhat.com> - 2017-01-31 16:20 +0100
  Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch()  [ver #7] Ard Biesheuvel <ard.biesheuvel@linaro.org> - 2017-02-03 17:10 +0100
    Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch() [ver #7] David Howells <dhowells@redhat.com> - 2017-02-03 17:30 +0100
      Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch()  [ver #7] Ard Biesheuvel <ard.biesheuvel@linaro.org> - 2017-02-03 17:30 +0100
        Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch()  [ver #7] Ard Biesheuvel <ard.biesheuvel@linaro.org> - 2017-02-03 18:10 +0100
          Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch() [ver #7] David Howells <dhowells@redhat.com> - 2017-02-03 18:20 +0100
    Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch()  [ver #7] Ard Biesheuvel <ard.biesheuvel@linaro.org> - 2017-02-03 17:30 +0100
      Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch() [ver #7] David Howells <dhowells@redhat.com> - 2017-02-03 17:30 +0100
    Re: [PATCH 7/7] efi: Print the secure boot status in x86 setup_arch() [ver #7] David Howells <dhowells@redhat.com> - 2017-02-03 17:30 +0100

csiph-web