[PATCH] i386: Force data segment to be 4K aligned
authorVivek Goyal <vgoyal@in.ibm.com>
Thu, 9 Nov 2006 01:44:41 +0000 (17:44 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Thu, 9 Nov 2006 02:29:23 +0000 (18:29 -0800)
o Currently there is no specific alignment restriction in linker script
  and in some cases it can be placed non 4K aligned addresses. This fails
  kexec which checks that segment to be loaded is page aligned.

o I guess, it does not harm data segment to be 4K aligned.

Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/i386/kernel/vmlinux.lds.S

index adc1f232afeeddad4e92b8ee26412440966aef4d..c6f84a0322ba30438dda746a630ef68e4ace7306 100644 (file)
@@ -51,6 +51,7 @@ SECTIONS
   __tracedata_end = .;
 
   /* writeable */
+  . = ALIGN(4096);
   .data : AT(ADDR(.data) - LOAD_OFFSET) {      /* Data */
        *(.data)
        CONSTRUCTORS