Skip to content

Commit

Permalink
Use new __init_task_data macro in arch init_task.c files.
Browse files Browse the repository at this point in the history
Signed-off-by: Joe Perches <[email protected]>
Signed-off-by: Tim Abbott <[email protected]>
Acked-by: Paul Mundt <[email protected]>
Signed-off-by: Sam Ravnborg <[email protected]>
  • Loading branch information
JoePerches authored and sravnborg committed Sep 21, 2009
1 parent 42f29a2 commit d200c92
Show file tree
Hide file tree
Showing 22 changed files with 46 additions and 62 deletions.
5 changes: 2 additions & 3 deletions arch/arm/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
*
* The things we do for performance..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/avr32/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
/*
* Initial thread structure. Must be aligned on an 8192-byte boundary.
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/cris/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/frv/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/h8300/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ EXPORT_SYMBOL(init_task);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

3 changes: 2 additions & 1 deletion arch/ia64/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ union {
struct thread_info thread_info;
} s;
unsigned long stack[KERNEL_STACK_SIZE/sizeof (unsigned long)];
} init_task_mem asm ("init_task") __attribute__((section(".data.init_task"))) = {{
} init_task_mem asm ("init_task") __init_task_data =
{{
.task = INIT_TASK(init_task_mem.s.task),
.thread_info = INIT_THREAD_INFO(init_task_mem.s.task)
}};
Expand Down
5 changes: 2 additions & 3 deletions arch/m32r/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
6 changes: 3 additions & 3 deletions arch/m68k/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@
*/
static struct signal_struct init_signals = INIT_SIGNALS(init_signals);
static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
union thread_union init_thread_union
__attribute__((section(".data.init_task"), aligned(THREAD_SIZE)))
= { INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data
__attribute__((aligned(THREAD_SIZE))) =
{ INIT_THREAD_INFO(init_task) };

/* initial task structure */
struct task_struct init_task = INIT_TASK(init_task);
Expand Down
5 changes: 2 additions & 3 deletions arch/m68knommu/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ EXPORT_SYMBOL(init_task);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

5 changes: 2 additions & 3 deletions arch/microblaze/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,8 @@
static struct signal_struct init_signals = INIT_SIGNALS(init_signals);
static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);

union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

struct task_struct init_task = INIT_TASK(init_task);
EXPORT_SYMBOL(init_task);
5 changes: 2 additions & 3 deletions arch/mips/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
*
* The things we do for performance..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"),
__aligned__(THREAD_SIZE))) =
union thread_union init_thread_union __init_task_data
__attribute__((__aligned__(THREAD_SIZE))) =
{ INIT_THREAD_INFO(init_task) };

/*
Expand Down
5 changes: 2 additions & 3 deletions arch/mn10300/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
4 changes: 2 additions & 2 deletions arch/parisc/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((aligned(128))) __attribute__((__section__(".data.init_task"))) =
union thread_union init_thread_union __init_task_data
__attribute__((aligned(128))) =
{ INIT_THREAD_INFO(init_task) };

#if PT_NLEVELS == 3
Expand Down
5 changes: 2 additions & 3 deletions arch/powerpc/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 3 additions & 2 deletions arch/powerpc/kernel/machine_kexec_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include <linux/kexec.h>
#include <linux/smp.h>
#include <linux/thread_info.h>
#include <linux/init_task.h>
#include <linux/errno.h>

#include <asm/page.h>
Expand Down Expand Up @@ -249,8 +250,8 @@ static void kexec_prepare_cpus(void)
* We could use a smaller stack if we don't care about anything using
* current, but that audit has not been performed.
*/
static union thread_union kexec_stack
__attribute__((__section__(".data.init_task"))) = { };
static union thread_union kexec_stack __init_task_data =
{ };

/* Our assembly helper, in kexec_stub.S */
extern NORET_TYPE void kexec_sequence(void *newstack, unsigned long start,
Expand Down
5 changes: 2 additions & 3 deletions arch/s390/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/score/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"), __aligned__(THREAD_SIZE))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/sh/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@ struct pt_regs fake_swapper_regs;
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/sparc/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,5 @@ EXPORT_SYMBOL(init_task);
* If this is not aligned on a 8k boundry, then you should change code
* in etrap.S which assumes it.
*/
union thread_union init_thread_union
__attribute__((section (".data.init_task")))
= { INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };
5 changes: 2 additions & 3 deletions arch/um/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,8 @@ EXPORT_SYMBOL(init_task);
* "init_task" linker map entry..
*/

union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

union thread_union cpu0_irqstack
__attribute__((__section__(".data.init_irqstack"))) =
Expand Down
5 changes: 2 additions & 3 deletions arch/x86/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,8 @@ static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
* way process stacks are handled. This is done by having a special
* "init_task" linker map entry..
*/
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

/*
* Initial task structure.
Expand Down
5 changes: 2 additions & 3 deletions arch/xtensa/kernel/init_task.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,8 @@

static struct signal_struct init_signals = INIT_SIGNALS(init_signals);
static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
union thread_union init_thread_union
__attribute__((__section__(".data.init_task"))) =
{ INIT_THREAD_INFO(init_task) };
union thread_union init_thread_union __init_task_data =
{ INIT_THREAD_INFO(init_task) };

struct task_struct init_task = INIT_TASK(init_task);

Expand Down

0 comments on commit d200c92

Please sign in to comment.