diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-12-12 15:22:13 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-12-12 15:22:13 -0500 |
commit | 9977d9b379cb77e0f67bd6f4563618106e58e11d (patch) | |
tree | 0191accfddf578edb52c69c933d64521e3dce297 /arch/h8300/include | |
parent | cf4af01221579a4e895f43dbfc47598fbfc5a731 (diff) | |
parent | 541880d9a2c7871f6370071d55aa6662d329c51e (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal
Pull big execve/kernel_thread/fork unification series from Al Viro:
"All architectures are converted to new model. Quite a bit of that
stuff is actually shared with architecture trees; in such cases it's
literally shared branch pulled by both, not a cherry-pick.
A lot of ugliness and black magic is gone (-3KLoC total in this one):
- kernel_thread()/kernel_execve()/sys_execve() redesign.
We don't do syscalls from kernel anymore for either kernel_thread()
or kernel_execve():
kernel_thread() is essentially clone(2) with callback run before we
return to userland, the callbacks either never return or do
successful do_execve() before returning.
kernel_execve() is a wrapper for do_execve() - it doesn't need to
do transition to user mode anymore.
As a result kernel_thread() and kernel_execve() are
arch-independent now - they live in kernel/fork.c and fs/exec.c
resp. sys_execve() is also in fs/exec.c and it's completely
architecture-independent.
- daemonize() is gone, along with its parts in fs/*.c
- struct pt_regs * is no longer passed to do_fork/copy_process/
copy_thread/do_execve/search_binary_handler/->load_binary/do_coredump.
- sys_fork()/sys_vfork()/sys_clone() unified; some architectures
still need wrappers (ones with callee-saved registers not saved in
pt_regs on syscall entry), but the main part of those suckers is in
kernel/fork.c now."
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal: (113 commits)
do_coredump(): get rid of pt_regs argument
print_fatal_signal(): get rid of pt_regs argument
ptrace_signal(): get rid of unused arguments
get rid of ptrace_signal_deliver() arguments
new helper: signal_pt_regs()
unify default ptrace_signal_deliver
flagday: kill pt_regs argument of do_fork()
death to idle_regs()
don't pass regs to copy_process()
flagday: don't pass regs to copy_thread()
bfin: switch to generic vfork, get rid of pointless wrappers
xtensa: switch to generic clone()
openrisc: switch to use of generic fork and clone
unicore32: switch to generic clone(2)
score: switch to generic fork/vfork/clone
c6x: sanitize copy_thread(), get rid of clone(2) wrapper, switch to generic clone()
take sys_fork/sys_vfork/sys_clone prototypes to linux/syscalls.h
mn10300: switch to generic fork/vfork/clone
h8300: switch to generic fork/vfork/clone
tile: switch to generic clone()
...
Conflicts:
arch/microblaze/include/asm/Kbuild
Diffstat (limited to 'arch/h8300/include')
-rw-r--r-- | arch/h8300/include/asm/processor.h | 2 | ||||
-rw-r--r-- | arch/h8300/include/asm/ptrace.h | 3 | ||||
-rw-r--r-- | arch/h8300/include/asm/signal.h | 2 | ||||
-rw-r--r-- | arch/h8300/include/asm/unistd.h | 4 |
4 files changed, 7 insertions, 4 deletions
diff --git a/arch/h8300/include/asm/processor.h b/arch/h8300/include/asm/processor.h index 4c9f6f87b617..4b0ca49bb463 100644 --- a/arch/h8300/include/asm/processor.h +++ b/arch/h8300/include/asm/processor.h | |||
@@ -107,8 +107,6 @@ static inline void release_thread(struct task_struct *dead_task) | |||
107 | { | 107 | { |
108 | } | 108 | } |
109 | 109 | ||
110 | extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags); | ||
111 | |||
112 | /* | 110 | /* |
113 | * Free current thread data structures etc.. | 111 | * Free current thread data structures etc.. |
114 | */ | 112 | */ |
diff --git a/arch/h8300/include/asm/ptrace.h b/arch/h8300/include/asm/ptrace.h index d09c440bdba7..7468589a128b 100644 --- a/arch/h8300/include/asm/ptrace.h +++ b/arch/h8300/include/asm/ptrace.h | |||
@@ -60,6 +60,9 @@ struct pt_regs { | |||
60 | #define user_mode(regs) (!((regs)->ccr & PS_S)) | 60 | #define user_mode(regs) (!((regs)->ccr & PS_S)) |
61 | #define instruction_pointer(regs) ((regs)->pc) | 61 | #define instruction_pointer(regs) ((regs)->pc) |
62 | #define profile_pc(regs) instruction_pointer(regs) | 62 | #define profile_pc(regs) instruction_pointer(regs) |
63 | #define current_pt_regs() ((struct pt_regs *) \ | ||
64 | (THREAD_SIZE + (unsigned long)current_thread_info()) - 1) | ||
65 | #define signal_pt_regs() ((struct pt_regs *)current->thread.esp0) | ||
63 | #endif /* __KERNEL__ */ | 66 | #endif /* __KERNEL__ */ |
64 | #endif /* __ASSEMBLY__ */ | 67 | #endif /* __ASSEMBLY__ */ |
65 | #endif /* _H8300_PTRACE_H */ | 68 | #endif /* _H8300_PTRACE_H */ |
diff --git a/arch/h8300/include/asm/signal.h b/arch/h8300/include/asm/signal.h index fd8b66e40dca..c43c0a7d2c2e 100644 --- a/arch/h8300/include/asm/signal.h +++ b/arch/h8300/include/asm/signal.h | |||
@@ -154,8 +154,6 @@ typedef struct sigaltstack { | |||
154 | #include <asm/sigcontext.h> | 154 | #include <asm/sigcontext.h> |
155 | #undef __HAVE_ARCH_SIG_BITOPS | 155 | #undef __HAVE_ARCH_SIG_BITOPS |
156 | 156 | ||
157 | #define ptrace_signal_deliver(regs, cookie) do { } while (0) | ||
158 | |||
159 | #endif /* __KERNEL__ */ | 157 | #endif /* __KERNEL__ */ |
160 | 158 | ||
161 | #endif /* _H8300_SIGNAL_H */ | 159 | #endif /* _H8300_SIGNAL_H */ |
diff --git a/arch/h8300/include/asm/unistd.h b/arch/h8300/include/asm/unistd.h index 5cd882801d79..c2c2f5c7d6bf 100644 --- a/arch/h8300/include/asm/unistd.h +++ b/arch/h8300/include/asm/unistd.h | |||
@@ -356,6 +356,10 @@ | |||
356 | #define __ARCH_WANT_SYS_SIGPROCMASK | 356 | #define __ARCH_WANT_SYS_SIGPROCMASK |
357 | #define __ARCH_WANT_SYS_RT_SIGACTION | 357 | #define __ARCH_WANT_SYS_RT_SIGACTION |
358 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND | 358 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND |
359 | #define __ARCH_WANT_SYS_EXECVE | ||
360 | #define __ARCH_WANT_SYS_FORK | ||
361 | #define __ARCH_WANT_SYS_VFORK | ||
362 | #define __ARCH_WANT_SYS_CLONE | ||
359 | 363 | ||
360 | /* | 364 | /* |
361 | * "Conditional" syscalls | 365 | * "Conditional" syscalls |