esp-hal/esp32c6-hal/ld/bl-esp32c6-memory.x
Scott Mabin 9a5a546228
Unify linker scripts (#443)
* esp32 & esp32s2 sharing scripts

* add wokwi files

* Add fixup section for esp32s2, fix ordering of sectino includes

* Remove debug asm file

* Use shared linker scripts for s3 with fixups

* Add external.x sections back

* Move ld scripts into esp-hal-common

* esp32c3 unified linker scripts

- rework original c3 script to use the xtensa named sections
  (e.g, _SECTIONNAME_start)
- Add fixups in esp32c3 specific linker
- Remove useless text section start and end (not required when using any
  form of bootloader)

* Add RTC alias'. Move some shared fixups to a file

* comment and cleanup

* unify c2 linker script

* unify c6 linker script

* remove debug configs

* use new esp-riscv-rt

* fmt

* align db symbol names

* fix s3 db
2023-03-20 08:12:14 -07:00

38 lines
1.2 KiB
Plaintext

MEMORY
{
/* MEMORY_MAP = [
[0x00000000, 0x00010000, "PADDING"],
[0x42800000, 0x43000000, "DROM"],
[0x40800000, 0x40880000, "RAM"],
[0x40800000, 0x40880000, "BYTE_ACCESSIBLE"],
[0x4004AC00, 0x40050000, "DROM_MASK"],
[0x40000000, 0x4004AC00, "ROM_MASK"],
[0x42000000, 0x42800000, "ROM"],
[0x40800000, 0x40880000, "RAM"],
[0x50000000, 0x50004000, "RTC_RAM"],
[0x50000000, 0x50004000, "RTC_RAM"],
[0x600FE000, 0x60100000, "MEM_INTERNAL2"],
] */
/* 512K of on soc RAM, 32K reserved for cache */
ICACHE : ORIGIN = 0x40800000, LENGTH = 32K
/* Instruction and Data RAM */
RAM : ORIGIN = 0x40800000 + 32K, LENGTH = 512K - 32K
/* External flash */
/* Instruction and Data ROM */
ROM : ORIGIN = 0x42000000 + 0x20, LENGTH = 0x400000 - 0x20
/* RTC fast memory (executable). Persists over deep sleep. */
RTC_FAST : ORIGIN = 0x50000000, LENGTH = 16K /*- ESP_BOOTLOADER_RESERVE_RTC*/
}
REGION_ALIAS("ROTEXT", ROM);
REGION_ALIAS("RODATA", ROM);
REGION_ALIAS("RWTEXT", RAM);
REGION_ALIAS("RWDATA", RAM);
REGION_ALIAS("RTC_FAST_RWTEXT", RTC_FAST);
REGION_ALIAS("RTC_FAST_RWDATA", RTC_FAST);