]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/ppc/kernel/asm-offsets.c
ppc/powerpc: use kbuild.h instead of defining macros in asm-offsets.c
[linux-2.6-omap-h63xx.git] / arch / ppc / kernel / asm-offsets.c
index c5850a272650b688e462a9b1415e9c3514df5f1c..8dcbdd6c2d2c3bae19ef6f846f2f4b25b26c6c58 100644 (file)
@@ -18,6 +18,8 @@
 #include <linux/suspend.h>
 #include <linux/mman.h>
 #include <linux/mm.h>
+#include <linux/kbuild.h>
+
 #include <asm/io.h>
 #include <asm/page.h>
 #include <asm/pgtable.h>
 #include <asm/thread_info.h>
 #include <asm/vdso_datapage.h>
 
-#define DEFINE(sym, val) \
-       asm volatile("\n->" #sym " %0 " #val : : "i" (val))
-
-#define BLANK() asm volatile("\n->" : : )
-
 int
 main(void)
 {
        DEFINE(THREAD, offsetof(struct task_struct, thread));
-       DEFINE(THREAD_INFO, offsetof(struct task_struct, thread_info));
+       DEFINE(THREAD_INFO, offsetof(struct task_struct, stack));
        DEFINE(MM, offsetof(struct task_struct, mm));
        DEFINE(PTRACE, offsetof(struct task_struct, ptrace));
        DEFINE(KSP, offsetof(struct thread_struct, ksp));
@@ -54,12 +51,6 @@ main(void)
        DEFINE(THREAD_VSCR, offsetof(struct thread_struct, vscr));
        DEFINE(THREAD_USED_VR, offsetof(struct thread_struct, used_vr));
 #endif /* CONFIG_ALTIVEC */
-#ifdef CONFIG_SPE
-       DEFINE(THREAD_EVR0, offsetof(struct thread_struct, evr[0]));
-       DEFINE(THREAD_ACC, offsetof(struct thread_struct, acc));
-       DEFINE(THREAD_SPEFSCR, offsetof(struct thread_struct, spefscr));
-       DEFINE(THREAD_USED_SPE, offsetof(struct thread_struct, used_spe));
-#endif /* CONFIG_SPE */
        /* Interrupt register frame */
        DEFINE(STACK_FRAME_OVERHEAD, STACK_FRAME_OVERHEAD);
        DEFINE(INT_FRAME_SIZE, STACK_FRAME_OVERHEAD + sizeof(struct pt_regs));