summaryrefslogtreecommitdiffstats
path: root/0001-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch
diff options
context:
space:
mode:
Diffstat (limited to '0001-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch')
-rw-r--r--0001-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch30
1 files changed, 15 insertions, 15 deletions
diff --git a/0001-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch b/0001-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch
index 8f9949335..43353a7b7 100644
--- a/0001-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch
+++ b/0001-efi-Add-an-EFI_SECURE_BOOT-flag-to-indicate-secure-b.patch
@@ -32,7 +32,7 @@ index a1b8cb9a2579..28d43754aeb6 100644
@@ -1256,19 +1256,7 @@ void __init setup_arch(char **cmdline_p)
/* Allocate bigger log buffer */
setup_log_buf(1);
-
+
- if (efi_enabled(EFI_BOOT)) {
- switch (boot_params.secure_boot) {
- case efi_secureboot_mode_disabled:
@@ -47,9 +47,9 @@ index a1b8cb9a2579..28d43754aeb6 100644
- }
- }
+ efi_set_secure_boot(boot_params.secure_boot);
-
+
reserve_initrd();
-
+
diff --git a/drivers/firmware/efi/Makefile b/drivers/firmware/efi/Makefile
index 7a216984552b..f0ef02d733af 100644
--- a/drivers/firmware/efi/Makefile
@@ -107,10 +107,10 @@ index 000000000000..de0a3714a5d4
+ }
+}
diff --git a/include/linux/efi.h b/include/linux/efi.h
-index b73b4bcaa32f..bde09740a9b5 100644
+index 1d77c218b67e..f5fe3e01bc0e 100644
--- a/include/linux/efi.h
+++ b/include/linux/efi.h
-@@ -780,6 +780,14 @@ extern int __init efi_setup_pcdp_console(char *);
+@@ -781,6 +781,14 @@ extern int __init efi_setup_pcdp_console(char *);
#define EFI_MEM_ATTR 10 /* Did firmware publish an EFI_MEMORY_ATTRIBUTES table? */
#define EFI_MEM_NO_SOFT_RESERVE 11 /* Is the kernel configured to ignore soft reservations? */
#define EFI_PRESERVE_BS_REGIONS 12 /* Are EFI boot-services memory segments available? */
@@ -122,31 +122,31 @@ index b73b4bcaa32f..bde09740a9b5 100644
+ efi_secureboot_mode_disabled,
+ efi_secureboot_mode_enabled,
+};
-
+
#ifdef CONFIG_EFI
/*
-@@ -791,6 +799,8 @@ static inline bool efi_enabled(int feature)
+@@ -792,6 +800,8 @@ static inline bool efi_enabled(int feature)
}
extern void efi_reboot(enum reboot_mode reboot_mode, const char *__unused);
-
+
+extern void __init efi_set_secure_boot(enum efi_secureboot_mode mode);
+
bool __pure __efi_soft_reserve_enabled(void);
-
+
static inline bool __pure efi_soft_reserve_enabled(void)
-@@ -817,6 +827,8 @@ efi_capsule_pending(int *reset_type)
+@@ -818,6 +828,8 @@ efi_capsule_pending(int *reset_type)
return false;
}
-
+
+static inline void efi_set_secure_boot(enum efi_secureboot_mode mode) {}
+
static inline bool efi_soft_reserve_enabled(void)
{
return false;
-@@ -1088,12 +1100,6 @@ static inline bool efi_runtime_disabled(void) { return true; }
+@@ -1089,12 +1101,6 @@ static inline bool efi_runtime_disabled(void) { return true; }
extern void efi_call_virt_check_flags(unsigned long flags, const char *call);
extern unsigned long efi_call_virt_save_flags(void);
-
+
-enum efi_secureboot_mode {
- efi_secureboot_mode_unset,
- efi_secureboot_mode_unknown,
@@ -154,8 +154,8 @@ index b73b4bcaa32f..bde09740a9b5 100644
- efi_secureboot_mode_enabled,
-};
enum efi_secureboot_mode efi_get_secureboot(void);
-
+
#ifdef CONFIG_RESET_ATTACK_MITIGATION
--
-2.26.2
+2.25.4