58326 Commits

Author SHA1 Message Date
Tomasz 'CeDeROM' CEDRO
358469e5bb github: Setup protection for master branch.
* We do not have "Settings" tab in the Apache's owned repository,
  thus we need to update .asf.yaml file with repository settings.
* No direct push to master branch is possible.
* Require status checks to pass before merge.
* Setup reviews parameters.
* Require signatures.
* Require conversation resolution.
* Require linear history.

Signed-off-by: Tomasz 'CeDeROM' CEDRO <tomek@cedro.info>
2025-05-07 10:37:44 +08:00
Tyler Bennett
559a278ddb boards/stm32h5/nucleo-h563zi: Add USART2 board defines.
This adds the ability to use USART2 as a console if wanting to use
a console without going through the ST-Link VCOM port. This required when
using an external debugger or trace with this board.

Signed-off-by: Tyler Bennett <tbennett@2g-eng.com>
2025-05-07 02:20:28 +08:00
Tyler Bennett
6ef5dab160 documentation/platforms/arm: Add Nucleo G0B1 board.
Include description of support for Nucleo G0B1RE from STMicro.
2025-05-07 02:03:19 +08:00
Tyler Bennett
94a62cb5a7 boards/stm32f0l0g0: Add Nucleo G0B1RE support
The Nucleo G0B1RE is a development board using the STM32G0B1RE MCU.
This commit adds a basic nsh over serial configuration.
2025-05-07 02:03:19 +08:00
Tim Hardisty
f967a69748 arch/arm/sama5: Add code to report the reset reason
This adds the necessary code and function to allow a board to determine the reason for a reset. This is useful in NXboot, for example.

Signed-off-by: Tim Hardisty <timh@jti.uk.com>
2025-05-07 02:03:00 +08:00
ouyangxiangzhen
fb592064cb sched: Improved the wdog and wq list insertion.
For the watchdog list and the workqueue list, we wonder whether the list head has changed after the insertion. In the original implementation, we have to access the list->next field and compare the result to the currently inserted node. In this commit, we mark the list head before the insertion and comparing the current traversed node with the list head we marked, which can avoid accessing the list->next and is more cache-friendly.

Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
2025-05-07 02:02:10 +08:00
ouyangxiangzhen
6f72f5481d sched/wqueue: Refactor delayed and periodical workqueue.
This commit refactors the logic of workqueue processing delayed and periodic work, and changes the timer to be set in `work_thread`. The improvements of this change are as follows:
- Fixed the memory reuse problem of the original periodic workqueue implementation.
- By removing the `wdog_s` structure in the `work_s` structure, the memory overhead of each `work_s` structure is reduced by about 30 bytes.
- Set the timer for each workqueue instead of each work, which improves system performance.
- Simplified the workqueue cancel logic.

Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
2025-05-07 02:02:10 +08:00
ouyangxiangzhen
9dbb9b49c6 sched/wqueue: Change dq to list.
In NuttX, the dq and the list are two different implementations of the double-linked list. Comparing to the dq, the list implementation has less branch conditions such as checking whether the head or tail is NULL. In theory and practice, the list is more friendly to the CPU pipeline. This commit changed the dq to the list in the wqueue implementation.

Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
2025-05-07 02:02:10 +08:00
ouyangxiangzhen
900b1c19dd wqueue: improve the robustness of the work
struct work_s
{
  union
  {
    struct
    {
      struct dq_entry_s dq;      /* Implements a double linked list */
      clock_t qtime;             /* Time work queued */
    } s;
    struct wdog_s timer;         /* Delay expiry timer */
    struct wdog_period_s ptimer; /* Period expiry timer */
  } u;
  worker_t  worker;              /* Work callback */
  FAR void *arg;                 /* Callback argument */
  FAR struct kwork_wqueue_s *wq; /* Work queue */
};

work_cancel() should determine whether the current work is
in the timer or has already entered the queue.
This judgment is indispensable because the structure is a union.
Whether it is interpreted as a timer or as a dq needs to be determined.

But this judgment seriously depends on the order of struct wdog_s and
struct dq_entry_s, once someone change the order of any, there is a bug.
So we decide remove the union, to improve the robustness.

For the work_s structure size will grow bigger, then we will provide a
another optimization patch

