File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -7,14 +7,14 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
7
7
8
8
## [ Unreleased]
9
9
10
- ## [ v0.7.3]
11
-
12
10
- Fixed a potential miscompilation caused by the initial stack pointer
13
11
not being 8-byte aligned. This issue affected 0.7.1 and 0.7.2; for
14
12
more details please see [ the advisory] ([ #467 ] ).
15
13
- A linker error is generated if the initial stack pointer is not 8-byte aligned ([ #464 ] ).
16
14
- The initial stack pointer is now forced to be 8-byte aligned in the linker script,
17
15
to defend against it being overridden outside of the cortex-m-rt linker script ([ #465 ] ).
16
+ - Add ` zero-init-ram ` feature to initialize RAM with zeros on startup. This can be necessary on
17
+ safety-critical hardware to properly initialize memory integrity measures.
18
18
19
19
[ the advisory ] : https://github.com/rust-embedded/cortex-m/discussions/469
20
20
[ #464 ] : https://github.com/rust-embedded/cortex-m/issues/464
Original file line number Diff line number Diff line change @@ -63,6 +63,8 @@ main() {
63
63
64
64
cargo rustc --target " $TARGET " --example minimal --features " set-sp,${needed_features} " -- $linker
65
65
cargo rustc --target " $TARGET " --example minimal --features " set-sp,${needed_features} " --release -- $linker
66
+ cargo rustc --target " $TARGET " --example minimal --features " zero-init-ram,${needed_features} " -- $linker
67
+ cargo rustc --target " $TARGET " --example minimal --features " zero-init-ram,${needed_features} " --release -- $linker
66
68
cargo rustc --target " $TARGET " --example minimal --features " set-vtor,${needed_features} " -- $linker
67
69
cargo rustc --target " $TARGET " --example minimal --features " set-vtor,${needed_features} " --release -- $linker
68
70
done
Original file line number Diff line number Diff line change 169
169
//! `_stack_start` value from the linker script. This is not usually required, but some debuggers
170
170
//! do not initialise SP when performing a soft reset, which can lead to stack corruption.
171
171
//!
172
+ //! ## `zero-init-ram`
173
+ //!
174
+ //! If this feature is enabled, RAM is initialized with zeros during startup from the `_ram_start`
175
+ //! value to the `_ram_end` value from the linker script. This is not usually required, but might be
176
+ //! necessary to properly initialize checksum-based memory integrity measures on safety-critical
177
+ //! hardware.
178
+ //!
172
179
//! ## `set-vtor`
173
180
//!
174
181
//! If this feature is enabled, the vector table offset register (VTOR) is initialised in the reset
You can’t perform that action at this time.
0 commit comments