[PATCH] x86_64: Align data segment to PAGE_SIZE boundary
authorVivek Goyal <vgoyal@in.ibm.com>
Mon, 20 Nov 2006 16:29:09 +0000 (11:29 -0500)
committerAndi Kleen <andi@basil.nowhere.org>
Tue, 21 Nov 2006 09:26:54 +0000 (10:26 +0100)
o Explicitly align data segment to PAGE_SIZE boundary otherwise depending on
  config options and tool chain it might be placed on a non PAGE_SIZE aligned
  boundary and vmlinux loaders like kexec fail when they encounter a
  PT_LOAD type segment which is not aligned to PAGE_SIZE boundary.

Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
Signed-off-by: Andi Kleen <ak@suse.de>
arch/x86_64/kernel/vmlinux.lds.S

index edb24aa714b4e0d58f1bbebe70b1e699abb16ce7..d9534e750d4fa548e7f2a016b94fb022ee7689c0 100644 (file)
@@ -60,6 +60,7 @@ SECTIONS
   }
 #endif
 
   }
 #endif
 
+  . = ALIGN(PAGE_SIZE);        /* Align data segment to page size boundary */
                                /* Data */
   .data : AT(ADDR(.data) - LOAD_OFFSET) {
        *(.data)
                                /* Data */
   .data : AT(ADDR(.data) - LOAD_OFFSET) {
        *(.data)