Signed-off-by: ligd <liguiding1@xiaomi.com>
Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
2025-05-07 02:02:10 +08:00
Tiago Medicci Serrano
c22df41ca6 espressif: Add variable to override MCUboot version and URL
The version and the git repository of Espressif's MCUboot port can
be changed by setting the `MCUBOOT_VERSION` and `MCUBOOT_URL`
environment variables before running the `make bootloader` command.

Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
2025-05-07 01:51:40 +08:00
Matteo Golin
6eba7ad35b docs/xtensa: Added chip tags
Added chip documentation tags to Xtensa boards.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-05-06 19:19:56 +02:00
Matteo Golin
989809b82c docs/arm/rp2350: Add chip tags
Added chip tags to the rp2350 board family.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-05-06 19:19:56 +02:00
Matteo Golin
af45a91d10 docs/arm64: Tag arm64 boards.
Added appropriate chip tags for the arm64 boards.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-05-06 19:19:56 +02:00
Matteo Golin
f6222a013c docs/arm/nrf: Tag NRF chip boards.
Introduces chip tags for family and chip type on all of the supported
nRF based boards.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-05-06 19:19:56 +02:00
Matteo Golin
4d8d2354ec docs/arm/stm32: Tag all STM32 chip families with their chips.
This commit introduces the tagging system into the STM32 family of chips
by tagging all chips with their appropriate chip type/family.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-05-06 19:19:56 +02:00
vrmay23
e086ef2d02 boards/arm/stm32f7/nucleo-f767zi: enhance button support
Before this patch, the board nucleo-767zi had just one button available for the
user, which one was not working (there was no /dev/buttons on stm32_bringup.c).

Aditionally, I have changed the stm32_buttons.c to support not only the
built-in button but as well as to another four external buttons.
2025-05-05 20:14:23 -03:00
Serg Podtynnyi
95cc862794 arch/arm/rp23xx: fix watchdog, enable TICK blocks
On the RP2350, the watchdog receives its tick input from the
system-level ticks block, unlike the RP2040, where the watchdog includes
its own tick generator. Enable the TICK blocks, update the watchdog
routines.

Signed-off-by: Serg Podtynnyi <serg@podtynnyi.com>
2025-05-05 23:58:10 +08:00
Filipe Cavalcanti
28abfb5fd1 boards/esp32s3: fix rtc segment on linker script
Modify rtc_data_seg to rtc_slow_seg to fix RTC problems.
The proper location for those is in RTC slow memory.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-05-05 23:50:52 +08:00
simbit18
d4e1d85008 CMake: added tm4c129e-launchpad, launchxl-cc1312r1, lm4f120-launchpad, lm3s8962-ek and ekk-lm3s9b96 boards
CMake added following boards:
tm4c129e-launchpad
launchxl-cc1312r1
lm4f120-launchpad
lm3s8962-ek
ekk-lm3s9b96
2025-05-05 23:50:20 +08:00
chao an
d07bed3e6b tools/process_config: remove unused unnecessary printing
Too much unnecessary printing that meaningless to non-builder developers

Signed-off-by: chao an <anchao.archer@bytedance.com>
2025-05-05 23:49:16 +08:00
Matteo Golin
ac583fc585 arch/arm/rp2040/gpio: Allow simultaneous selection of multiple interrupt modes.
The RP2040 chip supports 4 different GPIO interrupt modes. They can be
configured to be used simultaneously, although previously the NuttX
support only allowed one type of interrupt to be enabled per GPIO pin.
This allows up to all four to be selected without changing previous
behaviour.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-05-05 23:48:21 +08:00
Eren Terzioglu
5cc7046a7f arch/risc-v/espressif: Fix Serial IFLOW build issue
Serial IFLOW build error fixed for risc-v based Espressif devices

Signed-off-by: Eren Terzioglu <eren.terzioglu@espressif.com>
2025-05-05 23:47:05 +08:00
Eren Terzioglu
929c6313ff arch/risc-v/espressif: Add RS485 support for esp32[c3|c6|h2]
Add RS485 support for Risc-V based Espressif devices

