nuttx/arch/sim
Ricard Rosson 0a7171bc62 arch: fall back to the kernel heap when there is no separate text heap
When an architecture does not provide a separate text heap
(CONFIG_ARCH_USE_TEXT_HEAP is not selected), redirect the text heap
API to the normal kernel heap in include/nuttx/arch.h.  On
flat-memory architectures the kernel heap is executable, so code
written against the portable API (up_textheap_memalign() and
friends) now works on every such port without per-arch stubs that
just wrap kmm_memalign().  Suggested by review on the previous
revision of this change, which added exactly such a stub for rp23xx.

up_textheap_data_address() and up_textheap_data_sync() identity
fallbacks become available unconditionally as well.

Gate the sim implementation on CONFIG_ARCH_USE_TEXT_HEAP: it was
compiled unconditionally (harmless before, but it would now collide
with the fallback macros), matching how every other implementation
is already gated in its Make.defs/CMakeLists.

Assisted-by: Claude (Anthropic Claude Code)
Signed-off-by: Ricard Rosson <ricard@groundbits.com>
2026-07-24 07:48:17 +01:00
..
include arch/sim: replace macOS C++ constructor runtime hack with post-link patch 2026-05-19 07:08:55 -03:00
src arch: fall back to the kernel heap when there is no separate text heap 2026-07-24 07:48:17 +01:00
CMakeLists.txt arch:use ARCH_64BIT to mark arch is support 64bit 2025-12-18 22:05:12 +08:00
Kconfig sim: adapt macos avfoundation backend for camera indexing and capture 2026-05-08 19:51:39 +08:00