aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mn10300
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2015-04-15 16:53:55 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2015-04-15 16:53:55 -0400
commitfa2e5c073a355465a2a8c9a2fbecf404f9857c3a (patch)
tree771be75e5436031ad53649634dffa67f6667b083 /arch/mn10300
parente44740c1a94b5d39b093045920f543a7bc135584 (diff)
parent97b2f0dc331474fb80ba4f4e4aee1d8e9ffbf7ce (diff)
Merge branch 'exec_domain_rip_v2' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/misc
Pull exec domain removal from Richard Weinberger: "This series removes execution domain support from Linux. The idea behind exec domains was to support different ABIs. The feature was never complete nor stable. Let's rip it out and make the kernel signal handling code less complicated" * 'exec_domain_rip_v2' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/misc: (27 commits) arm64: Removed unused variable sparc: Fix execution domain removal Remove rest of exec domains. arch: Remove exec_domain from remaining archs arc: Remove signal translation and exec_domain xtensa: Remove signal translation and exec_domain xtensa: Autogenerate offsets in struct thread_info x86: Remove signal translation and exec_domain unicore32: Remove signal translation and exec_domain um: Remove signal translation and exec_domain tile: Remove signal translation and exec_domain sparc: Remove signal translation and exec_domain sh: Remove signal translation and exec_domain s390: Remove signal translation and exec_domain mn10300: Remove signal translation and exec_domain microblaze: Remove signal translation and exec_domain m68k: Remove signal translation and exec_domain m32r: Remove signal translation and exec_domain m32r: Autogenerate offsets in struct thread_info frv: Remove signal translation and exec_domain ...
Diffstat (limited to 'arch/mn10300')
-rw-r--r--arch/mn10300/include/asm/thread_info.h2
-rw-r--r--arch/mn10300/kernel/asm-offsets.c2
-rw-r--r--arch/mn10300/kernel/signal.c20
3 files changed, 4 insertions, 20 deletions
diff --git a/arch/mn10300/include/asm/thread_info.h b/arch/mn10300/include/asm/thread_info.h
index c1c374f0ec12..4861a78c7160 100644
--- a/arch/mn10300/include/asm/thread_info.h
+++ b/arch/mn10300/include/asm/thread_info.h
@@ -40,7 +40,6 @@ typedef struct {
40 40
41struct thread_info { 41struct thread_info {
42 struct task_struct *task; /* main task structure */ 42 struct task_struct *task; /* main task structure */
43 struct exec_domain *exec_domain; /* execution domain */
44 struct pt_regs *frame; /* current exception frame */ 43 struct pt_regs *frame; /* current exception frame */
45 unsigned long flags; /* low level flags */ 44 unsigned long flags; /* low level flags */
46 __u32 cpu; /* current CPU */ 45 __u32 cpu; /* current CPU */
@@ -74,7 +73,6 @@ struct thread_info {
74#define INIT_THREAD_INFO(tsk) \ 73#define INIT_THREAD_INFO(tsk) \
75{ \ 74{ \
76 .task = &tsk, \ 75 .task = &tsk, \
77 .exec_domain = &default_exec_domain, \
78 .flags = 0, \ 76 .flags = 0, \
79 .cpu = 0, \ 77 .cpu = 0, \
80 .preempt_count = INIT_PREEMPT_COUNT, \ 78 .preempt_count = INIT_PREEMPT_COUNT, \
diff --git a/arch/mn10300/kernel/asm-offsets.c b/arch/mn10300/kernel/asm-offsets.c
index d780670cbaf3..e5a61c659b5a 100644
--- a/arch/mn10300/kernel/asm-offsets.c
+++ b/arch/mn10300/kernel/asm-offsets.c
@@ -22,7 +22,6 @@ void foo(void)
22 BLANK(); 22 BLANK();
23 23
24 OFFSET(TI_task, thread_info, task); 24 OFFSET(TI_task, thread_info, task);
25 OFFSET(TI_exec_domain, thread_info, exec_domain);
26 OFFSET(TI_frame, thread_info, frame); 25 OFFSET(TI_frame, thread_info, frame);
27 OFFSET(TI_flags, thread_info, flags); 26 OFFSET(TI_flags, thread_info, flags);
28 OFFSET(TI_cpu, thread_info, cpu); 27 OFFSET(TI_cpu, thread_info, cpu);
@@ -85,7 +84,6 @@ void foo(void)
85 DEFINE(SIGCHLD_asm, SIGCHLD); 84 DEFINE(SIGCHLD_asm, SIGCHLD);
86 BLANK(); 85 BLANK();
87 86
88 OFFSET(EXEC_DOMAIN_handler, exec_domain, handler);
89 OFFSET(RT_SIGFRAME_sigcontext, rt_sigframe, uc.uc_mcontext); 87 OFFSET(RT_SIGFRAME_sigcontext, rt_sigframe, uc.uc_mcontext);
90 88
91 DEFINE(PAGE_SIZE_asm, PAGE_SIZE); 89 DEFINE(PAGE_SIZE_asm, PAGE_SIZE);
diff --git a/arch/mn10300/kernel/signal.c b/arch/mn10300/kernel/signal.c
index 8609845f12c5..dfd0301cf200 100644
--- a/arch/mn10300/kernel/signal.c
+++ b/arch/mn10300/kernel/signal.c
@@ -202,20 +202,14 @@ static int setup_frame(struct ksignal *ksig, sigset_t *set,
202 struct pt_regs *regs) 202 struct pt_regs *regs)
203{ 203{
204 struct sigframe __user *frame; 204 struct sigframe __user *frame;
205 int rsig, sig = ksig->sig; 205 int sig = ksig->sig;
206 206
207 frame = get_sigframe(ksig, regs, sizeof(*frame)); 207 frame = get_sigframe(ksig, regs, sizeof(*frame));
208 208
209 if (!access_ok(VERIFY_WRITE, frame, sizeof(*frame))) 209 if (!access_ok(VERIFY_WRITE, frame, sizeof(*frame)))
210 return -EFAULT; 210 return -EFAULT;
211 211
212 rsig = sig; 212 if (__put_user(sig, &frame->sig) < 0 ||
213 if (sig < 32 &&
214 current_thread_info()->exec_domain &&
215 current_thread_info()->exec_domain->signal_invmap)
216 rsig = current_thread_info()->exec_domain->signal_invmap[sig];
217
218 if (__put_user(rsig, &frame->sig) < 0 ||
219 __put_user(&frame->sc, &frame->psc) < 0) 213 __put_user(&frame->sc, &frame->psc) < 0)
220 return -EFAULT; 214 return -EFAULT;
221 215
@@ -270,20 +264,14 @@ static int setup_rt_frame(struct ksignal *ksig, sigset_t *set,
270 struct pt_regs *regs) 264 struct pt_regs *regs)
271{ 265{
272 struct rt_sigframe __user *frame; 266 struct rt_sigframe __user *frame;
273 int rsig, sig = ksig->sig; 267 int sig = ksig->sig;
274 268
275 frame = get_sigframe(ksig, regs, sizeof(*frame)); 269 frame = get_sigframe(ksig, regs, sizeof(*frame));
276 270
277 if (!access_ok(VERIFY_WRITE, frame, sizeof(*frame))) 271 if (!access_ok(VERIFY_WRITE, frame, sizeof(*frame)))
278 return -EFAULT; 272 return -EFAULT;
279 273
280 rsig = sig; 274 if (__put_user(sig, &frame->sig) ||
281 if (sig < 32 &&
282 current_thread_info()->exec_domain &&
283 current_thread_info()->exec_domain->signal_invmap)
284 rsig = current_thread_info()->exec_domain->signal_invmap[sig];
285
286 if (__put_user(rsig, &frame->sig) ||
287 __put_user(&frame->info, &frame->pinfo) || 275 __put_user(&frame->info, &frame->pinfo) ||
288 __put_user(&frame->uc, &frame->puc) || 276 __put_user(&frame->uc, &frame->puc) ||
289 copy_siginfo_to_user(&frame->info, &ksig->info)) 277 copy_siginfo_to_user(&frame->info, &ksig->info))