Commit Graph

1705 Commits

Author SHA1 Message Date
Masayuki Ishikawa df298c186f Revert "build depend:Revert Make.dep intermediate ddc file"
This reverts commit ddc3119c4e.
2024-09-15 19:29:47 +08:00
xuxin19 ddc3119c4e build depend:Revert Make.dep intermediate ddc file
Revert "Parallelize depend file generation"
This reverts commit d5b6ec450f.

parallel depend ddc does not significantly speed up compilation,
intermediately generated .ddc files can cause problems if compilation is interrupted unexpectedly

Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-09-15 10:01:58 +08:00
Alin Jerpelea c9eef2d697 tools: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-09-10 23:11:11 +08:00
shizhenghui d285e5bc31 Dockerfile: add subversion to final images
Add subversion to install list ensure linux docker
can use svn command to download source code.

Signed-off-by: shizhenghui <shizhenghui@xiaomi.com>
2024-09-10 12:17:20 +08:00
George White 3f00c4aae0 rp2040: support pico-sdk 2.0.0
Since the introduction of the rp2350, the pico-sdk project has been
re-arranged and elf2uf2 has been merged in to a new 'picotool' binary
which is supplied and installed separately.
2024-09-08 21:43:22 +08:00
shizhenghui af19a22b11 ci-docker: add subversion to linux dockerfile
Add subversion to install list ensure linux docker
can use svn command to download source code.

Signed-off-by: shizhenghui <shizhenghui@xiaomi.com>
2024-09-05 21:25:46 +08:00
TAiGA cc0d4af20a tools/mksymtab: support for structure 2024-09-05 15:54:49 +08:00
Matheus Catarino 1936e68f40 risc-v/qemu-rv: Add Build Config for leds64_zig
This PR adds a new Build Config `rv-virt:leds64_zig` that builds the Zig App `leds_zig` for QEMU RISC-V 64-bit.
ref.: https://github.com/apache/nuttx-apps/pull/2534
2024-09-05 11:28:12 +08:00
Alexander Merkle 39937c9685 tools/ci/docker/linux/Dockerfile: fix ccache when running container as user
Normally ccache places the temporary files in `~/.ccache`, when invoking the container with
  `-u <uid>:<gid>`
as e.g. Jenkins does, this might result in a invalid/unknown home folder.
Thus ccache tries to write to `/.ccache` which doesn't exist and the user doesn't have any permissions.

Explicitly set `CCACHE_DIR` to a folder with appropriate permissions.
2024-09-05 10:09:57 +08:00
Alexander Merkle c95a1cc98b tools/ci/docker/linux/Dockerfile: fix cmake download
remove the leftover `wget` as curl is used
triggers a host not found on my machine

Signed-off-by: Alexander Merkle <alexander.merkle@lauterbach.com>
2024-09-04 09:09:50 +02:00
Filipe Cavalcanti 29ae9d1110 esp32s2: fix SPI flash and file system mounting
Copied spi flash files from risc-v
Removed old spiflash from make.defs
KConfig modifications for common spiflash
Added new spiflash entry to make.defs
S2 Board config update
Modifications working on S2. Need fix on ROM function
Board fixes
Deleted old spiflash files
Fixes for smartfs operation
Set new HAL version
Fixed wrong change on S3
2024-09-03 19:13:46 -03:00
simbit18 ccb20feb25 tools/ci/docker/linux/Dockerfile: Restarting the Docker-Linux workflow a new attempt
tools/ci/docker/linux/Dockerfile

revert from --strip-components=1 to --strip-components 1

.github/workflows/docker_linux.yml

   added -> workflow_dispatch:

Manual execution of a workflow
https://docs.github.com/en/actions/managing-workflow-runs-and-deployments/managing-workflow-runs/manually-running-a-workflow
2024-09-02 14:11:51 -04:00
simbit18 63ed723d93 tools/ci/docker/linux/Dockerfile: Restarting the Docker-Linux workflow
The docker image has not been updated we currently use that one
from 22 days ago.

It seems that the error encountered is due to an incomplete download. It will probably work fine if downloaded again..

 https://github.com/apache/nuttx/actions/runs/10619683045/job/29437799464#step:7:1339

28.31
28.31 gzip: stdin: unexpected end of file
28.31 tar: Unexpected EOF in archive
28.32 tar: Unexpected EOF in archive
28.32 tar: Error is not recoverable: exiting now
2024-09-02 10:27:57 +08:00
guoshichao 4c01594d5b nuttx: remove the unnecessary -pipe build option
Signed-off-by: guoshichao <guoshichao@xiaomi.com>
2024-08-31 10:22:20 +08:00
YAMAMOTO Takashi 8e5f6de7e5 CI: drop stm3240g-eval:knxwm for now
cf. https://github.com/apache/nuttx/issues/13246
2024-08-30 21:03:08 +08:00
simbit18 75eea1b74e tools/ci/docker/linux/Dockerfile: image cleaned of unnecessary files and folders
Trying to reduce the size of the docker image, I found files and folders to be deleted.

