Commit Graph
486 Commits
Author SHA1 Message Date
Fu Hanxi d359f42f6d ci: apply idf-ci 1.x
(cherry picked from commit 21d772a24da646bfb672418cf056199cad9b17e4)
2026-07-27 10:52:35 +02:00
morris 8186da07ae Merge branch 'contrib/github_pr_18724_v5.5' into 'release/v5.5'
fix(heap_task_info): Fix incorrect current_usage subtraction on realloc() (GitHub PR) (v5.5)

See merge request espressif/esp-idf!50278
2026-07-21 10:36:48 +08:00
Jiang Jiang Jian cc5a3fbcb5 Merge branch 'feat/psram_enc_exempt_v5.5' into 'release/v5.5'
feat(esp_psram): add option to carve unencrypted PSRAM region (v5.5)

See merge request espressif/esp-idf!49931
2026-07-16 17:04:28 +08:00
wuzhenghui 31ce82f7d6 fix(esp_hw_support): update memory pointer checks for SPM support 2026-07-10 12:39:11 +08:00
wuzhenghui 1b3d83528b change(heap): reserve DMA pool with low priority MALLOC_CAP_DEFAULT caps 2026-07-09 17:33:25 +08:00
Renz Bagaporo b475fda9dc fix(heap): reset alloc_stat before realloc lookup
Closes https://github.com/espressif/esp-idf/issues/18723
Closes https://github.com/espressif/esp-idf/pull/18724
2026-07-02 10:00:35 +09:00
Ferdinand Bachmann ce82719ec1 fix(heap_task_info): Fix incorrect current_usage subtraction on realloc() 2026-07-02 10:00:34 +09:00
Renz Bagaporo a3c4103f3f ci(heap): add task tracking realloc handle reuse test 2026-07-02 10:00:34 +09:00
Mahavir Jain 0044542811 feat(esp_psram): add option to carve unencrypted PSRAM region
Adds CONFIG_SPIRAM_ENC_EXEMPT, available on chips that support per-page
PSRAM encryption configuration (esp32c5, esp32c61, esp32p4). When
enabled, esp_psram carves CONFIG_SPIRAM_ENC_EXEMPT_SIZE off the top of
PSRAM and maps it via the new mmu_hal_map_region_no_enc() helper, which
writes MMU entries without the SENSITIVE bit. The region is registered
as a separate heap pool reachable only through the new
MALLOC_CAP_SPIRAM_NO_ENC capability bit, so default SPIRAM allocations
cannot accidentally land there.

PSRAM encryption imposes alignment constraints that some DMA engines
(e.g. 2D-DMA) cannot satisfy. This option lets such workloads place
their buffers in unencrypted PSRAM while keeping the rest of PSRAM
(and flash) encrypted. Default disabled; security implications are
documented in the Kconfig help text.
2026-06-23 14:56:38 +05:30
Guillaume Souchere 6e9a100475 fix(heap): Remove unused variable in test_malloc_caps.c 2026-06-02 08:37:57 +02:00
Guillaume Souchere fdf45116eb fix(esp_rom): Set poison check hook for tlsf_walk_pool patch 2026-06-02 08:37:24 +02:00
Guillaume Souchere 41ea1c562f fix(heap): Do not consider newly registered heap in minimum free size calcualtion
After startup is done and app_main is reached, all calls to
heap_caps_add_region_with_caps (adding a new heap to the list of registered
heaps) will not affect the minimum free heap size value.

For heaps created before startup, this won't apply and their size will
end up being taken into account in the calculation of the minimum.
2026-05-29 07:57:09 +02:00
armando 0cb42beabf fix(spm): rename scp (scratchpad) to spm (scratchpad memory) 2026-03-31 09:24:53 +08:00
armando 55c462ccab change(mem): deprecated tcm and added scp memory utils 2026-03-31 09:22:11 +08:00
Alexey Lapshin 0b3929d0d9 feat(esp_libc): add full support for picolibc 2026-01-30 23:39:53 +07:00
Jiang Jiang Jian e2cc50cb46 Merge branch 'fix/task_tracing_crashing_5.5' into 'release/v5.5'
fix(heap): fix a bug where the biggest heap would be NULL on boot (backport v5.5)

