9da9d3ea8c
Set sh_addr for regions that are not allocated. Some relocations might depend on this. The fault in my case occurs when setting CONFIG_HAVE_CXX=y. In this case, the .ctor and .dtor sections do not get allocated, but the crt code depends on linker defined symbols _sctors/_ectors etc. These generate PC relative relocations and thus, the .ctor and .dtor output sections need an output VMA even though nothing is there. Otherwise the relocations will point to god knows where (in my case to address 0). The problem results in full system crash later: elf_symvalue: Other: 00000000+00000001=00000001 up_relocateadd: PCREL_HI20 at c00002dc [00000417] to sym=0x80409e80 st_value=1 _calc_imm: offset=-3221226203: hi=-786432 lo=-731 up_relocateadd: ERROR: PCREL_HI20 at c00002dc bad:ffffffff40000000 elf_relocateadd: ERROR: Section 2 reloc 52: Relocation failed: -22 The RISC-V elf64 linker does not like the uninitialized PC relative relocation entries, as the relocation offset cannot be reached with with the RV64 instruction set. More about this issue can be found here: https://github.com/apache/nuttx/pull/11322 |
||
---|---|---|
.github | ||
arch | ||
audio | ||
binfmt | ||
boards | ||
cmake | ||
crypto | ||
Documentation | ||
drivers | ||
dummy | ||
fs | ||
graphics | ||
include | ||
libs | ||
mm | ||
net | ||
openamp | ||
pass1 | ||
sched | ||
syscall | ||
tools | ||
video | ||
wireless | ||
.asf.yaml | ||
.gitignore | ||
.yamllint | ||
AUTHORS | ||
CMakeLists.txt | ||
CONTRIBUTING.md | ||
INVIOLABLES.md | ||
Kconfig | ||
LICENSE | ||
Makefile | ||
NOTICE | ||
README.md | ||
ReleaseNotes |
Apache NuttX is a real-time operating system (RTOS) with an emphasis on standards compliance and small footprint. Scalable from 8-bit to 64-bit microcontroller environments, the primary governing standards in NuttX are POSIX and ANSI standards. Additional standard APIs from Unix and other common RTOSs (such as VxWorks) are adopted for functionality not available under these standards, or for functionality that is not appropriate for deeply-embedded environments (such as fork()).
For brevity, many parts of the documentation will refer to Apache NuttX as simply NuttX.
Getting Started
First time on NuttX? Read the Getting Started guide! If you don't have a board available, NuttX has its own simulator that you can run on terminal.
Documentation
You can find the current NuttX documentation on the Documentation Page.
Alternatively, you can build the documentation yourself by following the Documentation Build Instructions.
The old NuttX documentation is still available in the Apache wiki.
Supported Boards
NuttX supports a wide variety of platforms. See the full list on the Supported Platforms page.
Contributing
If you wish to contribute to the NuttX project, read the Contributing guidelines for information on Git usage, coding standard, workflow and the NuttX principles.
License
The code in this repository is under either the Apache 2 license, or a license compatible with the Apache 2 license. See the License Page for more information.