system: fixed USE_FIXED_STATIC_RAM_SIZE option

The USE_FIXED_STATIC_RAM_SIZE was not actually causing the heap to start
at a fixed address.

Closes https://github.com/espressif/esp-idf/issues/10270
Closes https://github.com/espressif/esp-idf/issues/10271
This commit is contained in:
Marius Vikhammer
2022-12-01 15:28:26 +08:00
parent c77b5752ef
commit 585f05596b
13 changed files with 34 additions and 85 deletions

View File

@@ -20,12 +20,8 @@
#define I_D_SRAM_SIZE SRAM_DRAM_END - SRAM_DRAM_ORG
#if CONFIG_ESP32C2_USE_FIXED_STATIC_RAM_SIZE
ASSERT((CONFIG_ESP32C2_FIXED_STATIC_RAM_SIZE <= I_D_SRAM_SIZE), "Fixed static ram data does not fit.")
#define DRAM0_0_SEG_LEN CONFIG_ESP32C2_FIXED_STATIC_RAM_SIZE
#else
#define DRAM0_0_SEG_LEN I_D_SRAM_SIZE
#endif // CONFIG_ESP32C2_USE_FIXED_STATIC_RAM_SIZE
MEMORY
{
/**
@@ -65,13 +61,6 @@ MEMORY
}
#if CONFIG_ESP32C2_USE_FIXED_STATIC_RAM_SIZE
/* static data ends at defined address */
_static_data_end = 0x3FCA0000 + DRAM0_0_SEG_LEN;
#else
_static_data_end = _bss_end;
#endif // CONFIG_ESP32C2_USE_FIXED_STATIC_RAM_SIZE
/* Heap ends at top of dram0_0_seg */
_heap_end = 0x40000000;