For now, I have commented Swift from the  Dockerfile because the package is too large.
2024-08-30 01:19:55 +08:00
LuchianMihai d59fbfdbdc tools/nxstyle: fix wrong error reports for if statements
* Fix nxstyle check so it does not report error on comments on the same
line as if statements
* Rework if statement checks
* Report warning instead of error for is statements check fail
2024-08-28 09:08:42 +08:00
simbit18 1661a66843 [cmake]: added initial support for MSYS2
Currently concerns only arm.

tools/ci/testlist/msys2.dat:
At the moment I only added the board nucleo-l152re:nsh

.github/workflows/build.yml:
Enabled cmake for msys2
2024-08-27 21:36:12 +08:00
guoshichao dd8b630b0d nuttx: add GREENHILLS compiler config option
Signed-off-by: guoshichao <guoshichao@xiaomi.com>
2024-08-27 01:56:34 +08:00
Matheus Catarino 25bd3be167 tools/ci: add zig, ldc and swift
The main objective is to determine if the examples really work or if they have been obsoleted.
The languages included in the list promote good interoperability with the NuttX API (C predominant).

This will show if they are worth integrating in NuttX.

**FFI method**

- Rust: bindgen or c2rust
- D: importC
- Swift: Bridging header or clang modulemap.
- Zig: `@cImport/@cInclude` or translate-c
2024-08-26 10:25:54 +08:00
Matheus Catarino 93b520f7b0 swift6 embedded support 2024-08-23 09:02:20 +08:00
jianglianfang f5fe7646ed sim: read the second buffer
It can only read the contents of the first buffer, so fblen should be changed to ensure that it can read the second buffer as well.

Signed-off-by: jianglianfang <jianglianfang@xiaomi.com>
2024-08-22 16:17:43 +08:00
liqinhui be942853c4 simwifi: Add debug info and disable the wifi of networkmanager.
Signed-off-by: liqinhui <liqinhui@xiaomi.com>
2024-08-21 23:36:26 +08:00
anjiahao 9eadf61e90 toos/gdb:sync mempool memdump method
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:24 +08:00
anjiahao 9478f5b6d4 tools/gdb:add get_symbol_value api
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:24 +08:00
anjiahao fcf06f6367 gdbserver:minidumpserver is powerful, so change name to gdbserver
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao 03f0a59816 minidumpserver:Special processing xtensa architecture
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao 0a7d731eb7 minidumpserver:change logger format to debug
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao 4d05e69c1d minidumpserver:thread awarenes bug fix
1. need to continue if tcbptr is NULL
2. need use g_last_regs to show running regs
3. get a bad range

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao 8e0fb2c433 minidumpserver:support use coredump restore the crash scene
The benefit of this approach is that in a multi-core AMP system,
a single coredump might contain memory information from other cores.
By analyzing this coredump along with the corresponding ELF files from
the other cores, you can reconstruct the crash site of those other
cores.

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao f52a3d314e minidumpserver:support thread awareness
If we have a full memory raw dump, we can parse g_tcbinfo, g_npidhash,
and g_pidhash from the ELF to get NuttX thread info,
regardless of the crash dump log file.

support new command in gdb:
  info threads
  thread id

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao 65ef1f72c1 minidumpserver.py:Improve socket performance of minidumpserver.py
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao bb24fd9108 minidumpserver.py:support gdb can set register
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao f3e2b532e1 minidumpserver.py:support rawfile load
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
anjiahao 3a435b2eab minidumpserver.py:avoid port already used
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-21 18:01:06 +08:00
xinbingnan 942081ec6c minidumpserver: fix parsing bug
stack dump add new region `show stacks`, but this script is not support
now this is fixed with adding check condition for all lines contains stack word

Signed-off-by: xinbingnan <xinbingnan@xiaomi.com>
2024-08-19 19:54:06 +08:00
cuiziwei 4c70918888 tools/parsetrace.py:fix parsetrace script error.
Traceback (most recent call last):
  File nuttx/tools/parsetrace.py, line 29, in <module>
    from pycstruct import pycstruct
ModuleNotFoundError: No module named 'pycstruct'

