summaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc/current.h
diff options
context:
space:
mode:
authorDmitry Torokhov <dtor@insightbb.com>2006-11-05 04:42:39 +0100
committerDmitry Torokhov <dtor@insightbb.com>2006-11-05 04:42:39 +0100
commit752c58a471c108d64da1676b2925dfbd83eb177e (patch)
treefbffa0d7c54cd812950dffc16d642c9d449f4faf /include/asm-powerpc/current.h
parentInput: drivers/char/keyboard.c - small cleanup in k_cur() (diff)
parentMake sure "user->sigpending" count is in sync (diff)
downloadlinux-752c58a471c108d64da1676b2925dfbd83eb177e.tar.xz
linux-752c58a471c108d64da1676b2925dfbd83eb177e.zip
Merge rsync://rsync.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'include/asm-powerpc/current.h')
-rw-r--r--include/asm-powerpc/current.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/include/asm-powerpc/current.h b/include/asm-powerpc/current.h
index 1938d6abd255..b8708aedf925 100644
--- a/include/asm-powerpc/current.h
+++ b/include/asm-powerpc/current.h
@@ -14,7 +14,17 @@ struct task_struct;
#ifdef __powerpc64__
#include <asm/paca.h>
-#define current (get_paca()->__current)
+static inline struct task_struct *get_current(void)
+{
+ struct task_struct *task;
+
+ __asm__ __volatile__("ld %0,%1(13)"
+ : "=r" (task)
+ : "i" (offsetof(struct paca_struct, __current)));
+
+ return task;
+}
+#define current get_current()
#else