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]
Message-Id: <1483025343-28932-1-git-send-email-augustocaringi@gmail.com>
Date:   Thu, 29 Dec 2016 15:28:49 +0000
From:   Augusto Mecking Caringi <augustocaringi@...il.com>
To:     Tony Luck <tony.luck@...el.com>
Cc:     Augusto Mecking Caringi <augustocaringi@...il.com>,
        Borislav Petkov <bp@...en8.de>,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>,
        "H. Peter Anvin" <hpa@...or.com>, x86@...nel.org,
        linux-edac@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH] x86: mce: Fix build warning when !CONFIG_X86_LOCAL_APIC

The mce_irq_ipi() function is only called inside a #ifdef
CONFIG_X86_LOCAL_APIC block, if this option is disabled gcc gives the
following build warning:

arch/x86/kernel/cpu/mcheck/mce-inject.c:97:13: warning: ‘mce_irq_ipi’
defined but not used [-Wunused-function]
static void mce_irq_ipi(void *info)
             ^

Fix it marking this function as __maybe_unused.

Signed-off-by: Augusto Mecking Caringi <augustocaringi@...il.com>
---
 arch/x86/kernel/cpu/mcheck/mce-inject.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/cpu/mcheck/mce-inject.c b/arch/x86/kernel/cpu/mcheck/mce-inject.c
index 517619e..cd1fb58 100644
--- a/arch/x86/kernel/cpu/mcheck/mce-inject.c
+++ b/arch/x86/kernel/cpu/mcheck/mce-inject.c
@@ -94,7 +94,7 @@ static int mce_raise_notify(unsigned int cmd, struct pt_regs *regs)
 	return NMI_HANDLED;
 }
 
-static void mce_irq_ipi(void *info)
+static void __maybe_unused mce_irq_ipi(void *info)
 {
 	int cpu = smp_processor_id();
 	struct mce *m = this_cpu_ptr(&injectm);
-- 
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