See merge request espressif/esp-idf!43448
2026-01-19 11:11:38 +08:00
Omar Chebib 8db6882503 fix(heap): fix a bug where the biggest heap would be NULL on boot
Closes https://github.com/espressif/esp-idf/issues/17232
2026-01-16 14:26:26 +08:00
wuzhenghui 67a62f45ce fix(esp_system): fix rom secure boot fast wake feature for c5/c6/h2/h21 2026-01-12 18:11:59 +08:00
wuzhenghui 3ee348fe52 fix(esp_hw_support): add p4 rev3.0 MSPI workaround for deepsleep 2025-10-30 19:09:44 +08:00
wuzhenghui 9413361f82 change(esp_hw_support): allocate memory with MALLOC_CAP_RETENTION for regdma link 2025-10-20 17:18:20 +08:00
Mahavir Jain ea36c4f609 Merge branch 'feature/esp_tee_c5_v5.5' into 'release/v5.5'
feat(esp_tee): Initial support for ESP32-C5 and related changes (v5.5)

See merge request espressif/esp-idf!42357
2025-10-16 09:39:23 +05:30
Laukik Hase 508a659001 feat(esp_tee): Support for ESP32-C5 - the rest of the components 2025-10-14 10:12:11 +05:30
armando e6d4eec507 feat(p4): p4 rev3 real chip support 2025-10-13 15:25:23 +08:00
Laukik Hase 27496e47f0 feat(esp_tee): Support for ESP32-H2 - the rest of the components 2025-05-21 10:06:17 +05:30
Guillaume Souchere 83f28973be Merge branch 'docs/document-task-tracking' into 'master'
docs(heap): Document heap task tracking

Closes IDF-12684

See merge request espressif/esp-idf!38247
2025-04-30 16:27:36 +08:00
Guillaume Souchere 0627576982 docs(heap): Document heap task tracking
Populate the heap_debug.rst section on heap task tracking with the
description of the reworked task tracking.
2025-04-29 10:11:58 +02:00
Marius Vikhammer 4ea1facb42 Merge branch 'feature/esp32h21_core_support' into 'master'
feat(esp32h21): added support for misc core system features

Closes IDF-12042, IDF-11598, IDF-11596, IDF-11874, IDF-11873, IDF-11528, and IDF-11511

See merge request espressif/esp-idf!38773
2025-04-29 14:53:52 +08:00
Marius Vikhammer 1256078ea2 feat(esp32h21): added support for misc core system features 2025-04-28 11:42:25 +08:00
Guillaume Souchere 8a987d9288 feat(heap): Update get allocated size function to take any pointer 2025-04-25 09:50:15 +02:00
Guillaume Souchere 76f777c0e5 feat(heap): Update to latest TLSF
- this new version of TLSF uses uintptr_t instead of unsigned int
  casting in tlsf_malloc_addr to allow proper use of the function
  on 64bit targets.
2025-04-08 10:51:11 +02:00
Marius Vikhammer 97ae78e1f1 test(heap): fixed align_alloc issues in host test 2025-04-02 11:40:34 +08:00
Chen Jichang c34b4eb882 feat(esp32h4): enable ESP32H4 ci build 2025-03-28 14:41:28 +08:00
Guillaume Souchere 6ef7ad67d4 Merge branch 'feat/per-task-peak-usage' into 'master'
feat(heap): Add per task peak heap usage feature

Closes IDF-1811 and IDFGH-11277

See merge request espressif/esp-idf!26462
2025-03-26 15:20:04 +08:00
Guillaume Souchere d429b1fdbb feat(examples): Update heap task tracking examples
update example to showcasee the new API of heap task tracking

- Add basic heap task traacking example
- Add advanced example for task tracking
2025-03-25 10:22:30 +01:00
Guillaume Souchere daf8f9edb6 feat(heap): Add feature to get peak heap usage
This feature keeps track of the per task peak memory usage.

- Update the heap_task_tracking example to make use of the new feature
Cleanup the implementation:
- multi_heap_get_free_size() is never used, remove it.
- Minor update in heap_caps_update_per_task_info_xx() funcitons.
- Update settting on block owner in heap_caps.c to work with the
get peak usage feature.

