From 190aa9f60f9575d1b7382cd1ee33e2589208c514 Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Wed, 6 Feb 2008 22:08:18 -0800 Subject: [SPARC]: Remove PTRACE_SUN* handling. Supporting SunOS ptrace() is pretty pointless and these kinds of quirks keep us from being able to share more code with other platforms. Signed-off-by: David S. Miller --- include/asm-sparc/ptrace.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'include/asm-sparc') diff --git a/include/asm-sparc/ptrace.h b/include/asm-sparc/ptrace.h index 714497099a42..a84345ba8bee 100644 --- a/include/asm-sparc/ptrace.h +++ b/include/asm-sparc/ptrace.h @@ -151,8 +151,6 @@ extern void show_regs(struct pt_regs *); #define SF_XXARG 0x5c /* Stuff for the ptrace system call */ -#define PTRACE_SUNATTACH 10 -#define PTRACE_SUNDETACH 11 #define PTRACE_GETREGS 12 #define PTRACE_SETREGS 13 #define PTRACE_GETFPREGS 14 -- cgit v1.2.3 From 9775369ec06bad8edb2fbd8c77316f49b439c225 Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Thu, 7 Feb 2008 03:00:17 -0800 Subject: [SPARC]: Move over to arch_ptrace(). Signed-off-by: David S. Miller --- include/asm-sparc/ptrace.h | 5 ----- 1 file changed, 5 deletions(-) (limited to 'include/asm-sparc') diff --git a/include/asm-sparc/ptrace.h b/include/asm-sparc/ptrace.h index a84345ba8bee..8201a7b29d49 100644 --- a/include/asm-sparc/ptrace.h +++ b/include/asm-sparc/ptrace.h @@ -61,8 +61,6 @@ struct sparc_stackf { #ifdef __KERNEL__ -#define __ARCH_SYS_PTRACE 1 - #define user_mode(regs) (!((regs)->psr & PSR_PS)) #define instruction_pointer(regs) ((regs)->pc) unsigned long profile_pc(struct pt_regs *); @@ -162,7 +160,4 @@ extern void show_regs(struct pt_regs *); #define PTRACE_GETFPAREGS 20 #define PTRACE_SETFPAREGS 21 -#define PTRACE_GETUCODE 29 /* stupid bsd-ism */ - - #endif /* !(_SPARC_PTRACE_H) */ -- cgit v1.2.3 From 5a4924d7be5df430132e109d3d2f26be610b4707 Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Thu, 7 Feb 2008 04:36:02 -0800 Subject: [SPARC32]: Use regsets for ELF core dumping. Signed-off-by: David S. Miller --- include/asm-sparc/elf.h | 38 ++++++++------------------------------ 1 file changed, 8 insertions(+), 30 deletions(-) (limited to 'include/asm-sparc') diff --git a/include/asm-sparc/elf.h b/include/asm-sparc/elf.h index aaf6ef40ee2f..2f8ff3fa0957 100644 --- a/include/asm-sparc/elf.h +++ b/include/asm-sparc/elf.h @@ -65,8 +65,14 @@ #define HWCAP_SPARC_V9 16 #define HWCAP_SPARC_ULTRA3 32 -/* For the most part we present code dumps in the format - * Solaris does. +#define CORE_DUMP_USE_REGSET + +/* Format is: + * G0 --> G7 + * O0 --> O7 + * L0 --> L7 + * I0 --> I7 + * PSR, PC, nPC, Y, WIM, TBR */ typedef unsigned long elf_greg_t; #define ELF_NGREG 38 @@ -87,34 +93,6 @@ typedef struct { #ifdef __KERNEL__ #include -#include - -/* Format is: - * G0 --> G7 - * O0 --> O7 - * L0 --> L7 - * I0 --> I7 - * PSR, PC, nPC, Y, WIM, TBR - */ -#define ELF_CORE_COPY_REGS(__elf_regs, __pt_regs) \ -do { unsigned long *dest = &(__elf_regs[0]); \ - struct pt_regs *src = (__pt_regs); \ - unsigned long __user *sp; \ - memcpy(&dest[0], &src->u_regs[0], \ - sizeof(unsigned long) * 16); \ - /* Don't try this at home kids... */ \ - sp = (unsigned long __user *) src->u_regs[14]; \ - copy_from_user(&dest[16], sp, \ - sizeof(unsigned long) * 16); \ - dest[32] = src->psr; \ - dest[33] = src->pc; \ - dest[34] = src->npc; \ - dest[35] = src->y; \ - dest[36] = dest[37] = 0; /* XXX */ \ -} while(0); /* Janitors: Don't touch this semicolon. */ - -#define ELF_CORE_COPY_TASK_REGS(__tsk, __elf_regs) \ - ({ ELF_CORE_COPY_REGS((*(__elf_regs)), (__tsk)->thread.kregs); 1; }) /* * This is used to ensure we don't load something for the wrong architecture. -- cgit v1.2.3