Skip to content

Commit

Permalink
Bluetooth: fix BSS placement in the linker script generated by ldgen
Browse files Browse the repository at this point in the history
  • Loading branch information
o-marshmallow committed Nov 8, 2022
1 parent 166effd commit d4070f7
Showing 1 changed file with 17 additions and 9 deletions.
26 changes: 17 additions & 9 deletions components/bt/linker.lf
Original file line number Diff line number Diff line change
@@ -1,16 +1,21 @@
[sections:bss_common]
[sections:bt_bss]
entries:
.bss+

[sections:bt_common]
entries:
COMMON

[scheme:bt_start_end]
entries:
bss_common -> dram0_bss
bt_bss -> dram0_bss
bt_common -> dram0_bss
data -> dram0_data

# For the following fragments, order matters for
# 'ALIGN(4, post) SURROUND(sym)', which generates:
# 'ALIGN(4) ALIGN(4, post) SURROUND(sym)', which generates:
#
# . = ALIGN(4)
# _sym_start
# ...
# . = ALIGN(4)
Expand All @@ -20,21 +25,24 @@ entries:
archive: libbt.a
entries:
* (bt_start_end);
bss_common -> dram0_bss ALIGN(4, post) SURROUND(bt_bss),
data -> dram0_data ALIGN(4, post) SURROUND(bt_data)
bt_bss -> dram0_bss ALIGN(4) ALIGN(4, post) SURROUND(bt_bss),
bt_common -> dram0_bss ALIGN(4) ALIGN(4, post) SURROUND(bt_common),
data -> dram0_data ALIGN(4) ALIGN(4, post) SURROUND(bt_data)
if ESP_ALLOW_BSS_SEG_EXTERNAL_MEMORY = y:
* (extram_bss)

[mapping:btdm]
archive: libbtdm_app.a
entries:
* (bt_start_end);
bss_common -> dram0_bss ALIGN(4, post) SURROUND(btdm_bss),
data -> dram0_data ALIGN(4, post) SURROUND(btdm_data)
bt_bss -> dram0_bss ALIGN(4) ALIGN(4, post) SURROUND(btdm_bss),
bt_common -> dram0_bss ALIGN(4) ALIGN(4, post) SURROUND(btdm_common),
data -> dram0_data ALIGN(4) ALIGN(4, post) SURROUND(btdm_data)

[mapping:nimble]
archive: libnimble.a
entries:
* (bt_start_end);
bss_common -> dram0_bss ALIGN(4, post) SURROUND(nimble_bss),
data -> dram0_data ALIGN(4, post) SURROUND(nimble_data)
bt_bss -> dram0_bss ALIGN(4) ALIGN(4, post) SURROUND(nimble_bss),
bt_common -> dram0_bss ALIGN(4) ALIGN(4, post) SURROUND(nimble_common),
data -> dram0_data ALIGN(4) ALIGN(4, post) SURROUND(nimble_data)

0 comments on commit d4070f7

Please sign in to comment.