summaryrefslogtreecommitdiffstats
path: root/arch/mn10300/include/asm
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2012-09-19 13:18:20 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2012-10-01 00:53:59 -0400
commit6e75421014cd02cc66298d35c4667e493da78914 (patch)
treeb8c917bb766efc2396a7693b305e33e0c37e3a53 /arch/mn10300/include/asm
parent8f1597e959a3cfeae8f5cfae26890710f9092443 (diff)
downloadop-kernel-dev-6e75421014cd02cc66298d35c4667e493da78914.zip
op-kernel-dev-6e75421014cd02cc66298d35c4667e493da78914.tar.gz
mn10300: switch to generic kernel_execve()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch/mn10300/include/asm')
-rw-r--r--arch/mn10300/include/asm/frame.inc2
-rw-r--r--arch/mn10300/include/asm/processor.h13
-rw-r--r--arch/mn10300/include/asm/unistd.h1
3 files changed, 5 insertions, 11 deletions
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
OpenPOWER on IntegriCloud