frv: switch to generic kernel_execve

Acked-by: David Howells <dhowells@redhat.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Al Viro
2012-09-18 22:33:44 -04:00
rodzic 460dabab73
commit 019f96a345
5 zmienionych plików z 10 dodań i 39 usunięć

Wyświetl plik

@@ -8,7 +8,7 @@ heads-$(CONFIG_MMU) := head-mmu-fr451.o
extra-y:= head.o vmlinux.lds
obj-y := $(heads-y) entry.o entry-table.o break.o switch_to.o \
kernel_execve.o process.o traps.o ptrace.o signal.o dma.o \
process.o traps.o ptrace.o signal.o dma.o \
sys_frv.o time.o setup.o frv_ksyms.o \
debug-stub.o irq.o sleep.o uaccess.o

Wyświetl plik

@@ -871,6 +871,11 @@ ret_from_kernel_thread:
calll @(gr21,gr0)
bra sys_exit
.globl ret_from_kernel_execve
ret_from_kernel_execve:
ori gr28,0,sp
bra __syscall_exit
###################################################################################################
#
# Return to user mode is not as complex as all this looks,

Wyświetl plik

@@ -1,33 +0,0 @@
/* in-kernel program execution
*
* Copyright (C) 2006 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 License
* as published by the Free Software Foundation; either version
* 2 of the License, or (at your option) any later version.
*/
#include <linux/linkage.h>
#include <asm/unistd.h>
###############################################################################
#
# 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: GR8/GR9/GR10: arguments to function
# On return: GR8: syscall return.
#
###############################################################################
.globl kernel_execve
.type kernel_execve,@function
kernel_execve:
setlos __NR_execve,gr7
tira gr0,#0
bralr
.size kernel_execve,.-kernel_execve