lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-62d8b7fba8d3ba9c046b7a1a95946c6aaf7c5da9@git.kernel.org>
Date:   Tue, 20 Feb 2018 02:24:40 -0800
From:   tip-bot for Juergen Gross <tipbot@...or.com>
To:     linux-tip-commits@...r.kernel.org
Cc:     keescook@...omium.org, torvalds@...ux-foundation.org,
        tglx@...utronix.de, rafael.j.wysocki@...el.com,
        kirill.shutemov@...ux.intel.com, andy.shevchenko@...il.com,
        jgross@...e.com, linux-kernel@...r.kernel.org, bp@...en8.de,
        hpa@...or.com, ebiederm@...ssion.com, mingo@...nel.org,
        peterz@...radead.org
Subject: [tip:x86/boot] x86/acpi: Add a new x86_init_acpi structure to
 x86_init_ops

Commit-ID:  62d8b7fba8d3ba9c046b7a1a95946c6aaf7c5da9
Gitweb:     https://git.kernel.org/tip/62d8b7fba8d3ba9c046b7a1a95946c6aaf7c5da9
Author:     Juergen Gross <jgross@...e.com>
AuthorDate: Mon, 19 Feb 2018 11:09:05 +0100
Committer:  Ingo Molnar <mingo@...nel.org>
CommitDate: Tue, 20 Feb 2018 09:00:56 +0100

x86/acpi: Add a new x86_init_acpi structure to x86_init_ops

Add a new struct x86_init_acpi to x86_init_ops. For now it contains
only one init function to get the RSDP table address.

Signed-off-by: Juergen Gross <jgross@...e.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@...il.com>
Acked-by: Thomas Gleixner <tglx@...utronix.de>
Acked-by: Rafael J. Wysocki <rafael.j.wysocki@...el.com>
Cc: Borislav Petkov <bp@...en8.de>
Cc: Eric Biederman <ebiederm@...ssion.com>
Cc: H. Peter Anvin <hpa@...or.com>
Cc: Kees Cook <keescook@...omium.org>
Cc: Kirill A. Shutemov <kirill.shutemov@...ux.intel.com>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: boris.ostrovsky@...cle.com
Cc: lenb@...nel.org
Cc: linux-acpi@...r.kernel.org
Cc: xen-devel@...ts.xenproject.org
Link: http://lkml.kernel.org/r/20180219100906.14265-3-jgross@suse.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
 arch/x86/include/asm/acpi.h     | 7 +++++++
 arch/x86/include/asm/x86_init.h | 9 +++++++++
 arch/x86/kernel/x86_init.c      | 5 +++++
 3 files changed, 21 insertions(+)

diff --git a/arch/x86/include/asm/acpi.h b/arch/x86/include/asm/acpi.h
index 1188172..6609dd7 100644
--- a/arch/x86/include/asm/acpi.h
+++ b/arch/x86/include/asm/acpi.h
@@ -31,6 +31,7 @@
 #include <asm/mmu.h>
 #include <asm/mpspec.h>
 #include <asm/realmode.h>
+#include <asm/x86_init.h>
 
 #ifdef CONFIG_ACPI_APEI
 # include <asm/pgtable_types.h>
@@ -133,6 +134,12 @@ static inline bool acpi_has_cpu_in_madt(void)
 	return !!acpi_lapic;
 }
 
+#define ACPI_HAVE_ARCH_GET_ROOT_POINTER
+static inline u64 acpi_arch_get_root_pointer(void)
+{
+	return x86_init.acpi.get_root_pointer();
+}
+
 #else /* !CONFIG_ACPI */
 
 #define acpi_lapic 0
diff --git a/arch/x86/include/asm/x86_init.h b/arch/x86/include/asm/x86_init.h
index fc2f082..2e2c34d 100644
--- a/arch/x86/include/asm/x86_init.h
+++ b/arch/x86/include/asm/x86_init.h
@@ -131,6 +131,14 @@ struct x86_hyper_init {
 };
 
 /**
+ * struct x86_init_acpi - x86 ACPI init functions
+ * @get_root_pointer:		get RSDP address
+ */
+struct x86_init_acpi {
+	u64 (*get_root_pointer)(void);
+};
+
+/**
  * struct x86_init_ops - functions for platform specific setup
  *
  */
@@ -144,6 +152,7 @@ struct x86_init_ops {
 	struct x86_init_iommu		iommu;
 	struct x86_init_pci		pci;
 	struct x86_hyper_init		hyper;
+	struct x86_init_acpi		acpi;
 };
 
 /**
diff --git a/arch/x86/kernel/x86_init.c b/arch/x86/kernel/x86_init.c
index 1151ccd..9e4e994 100644
--- a/arch/x86/kernel/x86_init.c
+++ b/arch/x86/kernel/x86_init.c
@@ -30,6 +30,7 @@ int __init iommu_init_noop(void) { return 0; }
 void iommu_shutdown_noop(void) { }
 bool __init bool_x86_init_noop(void) { return false; }
 void x86_op_int_noop(int cpu) { }
+u64 u64_x86_init_noop(void) { return 0; }
 
 /*
  * The platform setup functions are preset with the default functions
@@ -91,6 +92,10 @@ struct x86_init_ops x86_init __initdata = {
 		.x2apic_available	= bool_x86_init_noop,
 		.init_mem_mapping	= x86_init_noop,
 	},
+
+	.acpi = {
+		.get_root_pointer	= u64_x86_init_noop,
+	},
 };
 
 struct x86_cpuinit_ops x86_cpuinit = {

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