sparc: use .data.init_task section for init_thread_union
PATCH 1/1 sparc: use .data.init_task section for init_thread_union
Use a dedicated aligned section for the init_thread_union variable and declare this section in vmlinux.lds.
This align sparc with most other architectures.
Eventually this allow the init_task bits to be unified across all architectures.
---
Build tested on sparc32 and sparc64 - no boot test!
Sam
arch/sparc/kernel/init_task.c | 3 +-- arch/sparc/kernel/vmlinux.lds.S | 9 +++++++++ 2 files changed, 10 insertions(+), 2 deletions(-)
arch/sparc/kernel/init_task.c +1 -2
@@ -23,6 +23,5 @@ EXPORT_SYMBOL(init_task);* in etrap.S which assumes it. */ union thread_union init_thread_union - __attribute__((section (".text\"\n\t#"))) - __attribute__((aligned (THREAD_SIZE))) + __attribute__((section (".data.init_task"))) = { INIT_THREAD_INFO(init_task) };
arch/sparc/kernel/vmlinux.lds.S +9 -0
@@ -1,7 +1,9 @@ /* ld script for sparc32/sparc64 kernel */ #include <asm-generic/vmlinux.lds.h> + #include <asm/page.h> +#include <asm/thread_info.h> #ifdef CONFIG_SPARC32 #define INITIAL_ADDRESS 0x10000 + SIZEOF_HEADERS
@@ -65,8 +67,15 @@ SECTIONS .data.read_mostly : { *(.data.read_mostly) } + /* End of data section */ _edata = .; PROVIDE (edata = .); + + /* init_task */ + . = ALIGN(THREAD_SIZE); + .data.init_task : { + *(.data.init_task) + } .fixup : { __start___fixup = .; *(.fixup)
Signature · 1 line
1.6.0.2.GIT
Re: [PATCH] sparc: use .data.init_task section for
Quoted 9 lines · Sam Ravnborg
Use a dedicated aligned section for the
init_thread_unionvariable and declare this section invmlinux.lds.This align sparc with most other architectures.
Eventually this allow theinit_taskbits to be unified across all architectures.Signed-off-by Sam Ravnborg <[email protected]>Cc Kyle McMartin <[email protected]>
Thanks Sam!
I'm working on v2 of my init_task patchset, I'll try to post it to linux-arch this evening or Monday.
cheers, Kyle
David Miller
maintainerRe: [PATCH] sparc: use .data.init_task section for
In reply to Sam RavnborgFrom: Kyle McMartin <[email protected]>
Date: Sun, 21 Dec 2008 15:45:01 -0500
Quoted 12 lines · Sam Ravnborg
Quoted 8 lines
Use a dedicated aligned section for the
init_thread_unionvariable and declare this section invmlinux.lds.This align sparc with most other architectures.
Eventually this allow theinit_taskbits to be unified across all architectures.Signed-off-by Sam Ravnborg <[email protected]>Cc Kyle McMartin <[email protected]>I'm working on v2 of my
init_taskpatchset, I'll try to post it to linux-arch this evening or Monday.
Is this patch from Sam going into Kyle's patch set or should I apply it directly to sparc-next-2.6?
Just let me know...
Quoted 13 lines · David Miller
From: Kyle McMartin <[email protected]>
Date: Sun, 21 Dec 2008 15:45:01 -0500Quoted 10 lines · Sam Ravnborg
Quoted 8 lines
Use a dedicated aligned section for the
init_thread_unionvariable and declare this section invmlinux.lds.This align sparc with most other architectures.
Eventually this allow theinit_taskbits to be unified across all architectures.Signed-off-by Sam Ravnborg <[email protected]>Cc Kyle McMartin <[email protected]>
Quoted 7 lines
Quoted 2 lines
I'm working on v2 of my
init_taskpatchset, I'll try to post it to linux-arch this evening or Monday.Is this patch from Sam going into Kyle's patch set or should I apply it directly to sparc-next-2.6?
Just let me know...
I suggest that you take it via sparc-next-2.6.
With your usual track schedule you will soon have this merged and Kyle can rebase on top of linus' tree.
This will also allow us to do some minimal testing to check that the conversion to the vmlinux.lds based alignmnet does not cause any troubles before we use the generic version.
I will follow up if there is any fallout.
Sam
David Miller
maintainerRe: [PATCH] sparc: use .data.init_task section for
In reply to Sam RavnborgFrom: Sam Ravnborg <[email protected]>
Date: Sat, 27 Dec 2008 08:03:05 +0100
Quoted 9 lines · David Miller
Quoted 4 lines
Is this patch from Sam going into Kyle's patch set or should I apply it directly to sparc-next-2.6?
Just let me know...
I suggest that you take it via sparc-next-2.6.
With your usual track schedule you will soon have this merged and Kyle can rebase on top of linus' tree.
Ok.
Re: [PATCH] sparc: use .data.init_task section for
In reply to Sam RavnborgFrom: Sam Ravnborg <[email protected]>
Date: Sun, 21 Dec 2008 21:40:54 +0100
Quoted 7 lines
Use a dedicated aligned section for the
init_thread_unionvariable and declare this section invmlinux.lds.This align sparc with most other architectures.
Eventually this allow theinit_taskbits to be unified across all architectures.Signed-off-by Sam Ravnborg <[email protected]>
Applied.
Re: [PATCH] sparc: use .data.init_task section for
In reply to Sam RavnborgQuoted 17 lines · Sam Ravnborg
Quoted 16 lines · David Miller
From: Kyle McMartin <[email protected]>
Date: Sun, 21 Dec 2008 15:45:01 -0500Quoted 12 lines · Sam Ravnborg
Quoted 8 lines
Use a dedicated aligned section for the
init_thread_unionvariable and declare this section invmlinux.lds.This align sparc with most other architectures.
Eventually this allow theinit_taskbits to be unified across all architectures.Signed-off-by Sam Ravnborg <[email protected]>Cc Kyle McMartin <[email protected]>I'm working on v2 of my
init_taskpatchset, I'll try to post it to linux-arch this evening or Monday.
Quoted 8 lines
Quoted 4 lines
Is this patch from Sam going into Kyle's patch set or should I apply it directly to sparc-next-2.6?
Just let me know...
I suggest that you take it via sparc-next-2.6.
With your usual track schedule you will soon have this merged and Kyle can rebase on top of linus' tree.
Aye, with the coming sparc merge this is the sensible option. :)
cheers, Kyle