Signed-off-by: Eren Terzioglu <eren.terzioglu@espressif.com>
2025-05-05 23:47:05 +08:00
Lars Kruse
4d70fa74e8 pre-commit: enable codespell checks 2025-05-05 12:34:39 +08:00
Lars Kruse
7088d2ee91 ci: enable spelling checks (via codespell) 2025-05-05 12:34:39 +08:00
Lars Kruse
1efeb39da0 style: add codespell configuration for common spelling exceptions
This file can be extended in order to cover all spelling check
exceptions (perceived as misspellings).
2025-05-05 12:34:39 +08:00
Serg Podtynnyi
bc8a7f713d arch/arm/rp23xx: add dsp/fpu extensions support
Each Arm Cortex-M33 processor in RP2350 is configured with Single
precision FPU and DSP extension
2025-05-05 09:35:39 +08:00
Lars Kruse
10c3930279 fix(udhcpc): missing interface name in log message
The mis-referenced variable probably did not cause an error, but simply
led to an empty string instead of the real network interface name.
2025-05-05 09:32:31 +08:00
Lars Kruse
bacc6bec37 fix(locale): misspelled "February" string (nl_langinfo) 2025-05-05 09:32:31 +08:00
Lars Kruse
fa719f52f6 fix(stm32h7): malformed compiler error message
The malformed compiler error message was added in the initial commit of
the stm32_rptun module (2fffd7dad6).
2025-05-05 09:32:31 +08:00
Lars Kruse
9afc9868f6 fix(kinetis): malformed define KINETIS_NSPI
The malformed defines were introduced in commit 91dd3306c8.
They affect only the following chips:
* MK64FX512VMD12
* MK64FN1M0VMD12
2025-05-05 09:32:31 +08:00
rongbaichuan
ee3e2401e7 libc/backtrace: Fix compilation error when set LIBC_BACKTRACE_BUFFSIZE
When compiling lib_backtrace.c after set CONFIG_LIBC_BACKTRACE_BUFFSIZE,
there will be compilation error warnings. This is because spin_unlock_irqrestore
incorrectly used pool->lock during unlocking, which has been corrected to bp->lock.

Signed-off-by: Baichuan Rong <rongbaichuan1027@163.com>
2025-05-05 09:29:26 +08:00
raiden00pl
5d2f121231 boards/nrf5340-dk: fix rpmsghci_nimble_cpuapp
fix broken rpmsghci_nimble_cpuapp configuration for nrf5340-dk.

Signed-off-by: raiden00pl <raiden00@railab.me>
2025-05-05 09:28:35 +08:00
raiden00pl
dbeba61c3c arch/nrf53/nrf53_sdc.c: fix broken RPMSG HCI server
BT device should not be registered when RPMGS HCI server is enabled.
Broken server since 31605b6335a8411833b410bf89ef10bd4fe502b0.

Signed-off-by: raiden00pl <raiden00@railab.me>
2025-05-05 09:28:35 +08:00
p-szafonimateusz
7e99c9582b boards/sim: add CAN support and configuration
Add host CAN support for sim target.

Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
2025-05-03 11:26:08 +08:00
p-szafonimateusz
76e1b80076 arch/sim: add CAN support based on host SocketCAN
Add CAN support for sim target based on host SocketCAN interface.