- Update heap_caps_update_per_task_info_free() to detect when it
is called to delete the memory allocated for a task TCB. Mark
the corresponding task in the statistic list as deleted.

- Add a Kconfig option dependant on HEAP_TASK_TRACKING being enabled
that force the deletion of the statistics related to deleted task
when set to true.

- In task tracking feature, add a current and peak memory usage
to the heap_stat_t structure to keep track of the current and
peak memory usage of the given task across all heaps.

- Fix missing block owner when allocating memory for heaps_array
in heap_caps_init.

- Keep the original implementation of the task tracking
for backward compatibility reasons.
2025-03-24 12:08:48 +01:00
Chen Jichang 45ba78940f feat(esp32h4): finnal introduce hello world 2025-03-19 18:48:41 +08:00
Guillaume Souchere 063d673fae Merge branch 'fix/memory-utils-esp_ptr_in_rtc_dram_fast' into 'master'
fix(esp_hw_support): esp_ptr_in_rtc_iram_fast check to return false

Closes IDFCI-2717

See merge request espressif/esp-idf!36930
2025-03-13 20:05:46 +08:00
Marius Vikhammer ad88bd184f fix(heap): fixed HEAP_PLACE_FUNCTION_INTO_FLASH disabled if heap impl in ROM 2025-03-12 10:52:07 +08:00
Guillaume Souchere 8c50df00ff fix(esp_hw_support): esp_ptr_in_rtc_iram_fast check to return false
esp_ptr_in_rtc_iram_fast logic should be executed if
SOC_RTC_FAST_MEM_SUPPORTED is set but it should also be executed
if IRAM and DRAM region mapping is the same. Remove the
SOC_RTC_IRAM_LOW != SOC_RTC_DRAM_LOW part of the check.

Update heap component to use the modify function appropriately.
2025-03-11 12:06:32 +01:00
igor.udot daf2d31008 test: format all test scripts 2025-03-05 12:08:48 +08:00
Chen Ji Chang 9342b3fba1 Merge branch 'feat/h4_introduce_step1_add_target' into 'master'
feat(esp32h4): introduce target esp32h4(stage 1)

See merge request espressif/esp-idf!36780
2025-02-11 18:11:08 +08:00
Chen Jichang 6f83f39dce feat(esp32h4): introduce target esp32h4(stage 1) 2025-02-08 17:07:44 +08:00
gaoxu 5ef4f20778 feat(esp32h21): disable unsupported build test 2025-02-06 15:47:51 +08:00
Song Ruo Jing 20eb6ca5e9 feat(heap): add a MALLOC_CAP_SIMD flag
MALLOC_CAP_SIMD can be used to allocate memory to be used for SIMD instructions
2025-01-16 14:39:12 +08:00
Omar Chebib d6cd339e46 fix: take into account MR comments 2025-01-09 11:57:02 +08:00
Omar Chebib 1e0cdcbd13 feat(heap): enable heap tracing for the RISC-V targets
When the frame pointer is enabled, it is possible for RISC-V targets to now
possible to enable and generate heap call traces.
2025-01-09 11:57:02 +08:00
gaoxu 25731d0c1e feat(esp32h21): finnal introduce hello world support 2024-12-30 20:14:40 +08:00
Marius Vikhammer 34c7d62855 refactor(hw_support): combine esp_hw_support rtc header to a single file 2024-12-30 10:09:34 +08:00
Guillaume Souchere a995a5339b fix(heap): MALLOC_CAP_EXEC does not allocate in RTC IRAM
This commit fixes the issue when trying to allocate memory
with the MALLOC_CAP_EXEC in RTC memory. Prior to the fix,
the heap allocator was returning an address in RTC DRAM.

To fix this issue:
- modified memory_layout.c of the concerned targets to fill the iram_address
field in the rtc entry of the soc_memory_region array properly.
- modified heap component  related functions to return IRAM address when
an allocation in RTC memory with MALLOC_CAP_EXEC is requested.

Closes https://github.com/espressif/esp-idf/issues/14835
2024-12-09 09:34:56 +01:00
Laukik Hase 733741bbac feat(esp_tee): Support for ESP-TEE - esp_system component 2024-12-02 12:20:04 +05:30