aboutsummaryrefslogtreecommitdiffstats
path: root/arch/i386
diff options
context:
space:
mode:
Diffstat (limited to 'arch/i386')
-rw-r--r--arch/i386/kernel/entry.S13
-rw-r--r--arch/i386/kernel/process.c9
2 files changed, 13 insertions, 9 deletions
diff --git a/arch/i386/kernel/entry.S b/arch/i386/kernel/entry.S
index ba22ec8fab5..dede506e5bd 100644
--- a/arch/i386/kernel/entry.S
+++ b/arch/i386/kernel/entry.S
@@ -950,6 +950,19 @@ ENTRY(arch_unwind_init_running)
950ENDPROC(arch_unwind_init_running) 950ENDPROC(arch_unwind_init_running)
951#endif 951#endif
952 952
953ENTRY(kernel_thread_helper)
954 pushl $0 # fake return address for unwinder
955 CFI_STARTPROC
956 movl %edx,%eax
957 push %edx
958 CFI_ADJUST_CFA_OFFSET 4
959 call *%ebx
960 push %eax
961 CFI_ADJUST_CFA_OFFSET 4
962 call do_exit
963 CFI_ENDPROC
964ENDPROC(kernel_thread_helper)
965
953.section .rodata,"a" 966.section .rodata,"a"
954#include "syscall_table.S" 967#include "syscall_table.S"
955 968
diff --git a/arch/i386/kernel/process.c b/arch/i386/kernel/process.c
index b741c3e1a5e..220aeca59c3 100644
--- a/arch/i386/kernel/process.c
+++ b/arch/i386/kernel/process.c
@@ -321,15 +321,6 @@ void show_regs(struct pt_regs * regs)
321 * the "args". 321 * the "args".
322 */ 322 */
323extern void kernel_thread_helper(void); 323extern void kernel_thread_helper(void);
324__asm__(".section .text\n"
325 ".align 4\n"
326 "kernel_thread_helper:\n\t"
327 "movl %edx,%eax\n\t"
328 "pushl %edx\n\t"
329 "call *%ebx\n\t"
330 "pushl %eax\n\t"
331 "call do_exit\n"
332 ".previous");
333 324
334/* 325/*
335 * Create a kernel thread 326 * Create a kernel thread