]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
x86-32, amd: Move va_align definition to unbreak 32-bit build
authorBorislav Petkov <borislav.petkov@amd.com>
Sat, 6 Aug 2011 12:31:38 +0000 (14:31 +0200)
committerH. Peter Anvin <hpa@zytor.com>
Sat, 6 Aug 2011 18:44:57 +0000 (11:44 -0700)
hpa reported that dfb09f9b7ab03fd367740e541a5caf830ed56726 breaks 32-bit
builds with the following error message:

/home/hpa/kernel/linux-tip.cpu/arch/x86/kernel/cpu/amd.c:437: undefined
reference to `va_align'
/home/hpa/kernel/linux-tip.cpu/arch/x86/kernel/cpu/amd.c:436: undefined
reference to `va_align'

This is due to the fact that va_align is a global in a 64-bit only
compilation unit. Move it to mmap.c where it is visible to both
subarches.

Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Link: http://lkml.kernel.org/r/1312633899-1131-1-git-send-email-bp@amd64.org
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
arch/x86/kernel/sys_x86_64.c
arch/x86/mm/mmap.c

index aaa8d09c7195294477ad501a1ccc94a6e1c7feb2..fe7d2dac7fa3e250bc0b01ac2c8d7c5007bd89f6 100644 (file)
 #include <asm/ia32.h>
 #include <asm/syscalls.h>
 
-struct __read_mostly va_alignment va_align = {
-       .flags = -1,
-};
-
 /*
  * Align a virtual address to avoid aliasing in the I$ on AMD F15h.
  *
index d4c073630175f5967d527be3aec286b0f52e52fa..4b5ba85eb5c95ebb705f8ce420acbff85c052f47 100644 (file)
 #include <linux/sched.h>
 #include <asm/elf.h>
 
+struct __read_mostly va_alignment va_align = {
+       .flags = -1,
+};
+
 static unsigned int stack_maxrandom_size(void)
 {
        unsigned int max = 0;
@@ -42,7 +46,6 @@ static unsigned int stack_maxrandom_size(void)
        return max;
 }
 
-
 /*
  * Top of mmap area (just below the process stack).
  *