patch-2.2.19 linux/arch/alpha/kernel/process.c
Next file: linux/arch/alpha/kernel/smp.c
Previous file: linux/arch/alpha/kernel/osf_sys.c
Back to the patch index
Back to the overall index
- Lines: 59
- Date:
Sun Mar 25 11:37:29 2001
- Orig file:
v2.2.18/arch/alpha/kernel/process.c
- Orig date:
Sun Mar 25 11:13:14 2001
diff -u --new-file --recursive --exclude-from /usr/src/exclude v2.2.18/arch/alpha/kernel/process.c linux/arch/alpha/kernel/process.c
@@ -249,8 +249,11 @@
alpha_mv.kill_arch(LINUX_REBOOT_CMD_POWER_OFF, NULL);
}
-void show_regs(struct pt_regs * regs)
+void __show_regs(struct pt_regs * regs)
{
+ extern void dik_show_trace(unsigned long *);
+
+ printk("\nCPU: %d", smp_processor_id());
printk("\nps: %04lx pc: [<%016lx>]\n", regs->ps, regs->pc);
printk("rp: [<%016lx>] sp: %p\n", regs->r26, regs+1);
printk(" r0: %016lx r1: %016lx r2: %016lx r3: %016lx\n",
@@ -265,6 +268,15 @@
regs->r23, regs->r24, regs->r25, regs->r26);
printk("r27: %016lx r28: %016lx r29: %016lx hae: %016lx\n",
regs->r27, regs->r28, regs->gp, regs->hae);
+ dik_show_trace(regs+1);
+}
+
+void show_regs(struct pt_regs * regs)
+{
+ __show_regs(regs);
+#ifdef CONFIG_SMP
+ smp_show_regs();
+#endif
}
/*
@@ -463,3 +475,29 @@
unlock_kernel();
return error;
}
+
+#ifdef __SMP__
+/*
+ * execve() system call for in kernel use.
+ *
+ * Two(user and kernel) execve() have quite different call path and
+ * following function puts lock_kernel() and unlock_kernel() in kernel
+ * execve(). You could put them in unistd.h but you will have to
+ * modify many files to clear compile error -
+ *
+ * soohoon.lee@api-networks.com. */
+
+asmlinkage int ___kernel_execve(char *filename, char **argp, char **envp,
+ struct pt_regs *regs)
+{
+ int error;
+
+ lock_kernel();
+
+ error = do_execve(filename, argp, envp, regs);
+
+ unlock_kernel();
+
+ return error;
+}
+#endif /* __SMP__ */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)