diff options
author | Ingo Molnar <mingo@kernel.org> | 2020-05-25 09:42:41 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2020-06-11 15:15:03 +0200 |
commit | 7102cb07132624cdc09aa8e40c03ae34b4cbb74a (patch) | |
tree | 1cde6bd5ab5e3dc83ffe623a1c13eea24d9ea7a7 /arch/x86/kernel | |
parent | c29c775a554f7060b6fb31b68f88a3c9087cf1c5 (diff) |
x86/entry: Fix allnoconfig build warning
The following commit:
095b7a3e7745 ("x86/entry: Convert double fault exception to IDTENTRY_DF")
introduced a new build warning on 64-bit allnoconfig kernels, that have CONFIG_VMAP_STACK disabled:
arch/x86/kernel/traps.c:332:16: warning: unused variable ‘address’ [-Wunused-variable]
This variable is only used if CONFIG_VMAP_STACK is defined, so make it
dependent on that, not CONFIG_X86_64.
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Alexandre Chartre <alexandre.chartre@oracle.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Andy Lutomirski <luto@kernel.org>
Cc: Borislav Petkov <bp@alien8.de>
Diffstat (limited to 'arch/x86/kernel')
-rw-r--r-- | arch/x86/kernel/traps.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c index 35298c1df32f..9e5d81cb94ba 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c @@ -328,7 +328,7 @@ DEFINE_IDTENTRY_DF(exc_double_fault) static const char str[] = "double fault"; struct task_struct *tsk = current; -#ifdef CONFIG_X86_64 +#ifdef CONFIG_VMAP_STACK unsigned long address = read_cr2(); #endif |