Fix build break without CONFIG_EFI set (reported by Peter W. Bowey)

This commit is contained in:
Josh Boyer 2012-11-05 09:51:22 -05:00
parent fd50c1cf70
commit 7002a8cc0b
2 changed files with 19 additions and 16 deletions

View File

@ -62,7 +62,7 @@ Summary: The Linux kernel
# For non-released -rc kernels, this will be appended after the rcX and
# gitX tags, so a 3 here would become part of release "0.rcX.gitX.3"
#
%global baserelease 1
%global baserelease 2
%global fedora_build %{baserelease}
# base_sublevel is the kernel version we're starting with and patching
@ -687,7 +687,7 @@ Patch900: modsign-upstream-3.7.patch
Patch901: modsign-post-KS-jwb.patch
# secure boot
Patch1000: secure-boot-20121026.patch
Patch1000: secure-boot-20121105.patch
# Improve PCI support on UEFI
Patch1100: handle-efi-roms.patch
@ -1444,7 +1444,7 @@ ApplyPatch modsign-upstream-3.7.patch
ApplyPatch modsign-post-KS-jwb.patch
# secure boot
ApplyPatch secure-boot-20121026.patch
ApplyPatch secure-boot-20121105.patch
# Improved PCI support for UEFI
ApplyPatch handle-efi-roms.patch
@ -2378,7 +2378,8 @@ fi
# ||----w |
# || ||
%changelog
* Mon Nov 05 2012 Josh Boyer <jwboyer@redhat.com> - 3.6.6-1
* Mon Nov 05 2012 Josh Boyer <jwboyer@redhat.com> - 3.6.6-2
- Fix build break without CONFIG_EFI set (reported by Peter W. Bowey)
- Linux v3.6.6
* Mon Nov 05 2012 David Woodhouse <David.Woodhouse@intel.com> - 3.6.5-3

View File

@ -940,11 +940,12 @@ index 836c797..9cc3250 100644
--
1.7.12.1
From 84d11d541cc039e8561d06deab5f9b700f12f246 Mon Sep 17 00:00:00 2001
From a06f449cee6152ce8f0a051593fceb82d26e4f16 Mon Sep 17 00:00:00 2001
From: Josh Boyer <jwboyer@redhat.com>
Date: Fri, 26 Oct 2012 12:29:49 -0400
Subject: [PATCH 1/3] EFI: Add in-kernel variable to determine if Secure Boot
is enabled
Subject: [PATCH] EFI: Add in-kernel variable to determine if Secure Boot is
enabled
There are a few cases where in-kernel functions may need to know if
Secure Boot is enabled. The added capability check cannot be used as the
@ -953,32 +954,34 @@ similar to efi_enabled so they can determine if Secure Boot is enabled.
Signed-off-by: Josh Boyer <jwboyer@redhat.com>
---
arch/x86/kernel/setup.c | 4 +++-
arch/x86/kernel/setup.c | 6 +++++-
arch/x86/platform/efi/efi.c | 2 ++
include/linux/efi.h | 3 +++
3 files changed, 8 insertions(+), 1 deletion(-)
3 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index 51f6970..d5b9548 100644
index b4f4666..db74940 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -961,8 +961,10 @@ void __init setup_arch(char **cmdline_p)
@@ -961,8 +961,12 @@ void __init setup_arch(char **cmdline_p)
io_delay_init();
- if (boot_params.secure_boot)
+ if (boot_params.secure_boot) {
secureboot_enable();
+#ifdef CONFIG_EFI
+ secure_boot_enabled = 1;
+#endif
+ }
/*
* Parse the ACPI tables for possible boot-time SMP configuration.
diff --git a/arch/x86/platform/efi/efi.c b/arch/x86/platform/efi/efi.c
index aded2a9..e57320b 100644
index 72d8899..882d794 100644
--- a/arch/x86/platform/efi/efi.c
+++ b/arch/x86/platform/efi/efi.c
@@ -54,6 +54,8 @@
@@ -53,6 +53,8 @@
int efi_enabled;
EXPORT_SYMBOL(efi_enabled);
@ -988,10 +991,10 @@ index aded2a9..e57320b 100644
.mps = EFI_INVALID_TABLE_ADDR,
.acpi = EFI_INVALID_TABLE_ADDR,
diff --git a/include/linux/efi.h b/include/linux/efi.h
index 9cc3250..ff72468 100644
index 54b5936..411997f 100644
--- a/include/linux/efi.h
+++ b/include/linux/efi.h
@@ -573,11 +573,14 @@ extern int __init efi_setup_pcdp_console(char *);
@@ -575,11 +575,14 @@ extern int __init efi_setup_pcdp_console(char *);
# ifdef CONFIG_X86
extern int efi_enabled;
extern bool efi_64bit;
@ -1009,7 +1012,6 @@ index 9cc3250..ff72468 100644
--
1.7.12.1
From 2a5f33b264daffd717b509bc5ac3cdc060b5573e Mon Sep 17 00:00:00 2001
From: Josh Boyer <jwboyer@redhat.com>
Date: Fri, 26 Oct 2012 12:36:24 -0400