Tested with virtual CAN on Linux but should work also with hardware CAN cards supported by host.

Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
2025-05-03 11:26:08 +08:00
George Poulios
7ea8b59a59 boards/imx93-evk: kernel build for AHAB boot
Add kernel build (target imx93-evk:knsh) to i.MX93 EVK.
This target is preconfigured for use with AHAB boot (see
https://spsdk.readthedocs.io/en/latest/examples/ahab/imx93/imx93_ahab_uboot.html)
as a replacement of U-Boot proper (BL33 at EL2), hence
the load address is set to 0x80200000.

Signed-off-by: George Poulios <gpoulios@census-labs.com>
2025-05-03 11:25:54 +08:00
Serg Podtynnyi
464c0831ce arch/arm/rp23xx: fix not restart after TX error
Fix a bug that I2C driver can not transfer after TX abort error.
It caused by remaining NO_STOP flag status.
same as done in commit 0df0a10 for cxd56xx

Signed-off-by: Serg Podtynnyi <serg@podtynnyi.com>
2025-05-03 11:17:37 +08:00
Michal Lenc
eeb4a0de83 setlogmask: fix setlogmask behavior according to POSIX standard
POSIX states "If the maskpri argument is 0, the current log mask is
not modified." The current implementation in NuttX doesn't
respect this and thus is in a clear violation with a strict POSIX
compliance rule in The Inviolable Principles of NuttX.

This commit therefore changes the behavior to the expected one. Passing
argument 0 doesn't change the current log mask, but just returns the
old one. Completely disabling logging at runtime is thus not possible,
but you may set the highest priority LOG_EMERG only to disable most of
the messages. Default can still be set to no logging with
CONFIG_SYSLOG_DEFAULT_MASK configuration option.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2025-05-02 16:29:08 +02:00
Tyler Bennett
c84f7c630f arch/stm32f0l0g0: Add support for STM32G0B1xx
Adds Kconfig and modifies chip.h for STM32G0B1xx options.

Signed-off-by: Tyler Bennett <tbennett@2g-eng.com>
2025-05-02 15:01:45 +02:00
Filipe Cavalcanti
9e8197ad49 boards/risc-v: add MPU60x0 bringup support to ESP32C6
Adds a defconfig for using MPU60x0 and implement the bringup sequence for the I2C IMU.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-05-02 09:31:52 -03:00
Serg Podtynnyi
3c5580e693 boards/arm: refresh defconfig for common board
refresh boards defconfigs for CONFIG_ARCH_BOARD_COMMON

Signed-off-by: Serg Podtynnyi <serg@podtynnyi.com>
2025-05-02 09:30:34 -03:00
Serg Podtynnyi
4c52f2dbeb tools: Update Unix.mk and savedefconfig.cmake for CONFIG_ARCH_BOARD_COMMON
Preserve CONFIG_ARCH_BOARD_COMMON in savedconfig

Signed-off-by: Serg Podtynnyi <serg@podtynnyi.com>
2025-05-02 09:30:34 -03:00
Pip Cet
cfab00817a fs/procfs: Improve subdirectory recognition
This patch fixes https://github.com/apache/nuttx/issues/16237, where
cd'ing to a non-directory prefix of a procfs entry would succeed.

Signed-off-by: Pip Cet <pipcet@protonmail.com>
2025-05-02 09:28:06 -03:00
Valentyn Korniienko
43b29a0547 Fixed empty line handling process_config.sh
This commit fixed empty line handling in the config file for being able to used KConfig-based defconfigs with the empty lines in them
2025-05-02 09:27:44 -03:00
Jukka Laitinen
2b513af2c3 sched/signal/sig_dispatch: Fix race conditions between nxsig_tcbdispatch and nxsig_deliver
For example a race in managing tcb->sigprocmask may cause signal not being delivered at all.
The mechanism is as follows:

1. cpu 1: nxsig_deliver adds the signal to the sigprocmask for the duration of signal delivery
2. cpu 2: new signal (same signo) is dispatched in nxsig_tcbdispatch
3. cpu 2: nxsig_tcbdispatch detects that signal is masked
4. cpu 2: nxsig_tcbdispatch leaves critical section before calling nxsig_add_pendigsignal
5. cpu 1: nxsig_deliver finishes. The "nxsig_unmask_pendingsignal" is called in the end but does nothing
6. cpu 2: nxsig_tcbdispatch continues and adds the pending signal

In the end, the logic in the end of nxsig_deliver, which tries to handle signals added
to the pending queue during the signal action delivery (step 5) failed, and the pending signal
was not delivered.

Fix this by just keeping the critical section for during the whole duration of nxsig_tcbdispatch,
and move things which can't be executed from within critical section outside.

Signed-off-by: Jukka Laitinen <jukka.laitinen@tii.ae>
2025-05-02 09:21:14 -03:00
Tim Hardisty
ed0c18c66c drivers/video/fb.c: Add startup splashscreen option
Adds Kconfig-selected splashscreen options used when the driver is first registered

* Includes a new Python script in ./tools to create RLE bitmap files
* Includes default NS logo btimaps in 320x320, 160x160 and 80x80 resolutions along with their PNG files

Signed-off-by: Tim Hardisty  timh@jti.uk.com>
2025-04-30 06:38:05 -03:00
Lars Kruse
b333ad3ab5 style: fix typos
Thanks, codespell!
2025-04-30 13:45:46 +08:00
stydxm
543d7c87bc risc-v/k230: update documents
fix typo
remove a `)` that should not be here

Signed-off-by: stydxm <stydxm@outlook.com>
2025-04-30 13:44:49 +08:00
p-szafonimateusz
09a5a0e72e x86_64: support for stack canaries
Add support for stack canaries for x86.

This includes mostly fixes for TLS support that are required for stack canaries
in x86. The FSBASE register must be unique per thread so we have to keep it in
thread registers area.

Signed-off-by: p-szafonimateusz <p-szafonimateusz@xiaomi.com>
2025-04-30 13:42:56 +08:00