diff options
author | H. Peter Anvin <hpa@zytor.com> | 2008-01-30 07:30:56 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-01-30 07:30:56 -0500 |
commit | 65ea5b0349903585bfed9720fa06f5edb4f1cd25 (patch) | |
tree | 6c252228c34416b7e2077f23475de34500c2ab8a /include/asm-x86/processor_64.h | |
parent | 53756d3722172815f52272b28c6d5d5e9639adde (diff) |
x86: rename the struct pt_regs members for 32/64-bit consistency
We have a lot of code which differs only by the naming of specific
members of structures that contain registers. In order to enable
additional unifications, this patch drops the e- or r- size prefix
from the register names in struct pt_regs, and drops the x- prefixes
for segment registers on the 32-bit side.
This patch also performs the equivalent renames in some additional
places that might be candidates for unification in the future.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'include/asm-x86/processor_64.h')
-rw-r--r-- | include/asm-x86/processor_64.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/include/asm-x86/processor_64.h b/include/asm-x86/processor_64.h index e7bea4fed642..797770113e6d 100644 --- a/include/asm-x86/processor_64.h +++ b/include/asm-x86/processor_64.h | |||
@@ -258,12 +258,12 @@ struct thread_struct { | |||
258 | #define start_thread(regs,new_rip,new_rsp) do { \ | 258 | #define start_thread(regs,new_rip,new_rsp) do { \ |
259 | asm volatile("movl %0,%%fs; movl %0,%%es; movl %0,%%ds": :"r" (0)); \ | 259 | asm volatile("movl %0,%%fs; movl %0,%%es; movl %0,%%ds": :"r" (0)); \ |
260 | load_gs_index(0); \ | 260 | load_gs_index(0); \ |
261 | (regs)->rip = (new_rip); \ | 261 | (regs)->ip = (new_rip); \ |
262 | (regs)->rsp = (new_rsp); \ | 262 | (regs)->sp = (new_rsp); \ |
263 | write_pda(oldrsp, (new_rsp)); \ | 263 | write_pda(oldrsp, (new_rsp)); \ |
264 | (regs)->cs = __USER_CS; \ | 264 | (regs)->cs = __USER_CS; \ |
265 | (regs)->ss = __USER_DS; \ | 265 | (regs)->ss = __USER_DS; \ |
266 | (regs)->eflags = 0x200; \ | 266 | (regs)->flags = 0x200; \ |
267 | set_fs(USER_DS); \ | 267 | set_fs(USER_DS); \ |
268 | } while(0) | 268 | } while(0) |
269 | 269 | ||
@@ -297,7 +297,7 @@ extern long kernel_thread(int (*fn)(void *), void * arg, unsigned long flags); | |||
297 | 297 | ||
298 | extern unsigned long get_wchan(struct task_struct *p); | 298 | extern unsigned long get_wchan(struct task_struct *p); |
299 | #define task_pt_regs(tsk) ((struct pt_regs *)(tsk)->thread.rsp0 - 1) | 299 | #define task_pt_regs(tsk) ((struct pt_regs *)(tsk)->thread.rsp0 - 1) |
300 | #define KSTK_EIP(tsk) (task_pt_regs(tsk)->rip) | 300 | #define KSTK_EIP(tsk) (task_pt_regs(tsk)->ip) |
301 | #define KSTK_ESP(tsk) -1 /* sorry. doesn't work for syscall. */ | 301 | #define KSTK_ESP(tsk) -1 /* sorry. doesn't work for syscall. */ |
302 | 302 | ||
303 | 303 | ||