26 #include <linux/errno.h>
27 #include <linux/signal.h>
28 #include <linux/ptrace.h>
33 #include <asm/cacheflush.h>
34 #include <asm/syscalls.h>
35 #include <asm/ucontext.h>
54 #define save_gp_reg(i) { \
55 reg = regs->regs[i]; \
56 err |= __put_user(reg, &sc->sc_regs[i]); \
98 #define restore_gp_reg(i) do { \
99 err |= __get_user(reg, &sc->sc_regs[i]); \
100 regs->regs[i] = reg; \
112 #undef restore_gp_reg
130 if ((ka->
sa.sa_flags &
SA_ONSTACK) && (!on_sig_stack(sp)))
133 return (
void __user*)((sp - frame_size) & ~7);
141 unsigned long usp = regs->
regs[0];
178 "la\tr8, syscall_exit\n\t"
180 : :
"r" (regs) :
"r8");
213 &frame->
rs_uc.uc_stack.ss_sp);
215 &frame->
rs_uc.uc_stack.ss_flags);
217 &frame->
rs_uc.uc_stack.ss_size);
224 regs->
regs[0] = (
unsigned long) frame;
226 regs->
regs[4] = signr;
229 regs->
regs[29] = (
unsigned long) ka->
sa.sa_handler;
239 static void handle_signal(
unsigned long sig,
siginfo_t *info,
243 switch (regs->
regs[4]) {
265 if (setup_rt_frame(ka, regs, sig, sigmask_to_save(), info) < 0)
288 handle_signal(signr, &info, &ka, regs);
315 restore_saved_sigmask();
323 __u32 thread_info_flags)
330 tracehook_notify_resume(regs);