aboutsummaryrefslogtreecommitdiffstats
path: root/arch/um/os-Linux/registers.c
diff options
context:
space:
mode:
authorJeff Dike <jdike@addtoit.com>2007-10-16 04:27:07 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-16 12:43:06 -0400
commit18badddaa84e13e126f4ca5df47ac55b97a2635a (patch)
treec57bee27c8144481a59546fcbd8487d9486c6a54 /arch/um/os-Linux/registers.c
parent6c738ffa9fea6869f5d51882dfefbba746e432b1 (diff)
uml: rename pt_regs general-purpose register file
Before the removal of tt mode, access to a register on the skas-mode side of a pt_regs struct looked like pt_regs.regs.skas.regs.regs[FOO]. This was bad enough, but it became pt_regs.regs.regs.regs[FOO] with the removal of the union from the middle. To get rid of the run of three "regs", the last field is renamed to "gp". Signed-off-by: Jeff Dike <jdike@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/um/os-Linux/registers.c')
-rw-r--r--arch/um/os-Linux/registers.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/um/os-Linux/registers.c b/arch/um/os-Linux/registers.c
index 14732f98e0a2..b06c780e8dba 100644
--- a/arch/um/os-Linux/registers.c
+++ b/arch/um/os-Linux/registers.c
@@ -16,14 +16,14 @@ static unsigned long exec_regs[MAX_REG_NR];
16 16
17void init_thread_registers(struct uml_pt_regs *to) 17void init_thread_registers(struct uml_pt_regs *to)
18{ 18{
19 memcpy(to->regs, exec_regs, sizeof(to->regs)); 19 memcpy(to->gp, exec_regs, sizeof(to->gp));
20} 20}
21 21
22void save_registers(int pid, struct uml_pt_regs *regs) 22void save_registers(int pid, struct uml_pt_regs *regs)
23{ 23{
24 int err; 24 int err;
25 25
26 err = ptrace(PTRACE_GETREGS, pid, 0, regs->regs); 26 err = ptrace(PTRACE_GETREGS, pid, 0, regs->gp);
27 if (err < 0) 27 if (err < 0)
28 panic("save_registers - saving registers failed, errno = %d\n", 28 panic("save_registers - saving registers failed, errno = %d\n",
29 errno); 29 errno);
@@ -33,7 +33,7 @@ void restore_registers(int pid, struct uml_pt_regs *regs)
33{ 33{
34 int err; 34 int err;
35 35
36 err = ptrace(PTRACE_SETREGS, pid, 0, regs->regs); 36 err = ptrace(PTRACE_SETREGS, pid, 0, regs->gp);
37 if (err < 0) 37 if (err < 0)
38 panic("restore_registers - saving registers failed, " 38 panic("restore_registers - saving registers failed, "
39 "errno = %d\n", errno); 39 "errno = %d\n", errno);