11 #include <linux/module.h>
12 #include <linux/errno.h>
13 #include <linux/sched.h>
14 #include <linux/kernel.h>
17 #include <linux/stddef.h>
19 #include <linux/ptrace.h>
23 #include <linux/reboot.h>
27 #include <linux/slab.h>
29 #include <asm/uaccess.h>
30 #include <asm/pgtable.h>
32 #include <asm/processor.h>
33 #include <asm/mmu_context.h>
36 #include <asm/gdb-stub.h>
50 return ((
unsigned long *) tsk->
thread.sp)[3];
59 #if !defined(CONFIG_SMP) || defined(CONFIG_HOTPLUG_CPU)
78 static inline void poll_idle(
void)
91 set_thread_flag(TIF_POLLING_NRFLAG);
92 while (!need_resched())
94 clear_thread_flag(TIF_POLLING_NRFLAG);
112 while (!need_resched()) {
118 #if defined(CONFIG_SMP) && !defined(CONFIG_HOTPLUG_CPU)
138 #ifdef CONFIG_KERNEL_DEBUGGER
142 #ifdef mn10300_unit_hard_reset
145 mn10300_proc_hard_reset();
151 #ifdef CONFIG_KERNEL_DEBUGGER
158 #ifdef CONFIG_KERNEL_DEBUGGER
208 unsigned long c_usp,
unsigned long ustk_size,
218 c_ksp -=
sizeof(
struct pt_regs);
219 c_regs = (
struct pt_regs *) c_ksp;
233 c_regs->
d0 = ustk_size;
235 c_regs->
epsw |= EPSW_IE | EPSW_IM_7;
241 c_regs->
epsw &= ~EPSW_FE;
245 c_regs->
e2 = current_frame()->d3;
257 int __user *parent_tidptr,
int __user *child_tidptr,
260 return do_fork(clone_flags, newsp ?: current_frame()->
sp,
261 current_frame(), 0, parent_tidptr, child_tidptr);