aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sh')
-rw-r--r--arch/sh/include/asm/processor_32.h3
-rw-r--r--arch/sh/include/asm/processor_64.h1
-rw-r--r--arch/sh/kernel/process.c7
-rw-r--r--arch/sh/kernel/process_32.c9
4 files changed, 7 insertions, 13 deletions
diff --git a/arch/sh/include/asm/processor_32.h b/arch/sh/include/asm/processor_32.h
index 900f8d72ffe2..b6311fd2d066 100644
--- a/arch/sh/include/asm/processor_32.h
+++ b/arch/sh/include/asm/processor_32.h
@@ -126,9 +126,6 @@ extern void start_thread(struct pt_regs *regs, unsigned long new_pc, unsigned lo
126/* Free all resources held by a thread. */ 126/* Free all resources held by a thread. */
127extern void release_thread(struct task_struct *); 127extern void release_thread(struct task_struct *);
128 128
129/* Prepare to copy thread state - unlazy all lazy status */
130void prepare_to_copy(struct task_struct *tsk);
131
132/* 129/*
133 * create a kernel thread without removing it from tasklists 130 * create a kernel thread without removing it from tasklists
134 */ 131 */
diff --git a/arch/sh/include/asm/processor_64.h b/arch/sh/include/asm/processor_64.h
index 740e26876596..cd6029fb2c01 100644
--- a/arch/sh/include/asm/processor_64.h
+++ b/arch/sh/include/asm/processor_64.h
@@ -169,7 +169,6 @@ extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags);
169#define copy_segments(p, mm) do { } while (0) 169#define copy_segments(p, mm) do { } while (0)
170#define release_segments(mm) do { } while (0) 170#define release_segments(mm) do { } while (0)
171#define forget_segments() do { } while (0) 171#define forget_segments() do { } while (0)
172#define prepare_to_copy(tsk) do { } while (0)
173/* 172/*
174 * FPU lazy state save handling. 173 * FPU lazy state save handling.
175 */ 174 */
diff --git a/arch/sh/kernel/process.c b/arch/sh/kernel/process.c
index e77feaf117ab..9b7a459a4613 100644
--- a/arch/sh/kernel/process.c
+++ b/arch/sh/kernel/process.c
@@ -13,8 +13,15 @@ unsigned long __stack_chk_guard __read_mostly;
13EXPORT_SYMBOL(__stack_chk_guard); 13EXPORT_SYMBOL(__stack_chk_guard);
14#endif 14#endif
15 15
16/*
17 * this gets called so that we can store lazy state into memory and copy the
18 * current task into the new thread.
19 */
16int arch_dup_task_struct(struct task_struct *dst, struct task_struct *src) 20int arch_dup_task_struct(struct task_struct *dst, struct task_struct *src)
17{ 21{
22#ifdef CONFIG_SUPERH32
23 unlazy_fpu(src, task_pt_regs(src));
24#endif
18 *dst = *src; 25 *dst = *src;
19 26
20 if (src->thread.xstate) { 27 if (src->thread.xstate) {
diff --git a/arch/sh/kernel/process_32.c b/arch/sh/kernel/process_32.c
index f78cc421e665..59521e8a164d 100644
--- a/arch/sh/kernel/process_32.c
+++ b/arch/sh/kernel/process_32.c
@@ -156,15 +156,6 @@ int dump_fpu(struct pt_regs *regs, elf_fpregset_t *fpu)
156} 156}
157EXPORT_SYMBOL(dump_fpu); 157EXPORT_SYMBOL(dump_fpu);
158 158
159/*
160 * This gets called before we allocate a new thread and copy
161 * the current task into it.
162 */
163void prepare_to_copy(struct task_struct *tsk)
164{
165 unlazy_fpu(tsk, task_pt_regs(tsk));
166}
167
168asmlinkage void ret_from_fork(void); 159asmlinkage void ret_from_fork(void);
169 160
170int copy_thread(unsigned long clone_flags, unsigned long usp, 161int copy_thread(unsigned long clone_flags, unsigned long usp,