Skip to content

Commit e3ad93f

Browse files
committed
minor fixes
1 parent 2d2d997 commit e3ad93f

File tree

2 files changed

+12
-14
lines changed

2 files changed

+12
-14
lines changed

aarch32-rt/link.x

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,16 +84,14 @@ SECTIONS {
8484
{
8585
. = ALIGN(8);
8686
_stacks_low_end = .;
87-
_sys_stack_end = .;
87+
_sys_stack_end = .;
8888
. += _sys_stack_size;
8989
. = ALIGN(8);
9090
_sys_stack = .;
91-
. = ALIGN(8);
9291
_fiq_stack_end = .;
9392
. += _fiq_stack_size;
9493
. = ALIGN(8);
9594
_fiq_stack = .;
96-
. = ALIGN(8);
9795
_irq_stack_end = .;
9896
. += _irq_stack_size;
9997
. = ALIGN(8);
@@ -124,7 +122,7 @@ SECTIONS {
124122

125123
/* We provide default sizes for the stacks to be overwritten in memory.x */
126124
PROVIDE(_stack_top = _stacks_high_end); /* deprecated, use _xxx_stack labels as defined in .stacks section */
127-
PROVIDE(_hyp_stack_size = 0x401);
125+
PROVIDE(_hyp_stack_size = 0x400);
128126
PROVIDE(_und_stack_size = 0x400);
129127
PROVIDE(_svc_stack_size = 0x400);
130128
PROVIDE(_abt_stack_size = 0x400);

aarch32-rt/src/lib.rs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -452,8 +452,8 @@
452452
//! * `_default_handler` - a C compatible function that spins forever.
453453
//! * `_init_segments` - initialises `.bss` and `.data`
454454
//! * `_stack_setup` - initialises UND, SVC, ABT, IRQ, FIQ and SYS stacks from
455-
//! the address given in `r0`. Deprecated, use `stack_setup_prealloc` instead
456-
//! * `_stack_setup_prealloc` - initialises UND, SVC, ABT, IRQ, FIQ and SYS
455+
//! the address given in `r0`. Deprecated, use `_stack_setup_preallocated` instead
456+
//! * `_stack_setup_preallocated` - initialises UND, SVC, ABT, IRQ, FIQ and SYS
457457
//! stacks from the `.stacks` section defined in link.x, based on
458458
//! _xxx_stack_size values
459459
//! * `_xxx_stack` and `_xxx_stack_end` where the former is the top and the latter
@@ -754,7 +754,7 @@ macro_rules! fpu_enable {
754754
}
755755

756756
// Start-up code for Armv7-R (and Armv8-R once we've left EL2)
757-
// DEPRECATED: use _stack_setup_prealloc to use sections defined
757+
// DEPRECATED: use _stack_setup_preallocated to use sections defined
758758
// in linker script
759759
// We set up our stacks and `kmain` in system mode.
760760
#[cfg(target_arch = "arm")]
@@ -870,10 +870,10 @@ core::arch::global_asm!(
870870
871871
// Configure a stack for every mode. Leaves you in sys mode.
872872
//
873-
.section .text._stack_setup_prealloc
874-
.global _stack_setup_prealloc
875-
.type _stack_setup_prealloc, %function
876-
_stack_setup_prealloc:
873+
.section .text._stack_setup_preallocated
874+
.global _stack_setup_preallocated
875+
.type _stack_setup_preallocated, %function
876+
_stack_setup_preallocated:
877877
// Save LR from whatever mode we're currently in
878878
mov r2, lr
879879
// (we might not be in the same mode when we return).
@@ -902,7 +902,7 @@ core::arch::global_asm!(
902902
mcr p15, 0, r1, c1, c0, 0
903903
// return to caller
904904
bx r2
905-
.size _stack_setup_prealloc, . - _stack_setup_prealloc
905+
.size _stack_setup_preallocated, . - _stack_setup_preallocated
906906
907907
// Initialises stacks, .data and .bss
908908
.section .text._init_segments
@@ -999,7 +999,7 @@ core::arch::global_asm!(
999999
.type _default_start, %function
10001000
_default_start:
10011001
// Set up stacks.
1002-
bl _stack_setup_prealloc
1002+
bl _stack_setup_preallocated
10031003
// Init .data and .bss
10041004
bl _init_segments
10051005
"#,
@@ -1069,7 +1069,7 @@ core::arch::global_asm!(
10691069
eret
10701070
1:
10711071
// Set up stacks.
1072-
bl _stack_setup_prealloc
1072+
bl _stack_setup_preallocated
10731073
// Set the VBAR (for EL1) to _vector_table. NB: This isn't required on
10741074
// Armv7-R because that only supports 'low' (default) or 'high'.
10751075
ldr r0, =_vector_table

0 commit comments

Comments
 (0)