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-next>] [day] [month] [year] [list]
Date:   Mon, 18 Dec 2017 14:43:50 +0100
From:   Arnd Bergmann <arnd@...db.de>
To:     Thomas Gleixner <tglx@...utronix.de>
Cc:     Arnd Bergmann <arnd@...db.de>, Ingo Molnar <mingo@...hat.com>,
        "H. Peter Anvin" <hpa@...or.com>, x86@...nel.org,
        Andy Lutomirski <luto@...nel.org>,
        Borislav Petkov <bp@...e.de>,
        Peter Zijlstra <peterz@...radead.org>,
        Thomas Garnier <thgarnie@...gle.com>,
        Ricardo Neri <ricardo.neri-calderon@...ux.intel.com>,
        linux-kernel@...r.kernel.org
Subject: [PATCH] x86: hide unused allocate_percpu_fixmap_ptes

The new function is not always used, causing a warning whenever
CONFIG_CPU_SUP_INTEL is disabled:

arch/x86/kernel/cpu/common.c:522:20: error: 'allocate_percpu_fixmap_ptes' defined but not used [-Werror=unused-function]

Hide it in the same #ifdef.

Fixes: 3015f86f838c ("x86/fixmap: Add debugstore entries to cpu_entry_area")
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
 arch/x86/kernel/cpu/common.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
index 6444f91e8d3c..6f354416a67f 100644
--- a/arch/x86/kernel/cpu/common.c
+++ b/arch/x86/kernel/cpu/common.c
@@ -519,11 +519,13 @@ static DEFINE_PER_CPU_PAGE_ALIGNED(struct entry_stack_page,
  * Force the population of PMDs for not yet allocated per cpu
  * memory like debug store buffers.
  */
+#ifdef CONFIG_CPU_SUP_INTEL
 static void __init allocate_percpu_fixmap_ptes(int idx, int pages)
 {
 	for (; pages; pages--, idx--)
 		__set_fixmap(idx, 0, PAGE_NONE);
 }
+#endif
 
 static void __init
 set_percpu_fixmap_pages(int idx, void *ptr, int pages, pgprot_t prot)
-- 
2.9.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