From 255461c53a91d34e2eddb8c8a2ba39e99065d7c1 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Wed, 19 Sep 2012 13:05:49 -0400 Subject: mn10300: split ret_from_fork, simplify kernel_thread() Signed-off-by: Al Viro --- arch/mn10300/kernel/Makefile | 2 +- arch/mn10300/kernel/entry.S | 7 ++++++ arch/mn10300/kernel/internal.h | 6 +---- arch/mn10300/kernel/kthread.S | 31 ------------------------- arch/mn10300/kernel/process.c | 52 +++++++++++++++--------------------------- 5 files changed, 27 insertions(+), 71 deletions(-) delete mode 100644 arch/mn10300/kernel/kthread.S (limited to 'arch/mn10300') diff --git a/arch/mn10300/kernel/Makefile b/arch/mn10300/kernel/Makefile index d067491..142c129 100644 --- a/arch/mn10300/kernel/Makefile +++ b/arch/mn10300/kernel/Makefile @@ -7,7 +7,7 @@ fpu-obj-y := fpu-nofpu.o fpu-nofpu-low.o fpu-obj-$(CONFIG_FPU) := fpu.o fpu-low.o obj-y := process.o signal.o entry.o traps.o irq.o \ - ptrace.o setup.o time.o sys_mn10300.o io.o kthread.o \ + ptrace.o setup.o time.o sys_mn10300.o io.o \ switch_to.o mn10300_ksyms.o kernel_execve.o $(fpu-obj-y) \ csrc-mn10300.o cevt-mn10300.o diff --git a/arch/mn10300/kernel/entry.S b/arch/mn10300/kernel/entry.S index 8e11f9f..000f144 100644 --- a/arch/mn10300/kernel/entry.S +++ b/arch/mn10300/kernel/entry.S @@ -55,6 +55,13 @@ ENTRY(ret_from_fork) mov d0,(REG_D0,fp) jmp syscall_exit +ENTRY(ret_from_kernel_thread) + call schedule_tail[],0 + mov (REG_D0,fp),d0 + mov (REG_A0,fp),a0 + calls (a0) + jmp sys_exit + ############################################################################### # # system call handler diff --git a/arch/mn10300/kernel/internal.h b/arch/mn10300/kernel/internal.h index 2df4401..5617855 100644 --- a/arch/mn10300/kernel/internal.h +++ b/arch/mn10300/kernel/internal.h @@ -15,14 +15,10 @@ struct clocksource; struct clock_event_device; /* - * kthread.S - */ -extern int kernel_thread_helper(int); - -/* * entry.S */ extern void ret_from_fork(struct task_struct *) __attribute__((noreturn)); +extern void ret_from_kernel_thread(struct task_struct *) __attribute__((noreturn)); /* * smp-low.S diff --git a/arch/mn10300/kernel/kthread.S b/arch/mn10300/kernel/kthread.S deleted file mode 100644 index b5ae467..0000000 --- a/arch/mn10300/kernel/kthread.S +++ /dev/null @@ -1,31 +0,0 @@ -/* MN10300 Kernel thread trampoline function - * - * Copyright (C) 2007 Red Hat, Inc. All Rights Reserved. - * Written by Mark Salter (msalter@redhat.com) - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public Licence - * as published by the Free Software Foundation; either version - * 2 of the Licence, or (at your option) any later version. - */ - .text - -############################################################################### -# -# kernel_thread_helper - trampoline for kernel_thread() -# -# On entry: -# A2 = address of function to call -# D2 = function argument -# -############################################################################### - .globl kernel_thread_helper - .type kernel_thread_helper,@function -kernel_thread_helper: - mov do_exit,d1 - mov d1,(sp) - mov d1,mdr - mov d2,d0 - jmp (a2) - - .size kernel_thread_helper,.-kernel_thread_helper diff --git a/arch/mn10300/kernel/process.c b/arch/mn10300/kernel/process.c index 7dab0cd..be87fbe 100644 --- a/arch/mn10300/kernel/process.c +++ b/arch/mn10300/kernel/process.c @@ -166,13 +166,11 @@ void show_regs(struct pt_regs *regs) */ int kernel_thread(int (*fn)(void *), void *arg, unsigned long flags) { - struct pt_regs regs; + struct pt_regs regs = { + .a0 = (unsigned long) fn; + .d0 = (unsigned long) arg; + }; - memset(®s, 0, sizeof(regs)); - - regs.a2 = (unsigned long) fn; - regs.d2 = (unsigned long) arg; - regs.pc = (unsigned long) kernel_thread_helper; local_save_flags(regs.epsw); regs.epsw |= EPSW_IE | EPSW_IM_7; @@ -180,7 +178,6 @@ int kernel_thread(int (*fn)(void *), void *arg, unsigned long flags) return do_fork(flags | CLONE_VM | CLONE_UNTRACED, 0, ®s, 0, NULL, NULL); } -EXPORT_SYMBOL(kernel_thread); /* * free current thread data structures etc.. @@ -227,49 +224,36 @@ int copy_thread(unsigned long clone_flags, struct task_struct *p, struct pt_regs *kregs) { struct thread_info *ti = task_thread_info(p); - struct pt_regs *c_uregs, *c_kregs, *uregs; + struct pt_regs *c_regs; unsigned long c_ksp; - uregs = current->thread.uregs; - c_ksp = (unsigned long) task_stack_page(p) + THREAD_SIZE; /* allocate the userspace exception frame and set it up */ c_ksp -= sizeof(struct pt_regs); - c_uregs = (struct pt_regs *) c_ksp; + c_regs = (struct pt_regs *) c_ksp; - p->thread.uregs = c_uregs; - *c_uregs = *uregs; - c_uregs->sp = c_usp; - c_uregs->epsw &= ~EPSW_FE; /* my FPU */ + p->thread.uregs = c_regs; + *c_regs = *kregs; + c_regs->sp = c_usp; + c_regs->epsw &= ~EPSW_FE; /* my FPU */ c_ksp -= 12; /* allocate function call ABI slack */ /* the new TLS pointer is passed in as arg #5 to sys_clone() */ if (clone_flags & CLONE_SETTLS) - c_uregs->e2 = current_frame()->d3; - - /* set up the return kernel frame if called from kernel_thread() */ - c_kregs = c_uregs; - if (kregs != uregs) { - c_ksp -= sizeof(struct pt_regs); - c_kregs = (struct pt_regs *) c_ksp; - *c_kregs = *kregs; - c_kregs->sp = c_usp; - c_kregs->next = c_uregs; -#ifdef CONFIG_MN10300_CURRENT_IN_E2 - c_kregs->e2 = (unsigned long) p; /* current */ -#endif + c_regs->e2 = current_frame()->d3; - c_ksp -= 12; /* allocate function call ABI slack */ - } + if (unlikely(!user_mode(kregs))) + p->thread.pc = (unsigned long) ret_from_kernel_thread; + else + p->thread.pc = (unsigned long) ret_from_fork; /* set up things up so the scheduler can start the new task */ - ti->frame = c_kregs; - p->thread.a3 = (unsigned long) c_kregs; + ti->frame = c_regs; + p->thread.a3 = (unsigned long) c_regs; p->thread.sp = c_ksp; - p->thread.pc = (unsigned long) ret_from_fork; - p->thread.wchan = (unsigned long) ret_from_fork; + p->thread.wchan = p->thread.pc; p->thread.usp = c_usp; return 0; -- cgit v1.1 From 8f1597e959a3cfeae8f5cfae26890710f9092443 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Wed, 19 Sep 2012 13:08:13 -0400 Subject: mn10300: switch to generic sys_execve() Signed-off-by: Al Viro --- arch/mn10300/include/asm/ptrace.h | 1 + arch/mn10300/include/asm/unistd.h | 1 + arch/mn10300/kernel/process.c | 16 ---------------- 3 files changed, 2 insertions(+), 16 deletions(-) (limited to 'arch/mn10300') diff --git a/arch/mn10300/include/asm/ptrace.h b/arch/mn10300/include/asm/ptrace.h index 44251b9..08ac856 100644 --- a/arch/mn10300/include/asm/ptrace.h +++ b/arch/mn10300/include/asm/ptrace.h @@ -86,6 +86,7 @@ struct pt_regs { #define user_mode(regs) (((regs)->epsw & EPSW_nSL) == EPSW_nSL) #define instruction_pointer(regs) ((regs)->pc) #define user_stack_pointer(regs) ((regs)->sp) +#define current_pt_regs() current_frame() #define arch_has_single_step() (1) diff --git a/arch/mn10300/include/asm/unistd.h b/arch/mn10300/include/asm/unistd.h index 866eb14..a965de4 100644 --- a/arch/mn10300/include/asm/unistd.h +++ b/arch/mn10300/include/asm/unistd.h @@ -382,6 +382,7 @@ #define __ARCH_WANT_SYS_SIGPROCMASK #define __ARCH_WANT_SYS_RT_SIGACTION #define __ARCH_WANT_SYS_RT_SIGSUSPEND +#define __ARCH_WANT_SYS_EXECVE /* * "Conditional" syscalls diff --git a/arch/mn10300/kernel/process.c b/arch/mn10300/kernel/process.c index be87fbe..49af5ca 100644 --- a/arch/mn10300/kernel/process.c +++ b/arch/mn10300/kernel/process.c @@ -283,22 +283,6 @@ asmlinkage long sys_vfork(void) current_frame(), 0, NULL, NULL); } -asmlinkage long sys_execve(const char __user *name, - const char __user *const __user *argv, - const char __user *const __user *envp) -{ - char *filename; - int error; - - filename = getname(name); - error = PTR_ERR(filename); - if (IS_ERR(filename)) - return error; - error = do_execve(filename, argv, envp, current_frame()); - putname(filename); - return error; -} - unsigned long get_wchan(struct task_struct *p) { return p->thread.wchan; -- cgit v1.1 From 6e75421014cd02cc66298d35c4667e493da78914 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Wed, 19 Sep 2012 13:18:20 -0400 Subject: mn10300: switch to generic kernel_execve() Signed-off-by: Al Viro --- arch/mn10300/include/asm/frame.inc | 2 +- arch/mn10300/include/asm/processor.h | 13 +++---------- arch/mn10300/include/asm/unistd.h | 1 + arch/mn10300/kernel/Makefile | 2 +- arch/mn10300/kernel/entry.S | 7 +++++++ arch/mn10300/kernel/kernel_execve.S | 37 ------------------------------------ 6 files changed, 13 insertions(+), 49 deletions(-) delete mode 100644 arch/mn10300/kernel/kernel_execve.S (limited to 'arch/mn10300') diff --git a/arch/mn10300/include/asm/frame.inc b/arch/mn10300/include/asm/frame.inc index 2ee58e3..1c3eb4f 100644 --- a/arch/mn10300/include/asm/frame.inc +++ b/arch/mn10300/include/asm/frame.inc @@ -61,7 +61,7 @@ ############################################################################### .macro RESTORE_ALL # peel back the stack to the calling frame - # - this permits execve() to discard extra frames due to kernel syscalls + # - we need that when returning from interrupts to kernel mode GET_THREAD_INFO a0 mov (TI_frame,a0),fp mov fp,sp diff --git a/arch/mn10300/include/asm/processor.h b/arch/mn10300/include/asm/processor.h index 247928c..0b844a2 100644 --- a/arch/mn10300/include/asm/processor.h +++ b/arch/mn10300/include/asm/processor.h @@ -119,20 +119,13 @@ struct thread_struct { /* * do necessary setup to start up a newly executed thread - * - need to discard the frame stacked by the kernel thread invoking the execve - * syscall (see RESTORE_ALL macro) */ static inline void start_thread(struct pt_regs *regs, unsigned long new_pc, unsigned long new_sp) { - struct thread_info *ti = current_thread_info(); - struct pt_regs *frame0; - - frame0 = thread_info_to_uregs(ti); - frame0->epsw = EPSW_nSL | EPSW_IE | EPSW_IM; - frame0->pc = new_pc; - frame0->sp = new_sp; - ti->frame = frame0; + regs->epsw = EPSW_nSL | EPSW_IE | EPSW_IM; + regs->pc = new_pc; + regs->sp = new_sp; } diff --git a/arch/mn10300/include/asm/unistd.h b/arch/mn10300/include/asm/unistd.h index a965de4..044c770 100644 --- a/arch/mn10300/include/asm/unistd.h +++ b/arch/mn10300/include/asm/unistd.h @@ -383,6 +383,7 @@ #define __ARCH_WANT_SYS_RT_SIGACTION #define __ARCH_WANT_SYS_RT_SIGSUSPEND #define __ARCH_WANT_SYS_EXECVE +#define __ARCH_WANT_KERNEL_EXECVE /* * "Conditional" syscalls diff --git a/arch/mn10300/kernel/Makefile b/arch/mn10300/kernel/Makefile index 142c129..561029f 100644 --- a/arch/mn10300/kernel/Makefile +++ b/arch/mn10300/kernel/Makefile @@ -8,7 +8,7 @@ fpu-obj-$(CONFIG_FPU) := fpu.o fpu-low.o obj-y := process.o signal.o entry.o traps.o irq.o \ ptrace.o setup.o time.o sys_mn10300.o io.o \ - switch_to.o mn10300_ksyms.o kernel_execve.o $(fpu-obj-y) \ + switch_to.o mn10300_ksyms.o $(fpu-obj-y) \ csrc-mn10300.o cevt-mn10300.o obj-$(CONFIG_SMP) += smp.o smp-low.o diff --git a/arch/mn10300/kernel/entry.S b/arch/mn10300/kernel/entry.S index 000f144..7dee5f6 100644 --- a/arch/mn10300/kernel/entry.S +++ b/arch/mn10300/kernel/entry.S @@ -62,6 +62,13 @@ ENTRY(ret_from_kernel_thread) calls (a0) jmp sys_exit +ENTRY(ret_from_kernel_execve) + add -12,d0 /* pt_regs -> frame */ + mov d0,sp + GET_THREAD_INFO a2 + clr d0 + jmp syscall_exit + ############################################################################### # # system call handler diff --git a/arch/mn10300/kernel/kernel_execve.S b/arch/mn10300/kernel/kernel_execve.S deleted file mode 100644 index 86039f1..0000000 --- a/arch/mn10300/kernel/kernel_execve.S +++ /dev/null @@ -1,37 +0,0 @@ -/* MN10300 In-kernel program execution - * - * Copyright (C) 2007 Red Hat, Inc. All Rights Reserved. - * Written by David Howells (dhowells@redhat.com) - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public Licence - * as published by the Free Software Foundation; either version - * 2 of the Licence, or (at your option) any later version. - */ -#include -#include - -############################################################################### -# -# Do a system call from kernel instead of calling sys_execve so we end up with -# proper pt_regs. -# -# int kernel_execve(const char *filename, char *const argv[], -# char *const envp[]) -# -# On entry: D0/D1/8(SP): arguments to function -# On return: D0: syscall return. -# -############################################################################### - .globl kernel_execve - .type kernel_execve,@function -kernel_execve: - mov a3,a1 - mov d0,a0 - mov (12,sp),a3 - mov +__NR_execve,d0 - syscall 0 - mov a1,a3 - rets - - .size kernel_execve,.-kernel_execve -- cgit v1.1 From 61b7fbc3f4ebdcfd34f9438adfab8df936a19e33 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Sat, 22 Sep 2012 18:18:23 -0400 Subject: mn10300: convert to generic kernel_thread() Signed-off-by: Al Viro --- arch/mn10300/Kconfig | 1 + arch/mn10300/include/asm/processor.h | 5 ---- arch/mn10300/kernel/process.c | 49 +++++++++++++----------------------- 3 files changed, 19 insertions(+), 36 deletions(-) (limited to 'arch/mn10300') diff --git a/arch/mn10300/Kconfig b/arch/mn10300/Kconfig index 5cfb086..ddbdc33 100644 --- a/arch/mn10300/Kconfig +++ b/arch/mn10300/Kconfig @@ -8,6 +8,7 @@ config MN10300 select HAVE_ARCH_KGDB select HAVE_NMI_WATCHDOG if MN10300_WD_TIMER select GENERIC_CLOCKEVENTS + select GENERIC_KERNEL_THREAD config AM33_2 def_bool n diff --git a/arch/mn10300/include/asm/processor.h b/arch/mn10300/include/asm/processor.h index 0b844a2..8b80b19 100644 --- a/arch/mn10300/include/asm/processor.h +++ b/arch/mn10300/include/asm/processor.h @@ -133,11 +133,6 @@ static inline void start_thread(struct pt_regs *regs, extern void release_thread(struct task_struct *); /* - * create a kernel thread without removing it from tasklists - */ -extern int kernel_thread(int (*fn)(void *), void *arg, unsigned long flags); - -/* * Return saved PC of a blocked thread. */ extern unsigned long thread_saved_pc(struct task_struct *tsk); diff --git a/arch/mn10300/kernel/process.c b/arch/mn10300/kernel/process.c index 49af5ca..8ee09d8 100644 --- a/arch/mn10300/kernel/process.c +++ b/arch/mn10300/kernel/process.c @@ -162,24 +162,6 @@ void show_regs(struct pt_regs *regs) } /* - * create a kernel thread - */ -int kernel_thread(int (*fn)(void *), void *arg, unsigned long flags) -{ - struct pt_regs regs = { - .a0 = (unsigned long) fn; - .d0 = (unsigned long) arg; - }; - - local_save_flags(regs.epsw); - regs.epsw |= EPSW_IE | EPSW_IM_7; - - /* Ok, create the new process.. */ - return do_fork(flags | CLONE_VM | CLONE_UNTRACED, 0, ®s, 0, - NULL, NULL); -} - -/* * free current thread data structures etc.. */ void exit_thread(void) @@ -232,29 +214,34 @@ int copy_thread(unsigned long clone_flags, /* allocate the userspace exception frame and set it up */ c_ksp -= sizeof(struct pt_regs); c_regs = (struct pt_regs *) c_ksp; + c_ksp -= 12; /* allocate function call ABI slack */ + /* set up things up so the scheduler can start the new task */ p->thread.uregs = c_regs; + ti->frame = c_regs; + p->thread.a3 = (unsigned long) c_regs; + p->thread.sp = c_ksp; + p->thread.wchan = p->thread.pc; + p->thread.usp = c_usp; + + if (unlikely(!kregs)) { + memset(c_regs, 0, sizeof(struct pt_regs)); + c_regs->a0 = c_usp; /* function */ + c_regs->d0 = ustk_size; /* argument */ + local_save_flags(c_regs->epsw); + c_regs->epsw |= EPSW_IE | EPSW_IM_7; + p->thread.pc = (unsigned long) ret_from_kernel_thread; + return 0; + } *c_regs = *kregs; c_regs->sp = c_usp; c_regs->epsw &= ~EPSW_FE; /* my FPU */ - c_ksp -= 12; /* allocate function call ABI slack */ - /* the new TLS pointer is passed in as arg #5 to sys_clone() */ if (clone_flags & CLONE_SETTLS) c_regs->e2 = current_frame()->d3; - if (unlikely(!user_mode(kregs))) - p->thread.pc = (unsigned long) ret_from_kernel_thread; - else - p->thread.pc = (unsigned long) ret_from_fork; - - /* set up things up so the scheduler can start the new task */ - ti->frame = c_regs; - p->thread.a3 = (unsigned long) c_regs; - p->thread.sp = c_ksp; - p->thread.wchan = p->thread.pc; - p->thread.usp = c_usp; + p->thread.pc = (unsigned long) ret_from_fork; return 0; } -- cgit v1.1 From 6fdb6fbecbf1ca939699f09376e35169615a3678 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Mon, 30 Apr 2012 19:49:23 -0400 Subject: mn10300: get rid of calling do_notify_resume() when returning to kernel mode Signed-off-by: Al Viro --- arch/mn10300/kernel/entry.S | 4 ++++ arch/mn10300/kernel/signal.c | 5 ----- 2 files changed, 4 insertions(+), 5 deletions(-) (limited to 'arch/mn10300') diff --git a/arch/mn10300/kernel/entry.S b/arch/mn10300/kernel/entry.S index 7dee5f6..0c631d3 100644 --- a/arch/mn10300/kernel/entry.S +++ b/arch/mn10300/kernel/entry.S @@ -108,6 +108,10 @@ restore_all: ############################################################################### ALIGN syscall_exit_work: + mov (REG_EPSW,fp),d0 + and EPSW_nSL,d0 + beq resume_kernel # returning to supervisor mode + btst _TIF_SYSCALL_TRACE,d2 beq work_pending LOCAL_IRQ_ENABLE # could let syscall_trace_exit() call diff --git a/arch/mn10300/kernel/signal.c b/arch/mn10300/kernel/signal.c index 4d584ae..b2c0ac7 100644 --- a/arch/mn10300/kernel/signal.c +++ b/arch/mn10300/kernel/signal.c @@ -475,11 +475,6 @@ static void do_signal(struct pt_regs *regs) siginfo_t info; int signr; - /* we want the common case to go fast, which is why we may in certain - * cases get here from kernel mode */ - if (!user_mode(regs)) - return; - signr = get_signal_to_deliver(&info, &ka, regs, NULL); if (signr > 0) { if (handle_signal(signr, &info, &ka, regs) == 0) { -- cgit v1.1 From 8af4efac26e1805c76144ad44118157239308d35 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Fri, 1 Jun 2012 14:21:16 -0400 Subject: bury _TIF_RESTORE_SIGMASK never used... Signed-off-by: Al Viro --- arch/mn10300/include/asm/thread_info.h | 1 - 1 file changed, 1 deletion(-) (limited to 'arch/mn10300') diff --git a/arch/mn10300/include/asm/thread_info.h b/arch/mn10300/include/asm/thread_info.h index ac519bb..224b426 100644 --- a/arch/mn10300/include/asm/thread_info.h +++ b/arch/mn10300/include/asm/thread_info.h @@ -160,7 +160,6 @@ void arch_release_thread_info(struct thread_info *ti); #define _TIF_SIGPENDING +(1 << TIF_SIGPENDING) #define _TIF_NEED_RESCHED +(1 << TIF_NEED_RESCHED) #define _TIF_SINGLESTEP +(1 << TIF_SINGLESTEP) -#define _TIF_RESTORE_SIGMASK +(1 << TIF_RESTORE_SIGMASK) #define _TIF_POLLING_NRFLAG +(1 << TIF_POLLING_NRFLAG) #define _TIF_WORK_MASK 0x0000FFFE /* work to do on interrupt/exception return */ -- cgit v1.1 From 16a8016372c42c7628eb4a39d75386a461e8c5d0 Mon Sep 17 00:00:00 2001 From: Al Viro Date: Fri, 1 Jun 2012 14:22:01 -0400 Subject: sanitize tsk_is_polling() Make default just return 0. The current default (checking TIF_POLLING_NRFLAG) is taken to architectures that need it; ones that don't do polling in their idle threads don't need to defined TIF_POLLING_NRFLAG at all. ia64 defined both TS_POLLING (used by its tsk_is_polling()) and TIF_POLLING_NRFLAG (not used at all). Killed the latter... Signed-off-by: Al Viro --- arch/mn10300/include/asm/thread_info.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'arch/mn10300') diff --git a/arch/mn10300/include/asm/thread_info.h b/arch/mn10300/include/asm/thread_info.h index 224b426..f90062b 100644 --- a/arch/mn10300/include/asm/thread_info.h +++ b/arch/mn10300/include/asm/thread_info.h @@ -165,6 +165,8 @@ void arch_release_thread_info(struct thread_info *ti); #define _TIF_WORK_MASK 0x0000FFFE /* work to do on interrupt/exception return */ #define _TIF_ALLWORK_MASK 0x0000FFFF /* work to do on any return to u-space */ +#define tsk_is_polling(t) test_tsk_thread_flag(t, TIF_POLLING_NRFLAG) + #endif /* __KERNEL__ */ #endif /* _ASM_THREAD_INFO_H */ -- cgit v1.1 From 548916e9f59ba35174122e33c48ac744410973fa Mon Sep 17 00:00:00 2001 From: Al Viro Date: Sat, 26 May 2012 22:20:22 -0400 Subject: mn10300: don't bother with SIGTRAP in setup_frame() ... just tell signal_delivered() to do it. Signed-off-by: Al Viro --- arch/mn10300/kernel/signal.c | 8 -------- 1 file changed, 8 deletions(-) (limited to 'arch/mn10300') diff --git a/arch/mn10300/kernel/signal.c b/arch/mn10300/kernel/signal.c index b2c0ac7..f570b30 100644 --- a/arch/mn10300/kernel/signal.c +++ b/arch/mn10300/kernel/signal.c @@ -317,10 +317,6 @@ static int setup_frame(int sig, struct k_sigaction *ka, sigset_t *set, regs->d0 = sig; regs->d1 = (unsigned long) &frame->sc; - /* the tracer may want to single-step inside the handler */ - if (test_thread_flag(TIF_SINGLESTEP)) - ptrace_notify(SIGTRAP); - #if DEBUG_SIG printk(KERN_DEBUG "SIG deliver %d (%s:%d): sp=%p pc=%lx ra=%p\n", sig, current->comm, current->pid, frame, regs->pc, @@ -398,10 +394,6 @@ static int setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, regs->d0 = sig; regs->d1 = (long) &frame->info; - /* the tracer may want to single-step inside the handler */ - if (test_thread_flag(TIF_SINGLESTEP)) - ptrace_notify(SIGTRAP); - #if DEBUG_SIG printk(KERN_DEBUG "SIG deliver %d (%s:%d): sp=%p pc=%lx ra=%p\n", sig, current->comm, current->pid, frame, regs->pc, -- cgit v1.1