aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2005-11-07 19:14:20 -0500
committerPaul Mackerras <paulus@samba.org>2005-11-07 19:14:20 -0500
commit24bfb00123e82a2e70bd115277d922438813515b (patch)
tree27328b8a5718e16d64e2d101f4b7ddcad5930aed /arch/powerpc/kernel
parentc6135234550ed89a6fd0e8cb229633967e41d649 (diff)
parent3f00d3e8fb963968a922d821a9a53b503b687e81 (diff)
Merge ../linux-2.6
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r--arch/powerpc/kernel/cputable.c10
-rw-r--r--arch/powerpc/kernel/ptrace.c43
-rw-r--r--arch/powerpc/kernel/time.c1
3 files changed, 13 insertions, 41 deletions
diff --git a/arch/powerpc/kernel/cputable.c b/arch/powerpc/kernel/cputable.c
index 33c63bcf69f8..cc4e9eb1c13f 100644
--- a/arch/powerpc/kernel/cputable.c
+++ b/arch/powerpc/kernel/cputable.c
@@ -929,6 +929,16 @@ struct cpu_spec cpu_specs[] = {
929 .icache_bsize = 32, 929 .icache_bsize = 32,
930 .dcache_bsize = 32, 930 .dcache_bsize = 32,
931 }, 931 },
932 { /* 440SPe Rev. A */
933 .pvr_mask = 0xff000fff,
934 .pvr_value = 0x53000890,
935 .cpu_name = "440SPe Rev. A",
936 .cpu_features = CPU_FTR_SPLIT_ID_CACHE |
937 CPU_FTR_USE_TB,
938 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
939 .icache_bsize = 32,
940 .dcache_bsize = 32,
941 },
932#endif /* CONFIG_44x */ 942#endif /* CONFIG_44x */
933#ifdef CONFIG_FSL_BOOKE 943#ifdef CONFIG_FSL_BOOKE
934 { /* e200z5 */ 944 { /* e200z5 */
diff --git a/arch/powerpc/kernel/ptrace.c b/arch/powerpc/kernel/ptrace.c
index 568ea335d616..3d2abd95c7ae 100644
--- a/arch/powerpc/kernel/ptrace.c
+++ b/arch/powerpc/kernel/ptrace.c
@@ -248,46 +248,10 @@ void ptrace_disable(struct task_struct *child)
248 clear_single_step(child); 248 clear_single_step(child);
249} 249}
250 250
251long sys_ptrace(long request, long pid, long addr, long data) 251long arch_ptrace(struct task_struct *child, long request, long addr, long data)
252{ 252{
253 struct task_struct *child;
254 int ret = -EPERM; 253 int ret = -EPERM;
255 254
256 lock_kernel();
257 if (request == PTRACE_TRACEME) {
258 /* are we already being traced? */
259 if (current->ptrace & PT_PTRACED)
260 goto out;
261 ret = security_ptrace(current->parent, current);
262 if (ret)
263 goto out;
264 /* set the ptrace bit in the process flags. */
265 current->ptrace |= PT_PTRACED;
266 ret = 0;
267 goto out;
268 }
269 ret = -ESRCH;
270 read_lock(&tasklist_lock);
271 child = find_task_by_pid(pid);
272 if (child)
273 get_task_struct(child);
274 read_unlock(&tasklist_lock);
275 if (!child)
276 goto out;
277
278 ret = -EPERM;
279 if (pid == 1) /* you may not mess with init */
280 goto out_tsk;
281
282 if (request == PTRACE_ATTACH) {
283 ret = ptrace_attach(child);
284 goto out_tsk;
285 }
286
287 ret = ptrace_check_attach(child, request == PTRACE_KILL);
288 if (ret < 0)
289 goto out_tsk;
290
291 switch (request) { 255 switch (request) {
292 /* when I and D space are separate, these will need to be fixed. */ 256 /* when I and D space are separate, these will need to be fixed. */
293 case PTRACE_PEEKTEXT: /* read word at location addr. */ 257 case PTRACE_PEEKTEXT: /* read word at location addr. */
@@ -540,10 +504,7 @@ long sys_ptrace(long request, long pid, long addr, long data)
540 ret = ptrace_request(child, request, addr, data); 504 ret = ptrace_request(child, request, addr, data);
541 break; 505 break;
542 } 506 }
543out_tsk: 507
544 put_task_struct(child);
545out:
546 unlock_kernel();
547 return ret; 508 return ret;
548} 509}
549 510
diff --git a/arch/powerpc/kernel/time.c b/arch/powerpc/kernel/time.c
index 1c7ea5e06311..a6282b625b44 100644
--- a/arch/powerpc/kernel/time.c
+++ b/arch/powerpc/kernel/time.c
@@ -70,6 +70,7 @@
70#include <asm/iseries/it_lp_queue.h> 70#include <asm/iseries/it_lp_queue.h>
71#include <asm/iseries/hv_call_xm.h> 71#include <asm/iseries/hv_call_xm.h>
72#endif 72#endif
73#include <asm/smp.h>
73 74
74/* keep track of when we need to update the rtc */ 75/* keep track of when we need to update the rtc */
75time_t last_rtc_update; 76time_t last_rtc_update;