Skip to content

Commit 8272622

Browse files
committed
[zep noup] platform: Include TFM_BSS in zero table for link script templates
While the copy table included the default data segment for these templates, the zero table didn't include the default bss segment. Make sure that area gets initialized to zero using the table-based mechanism instead of relying on the startup code to initialize it explicitly. Signed-off-by: Keith Packard <[email protected]>
1 parent 1abf0ea commit 8272622

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

platform/ext/common/gcc/tfm_common_s.ld.template

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,9 @@ SECTIONS
268268
/* .zero.table */
269269
. = ALIGN(4);
270270
__zero_table_start__ = .;
271+
LONG (ADDR(.TFM_BSS))
272+
LONG (SIZEOF(.TFM_BSS) / 4)
273+
271274
LONG (ADDR(.TFM_PSA_ROT_LINKER_BSS))
272275
LONG (SIZEOF(.TFM_PSA_ROT_LINKER_BSS) / 4)
273276

platform/ext/common/gcc/tfm_isolation_s.ld.template

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,9 @@ SECTIONS
256256
/* .zero.table */
257257
. = ALIGN(4);
258258
__zero_table_start__ = .;
259+
LONG (ADDR(.TFM_BSS))
260+
LONG (SIZEOF(.TFM_BSS) / 4)
261+
259262
{% for partition in partitions %}
260263
LONG (ADDR(.ER_{{partition.manifest.name}}_BSS))
261264
LONG (SIZEOF(.ER_{{partition.manifest.name}}_BSS) / 4)

0 commit comments

Comments
 (0)