Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 153741
b: refs/heads/master
c: feb97c3
h: refs/heads/master
i:
  153739: 1fb5655
v: v3
  • Loading branch information
Catalin Marinas authored and Russell King committed Jun 19, 2009
1 parent 2653b59 commit 6bf37e3
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c894ed6956f126d60d888e8efc5fb3a595ba89ae
refs/heads/master: feb97c3644a560ffdf9a17c65b1df807b5b4432f
19 changes: 18 additions & 1 deletion trunk/arch/arm/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,23 @@ asm( ".section .text\n"
" .size kernel_thread_helper, . - kernel_thread_helper\n"
" .previous");

#ifdef CONFIG_ARM_UNWIND
extern void kernel_thread_exit(long code);
asm( ".section .text\n"
" .align\n"
" .type kernel_thread_exit, #function\n"
"kernel_thread_exit:\n"
" .fnstart\n"
" .cantunwind\n"
" bl do_exit\n"
" nop\n"
" .fnend\n"
" .size kernel_thread_exit, . - kernel_thread_exit\n"
" .previous");
#else
#define kernel_thread_exit do_exit
#endif

/*
* Create a kernel thread.
*/
Expand All @@ -363,7 +380,7 @@ pid_t kernel_thread(int (*fn)(void *), void *arg, unsigned long flags)

regs.ARM_r1 = (unsigned long)arg;
regs.ARM_r2 = (unsigned long)fn;
regs.ARM_r3 = (unsigned long)do_exit;
regs.ARM_r3 = (unsigned long)kernel_thread_exit;
regs.ARM_pc = (unsigned long)kernel_thread_helper;
regs.ARM_cpsr = SVC_MODE | PSR_ENDSTATE;

Expand Down

0 comments on commit 6bf37e3

Please sign in to comment.