Signed-off-by: cuiziwei <cuiziwei@xiaomi.com>
2024-08-19 13:53:30 +08:00
fanjiangang 5e9358b782 make/disassembly: generate disassembly file
Create the nuttx.asm in the disassembly format using the objdump program.

NOTE:
'>', objdump doesn't take arguments for output file,
but result is printed to standard out, and is redirected.

Signed-off-by: fanjiangang <fanjiangang@lixiang.com>
Signed-off-by: chao an <anchao@lixiang.com>
2024-08-16 15:22:25 +08:00
Lup Yuen Lee 52583fc17e tools/ci: Add Rust Target for QEMU RISC-V 64-bit
This PR updates the Docker Image for NuttX CI, so that it builds Rust Apps correctly for QEMU RISC-V 64-bit. We add the Rust Target for `riscv64gc-unknown-none-elf` to the Docker Image.

In the next PR, we will call the Updated Docker Image to [compile the Rust App `leds_rust`](https://github.com/apache/nuttx/pull/12852), at every run of NuttX CI. This will validate whether Rust Apps are built correctly for QEMU RISC-V 64-bit.

Modified Files:

`tools/ci/docker/linux/Dockerfile`: Add Rust Target `riscv64gc-unknown-none-elf` for Docker CI

`tools/ci/platforms/ubuntu.sh`: Same as above, but for Ubuntu CI

`tools/ci/platforms/msys2.sh`: Same as above, but for MSYS2 CI
2024-08-07 19:59:56 +08:00
Lup Yuen Lee 788f91c677 tools/[Rust|D]: Fix the Rust and D Builds for QEMU RISC-V
This PR fixes the build for Rust Apps and D Apps on QEMU RISC-V. Previously the Rust Build selected the [incorrect Rust Target riscv64i-unknown-none-elf](https://lupyuen.github.io/articles/rust5#rust-target-is-incorrect). Now the Rust Build selects the correct Rust Target: riscv64gc-unknown-none-elf.

This PR also fixes the 32-bit RISC-V Target for D Apps. D Targets ("riscv32") are named differently from Rust Targets ("riscv32gc"), this PR restores the correct Target Names.

Note that Rust Apps won't build correctly for QEMU RISC-V 32-bit. This requires a [Rust Custom Target for riscv32gc](https://lupyuen.github.io/articles/rust4#custom-target-for-rust), which will make the NuttX Makefiles much more complicated.

Also note that `hello_d` won't build correctly for 64-bit `rv-virt:nsh64`. To date, NuttX has never supported 64-bit RISC-V for D Apps.

Modified Files:

`tools/Rust.defs`: Rename the RISC-V ISA `imafdc` to `gc` for Rust Targets

`tools/D.defs`: Exclude the RISC-V ISA for D Targets
2024-08-07 10:03:43 +08:00
Huang Qi 1eca39eacc tools/[Rust|D]: Fix build break for RISC-V
Rust/D support for RISC-V is broken after https://github.com/apache/nuttx/pull/11549,
since the target triple is quite different bewteen Rust/D toolchain and GCC,
only few RISC-V targets are supported by Rust toolchain now, so it's better to
construct target triple in Rust.defs/D.defs for RISC-V.
2024-08-05 16:20:19 +08:00
Alexey Matveev e9d20bd611 Add mkfsdata.py 2024-08-03 01:29:09 +08:00
buxiasen 1de538282e tools/parsememdump: speed up use mem addr cache and multi-thread
Signed-off-by: buxiasen <buxiasen@xiaomi.com>
2024-08-02 13:40:14 +08:00
anjiahao 8acd8e5236 fix parsememdump.py statistics error bug
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-02 13:40:14 +08:00
anjiahao bc55750d71 parsememdump.py:fix bug determine whether it is the memory of the same backtrace
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-02 13:40:14 +08:00
anjiahao 6f23c8d943 parsememdump.py:fix bug add prefix addr2line
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2024-08-02 13:40:14 +08:00
Luchian Mihai 780366de62 tools: nxstyle if statement check
nxstyle will print an error on a single line if statement
2024-07-31 17:56:47 +08:00
simbit18 c4efab7eea tools/testbuild.sh: added store compilation artifacts for cmake
Added the ability to store compilation artifacts for cmake after a job.
2024-07-30 21:36:26 +08:00
simbit18 3637040d73 tools/ci/testlist: Added jobs to speed up CI checks.
Divided jobs risc-v and xtensa to finish workflow under 2 hours.
2024-07-30 01:43:29 +08:00
Huang Qi 9240e1b5ce nxstyle: Add Dl_info to white list
Avoid the mixed case identifiers warning
for Dl_info which is from the POSIX.

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2024-07-26 14:39:10 -03:00