aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-i386/pda.h
diff options
context:
space:
mode:
authorJeremy Fitzhardinge <jeremy@goop.org>2006-12-06 20:14:03 -0500
committerAndi Kleen <andi@basil.nowhere.org>2006-12-06 20:14:03 -0500
commitec7fcaabbfb3c5bd5189f857b6ac7bb9745ef291 (patch)
tree9730e2849a9943e26f8d32f394296fd685b85e39 /include/asm-i386/pda.h
parentb2938f880890ebfcccad356275e0000193153623 (diff)
[PATCH] i386: Implement "current" with the PDA
Use the pcurrent field in the PDA to implement the "current" macro. This ends up compiling down to a single instruction to get the current task. Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com> Signed-off-by: Andi Kleen <ak@suse.de> Cc: Chuck Ebbert <76306.1226@compuserve.com> Cc: Zachary Amsden <zach@vmware.com> Cc: Jan Beulich <jbeulich@novell.com> Cc: Andi Kleen <ak@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org>
Diffstat (limited to 'include/asm-i386/pda.h')
-rw-r--r--include/asm-i386/pda.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/asm-i386/pda.h b/include/asm-i386/pda.h
index f90fde22566d..08a35c478af2 100644
--- a/include/asm-i386/pda.h
+++ b/include/asm-i386/pda.h
@@ -7,12 +7,14 @@
7#define _I386_PDA_H 7#define _I386_PDA_H
8 8
9#include <linux/stddef.h> 9#include <linux/stddef.h>
10#include <linux/types.h>
10 11
11struct i386_pda 12struct i386_pda
12{ 13{
13 struct i386_pda *_pda; /* pointer to self */ 14 struct i386_pda *_pda; /* pointer to self */
14 15
15 int cpu_number; 16 int cpu_number;
17 struct task_struct *pcurrent; /* current process */
16}; 18};
17 19
18extern struct i386_pda *_cpu_pda[]; 20extern struct i386_pda *_cpu_pda[];