ia64/xen-unstable

changeset 16770:fd56e24b07c8

[IA64] Remove init_task definition

init_task in kernel area shouldn't be referenced.
The corresponding address in the identity mapping area should be used.
i.e. ia64_tpa(init_task) + PAGE_OFFSET, because ia64_switch_rr7() and
vmx_switch_rr7() assume that stack is in indentity mapping area.
To make it sure, remove init_task definition.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
author Alex Williamson <alex.williamson@hp.com>
date Thu Jan 17 12:05:43 2008 -0700 (2008-01-17)
parents d4abdf169a00
children e8d933b33f4b
files xen/arch/ia64/linux-xen/head.S xen/arch/ia64/xen/idle0_task.c
line diff
     1.1 --- a/xen/arch/ia64/linux-xen/head.S	Thu Jan 17 12:05:43 2008 -0700
     1.2 +++ b/xen/arch/ia64/linux-xen/head.S	Thu Jan 17 12:05:43 2008 -0700
     1.3 @@ -311,6 +311,10 @@ 1:	// now we are in virtual mode
     1.4  #define isAP	p2	// are we an Application Processor?
     1.5  #define isBP	p3	// are we the Bootstrap Processor?
     1.6  
     1.7 +#ifdef XEN
     1.8 +# define init_task	init_task_mem
     1.9 +#endif
    1.10 +
    1.11  #ifdef CONFIG_SMP
    1.12  	/*
    1.13  	 * Find the init_task for the currently booting CPU.  At poweron, and in
     2.1 --- a/xen/arch/ia64/xen/idle0_task.c	Thu Jan 17 12:05:43 2008 -0700
     2.2 +++ b/xen/arch/ia64/xen/idle0_task.c	Thu Jan 17 12:05:43 2008 -0700
     2.3 @@ -11,17 +11,19 @@
     2.4  /*
     2.5   * Initial task structure.
     2.6   *
     2.7 - * We need to make sure that this is properly aligned due to the way process stacks are
     2.8 - * handled. This is done by having a special ".data.init_task" section...
     2.9 + * We need to make sure that this is properly aligned due to the way process
    2.10 + * stacks are handled.
    2.11 + * This is done by having a special ".data.init_task" section...
    2.12 + *
    2.13 + * init_task_mem shouldn't be used directly. the corresponding address in
    2.14 + * the identity mapping area should be used.
    2.15 + * I.e. __va(ia64_tpa(init_task_mem)) should be used.
    2.16   */
    2.17  union {
    2.18  	struct {
    2.19  		struct vcpu task;
    2.20  	} s;
    2.21  	unsigned long stack[KERNEL_STACK_SIZE/sizeof (unsigned long)];
    2.22 -} init_task_mem asm ("init_task") __attribute__((section(".data.init_task"))) = {{
    2.23 +} init_task_mem __attribute__((section(".data.init_task"))) = {{
    2.24  	.task = IDLE_VCPU(init_task_mem.s.task)
    2.25  }};
    2.26 -
    2.27 -EXPORT_SYMBOL(init_task);
    2.28 -