diff options
author | Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> | 2014-01-08 06:15:05 -0500 |
---|---|---|
committer | Stafford Horne <shorne@gmail.com> | 2017-02-06 07:50:42 -0500 |
commit | c2dc72437a5504bf8f4343ed83ae745afa388522 (patch) | |
tree | 11eb79d738234211ddfa684758b5c0ca6f672a36 /arch/openrisc | |
parent | 742fb582b4540a7b59427dc67be1fe4a5eac7078 (diff) |
openrisc: head: use THREAD_SIZE instead of magic constant
The stack size was hard coded to 0x2000, use the standard THREAD_SIZE
definition loaded from thread_info.h.
Signed-off-by: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
[shorne@gmail.com: Added body to the commit message]
Signed-off-by: Stafford Horne <shorne@gmail.com>
Diffstat (limited to 'arch/openrisc')
-rw-r--r-- | arch/openrisc/kernel/head.S | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/openrisc/kernel/head.S b/arch/openrisc/kernel/head.S index 2346c5b39095..63ba2d96a860 100644 --- a/arch/openrisc/kernel/head.S +++ b/arch/openrisc/kernel/head.S | |||
@@ -24,6 +24,7 @@ | |||
24 | #include <asm/page.h> | 24 | #include <asm/page.h> |
25 | #include <asm/mmu.h> | 25 | #include <asm/mmu.h> |
26 | #include <asm/pgtable.h> | 26 | #include <asm/pgtable.h> |
27 | #include <asm/thread_info.h> | ||
27 | #include <asm/cache.h> | 28 | #include <asm/cache.h> |
28 | #include <asm/spr_defs.h> | 29 | #include <asm/spr_defs.h> |
29 | #include <asm/asm-offsets.h> | 30 | #include <asm/asm-offsets.h> |
@@ -486,7 +487,8 @@ _start: | |||
486 | /* | 487 | /* |
487 | * set up initial ksp and current | 488 | * set up initial ksp and current |
488 | */ | 489 | */ |
489 | LOAD_SYMBOL_2_GPR(r1,init_thread_union+0x2000) // setup kernel stack | 490 | /* setup kernel stack */ |
491 | LOAD_SYMBOL_2_GPR(r1,init_thread_union + THREAD_SIZE) | ||
490 | LOAD_SYMBOL_2_GPR(r10,init_thread_union) // setup current | 492 | LOAD_SYMBOL_2_GPR(r10,init_thread_union) // setup current |
491 | tophys (r31,r10) | 493 | tophys (r31,r10) |
492 | l.sw TI_KSP(r31), r1 | 494 | l.sw TI_KSP(r31), r1 |