Update ia64 patch to 2.5.72-030619
[linux-flexiantxendom0-3.2.10.git] / include / asm-ia64 / system.h
index 250c0fa..2d7f0b2 100644 (file)
 #include <asm/pal.h>
 #include <asm/percpu.h>
 
-#define KERNEL_START           (PAGE_OFFSET + 68*1024*1024)
-
-/* 0xa000000000000000 - 0xa000000000000000+PERCPU_MAX_SIZE remain unmapped */
+/* 0xa000000000000000 - 0xa000000000000000+PERCPU_PAGE_SIZE remain unmapped */
 #define PERCPU_ADDR            (0xa000000000000000 + PERCPU_PAGE_SIZE)
 #define GATE_ADDR              (0xa000000000000000 + 2*PERCPU_PAGE_SIZE)
+#define KERNEL_START            0xa000000100000000
 
 #ifndef __ASSEMBLY__
 
@@ -217,13 +216,11 @@ extern void ia64_load_extra (struct task_struct *task);
         || IS_IA32_PROCESS(ia64_task_regs(t)) || PERFMON_IS_SYSWIDE())
 
 #define __switch_to(prev,next,last) do {                                                        \
-       struct task_struct *__fpu_owner = ia64_get_fpu_owner();                                  \
        if (IA64_HAS_EXTRA_STATE(prev))                                                          \
                ia64_save_extra(prev);                                                           \
        if (IA64_HAS_EXTRA_STATE(next))                                                          \
                ia64_load_extra(next);                                                           \
-       ia64_psr(ia64_task_regs(next))->dfh =                                                    \
-               !(__fpu_owner == (next) && ((next)->thread.last_fph_cpu == smp_processor_id())); \
+       ia64_psr(ia64_task_regs(next))->dfh = !ia64_is_local_fpu_owner(next);                    \
        (last) = ia64_switch_to((next));                                                         \
 } while (0)
 
@@ -239,7 +236,6 @@ extern void ia64_load_extra (struct task_struct *task);
                ia64_psr(ia64_task_regs(prev))->mfh = 0;                        \
                (prev)->thread.flags |= IA64_THREAD_FPH_VALID;                  \
                __ia64_save_fpu((prev)->thread.fph);                            \
-               (prev)->thread.last_fph_cpu = smp_processor_id();               \
        }                                                                       \
        __switch_to(prev, next, last);                                          \
 } while (0)
@@ -279,6 +275,8 @@ do {                                                \
 #define finish_arch_switch(rq, prev)   spin_unlock_irq(&(prev)->switch_lock)
 #define task_running(rq, p)            ((rq)->curr == (p) || spin_is_locked(&(p)->switch_lock))
 
+#define ia64_platform_is(x) (strcmp(x, platform_name) == 0)
+
 #endif /* __KERNEL__ */
 
 #endif /* __ASSEMBLY__ */