Commit graph

114498 commits

Author SHA1 Message Date
Martin Jäger
bb0e580be4 soc: stm32g0x: add poweroff implementation
Same implementation as stm32c0x and stm32l4x. This is required
for wake-up from sleep.

Signed-off-by: Martin Jäger <martin@libre.solar>
2025-05-02 01:17:02 +02:00
Martin Jäger
d65149e210 dts: arm: stm32g0: add pwr node and wkup-pins
WKUP3 is only available for g0b0/1 and g0c1 variants.

WKUP5 is only available in larger packages. However, package sizes
are currently not considered in the devicetree file schema for STM32.

Signed-off-by: Martin Jäger <martin@libre.solar>
2025-05-02 01:17:02 +02:00
Chris Friedt
0cac1849ca doc: kernel: mark k_event apis as being ISR safe
Most of the k_event APIs are ISR-safe, with the exception of

* k_event_init() - object should be initialized before ISR context
* k_event_wait(), k_event_wait_all() - only ISR safe with K_NO_WAIT

The last two functions already check for K_NO_WAIT when in ISR context
so this is very much just updating documentation to reflect the
current state.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2025-05-02 01:16:46 +02:00
Chris Friedt
36c44045a0 kernel: events: prevent k_event_init() from being called in an ISR
Most kernel objects should be initialized well before being
manipulated in ISR context.

Event objects are no exception. Initializing a k_event object in
ISR context would implicitly be racey and introduce an element of
non-determinism.

Assert that k_event_init() is not called from ISR context.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2025-05-02 01:16:46 +02:00
Hake Huang
c10e6eaf07 soc: mimxrt11xx: update the frdmram api
flexram api change to misc.

fixes: #89150

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
2025-05-02 01:16:37 +02:00
Hake Huang
61e1dc963c samples: magic_addr: move the config to app.overlay
move the board config to app.overlay, as it is
a general dts settings

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
2025-05-02 01:16:37 +02:00
Derek Snell
26423f2020 soc: nxp: mcxn: configure CPU1 TrustZone access level
Configures AHBSC MASTER_SEC_LEVEL register for the cpu1 before cpu1 is
enabled.  By default, this gives CPU1 secure and privileged access to
the rest of the SOC, same as CPU0.

Signed-off-by: Derek Snell <derek.snell@nxp.com>
2025-05-02 01:16:26 +02:00
Derek Snell
01ca78b227 Revert "boards: nxp: frdm_mcxn947: enable GPIO in all modes"
This reverts commit feb966df36cbb8b6d847b9f0873bc79195e7fd22.  That
change makes GPIO registers inaccessible from cpu0.

Signed-off-by: Derek Snell <derek.snell@nxp.com>
2025-05-02 01:16:26 +02:00
Keith Packard
2d64237f44 cmake: Enable undefined behavior sanitizer on all targets
GCC and Clang support the undefined behavior sanitizer in any
configuration, the only restriction is that if you want to get nice
messages printed, then you need the ubsan library routines which are only
present for posix architecture or when using picolibc.

This patch adds three new compiler properties:

 * sanitizer_undefined. Enables the undefined behavior sanitizer.
 * sanitizer_undefined_library. Calls ubsan library routines on fault.
 * sanitizer_undefined_trap. Invokes __builtin_trap() on fault.

Overhead for using the trapping sanitizer is fairly low and should be
considered for use in CI once all of the undefined behavior faults in
Zephyr are fixed.

Signed-off-by: Keith Packard <keithp@keithp.com>
2025-05-02 01:16:18 +02:00
Alex Fabre
1fdad5cc29 doc: toolchain: atfe: arm toolchain for embedded documentation
Arm Toolchain for Embedded (ATfE) is the next-generation Arm embedded
C/C++ compilation toolchain.

Arm Toolchain for Embedded is 100% open source. Arm is investing in the
LLVM linker and minor tools, and in the Picolib C library, to create a
performant 100% open source compilation toolchain for embedded
development with Arm-based designs.

The proprietary components used in Arm Compiler for Embedded 6 (the
linker, C library, and binutils carried over from the legacy Arm
Compiler 5 toolchain) are retired in favour of their open source
(LLVM and Picolib) equivalents.

Product page: https://developer.arm.com/Tools%20and%20Software/Arm%20Toolchain%20for%20Embedded
Github repo: https://github.com/arm/arm-toolchain

Signed-off-by: Alex Fabre <alex.fabre@rtone.fr>
2025-05-02 01:16:08 +02:00
Alex Fabre
6e5554b383 doc: toolchain: ac6: update documentation filename
This update changes the filename from 'arm_compiler.rst' to
'arm_compiler_6.rst' to accurately reflects its focus on AC6.

Recently, Arm introduced the Arm Toolchain for Embedded (ATfE), which is
distinct from AC6. This 7th generation compiler is entirely open source
for the first time. To distinguish it from AC6 and highlight it's a
complete toolchain rather than just a compiler, this new version will
be named Arm Toolchain for Embedded (ATfE).

Signed-off-by: Alex Fabre <alex.fabre@rtone.fr>
2025-05-02 01:16:08 +02:00
Tais Hjortshøj
0709014549 scripts: west_commands: Add powershell autocompletion (west -b)
Windows powershell can by default not autocomplete known boards when
tapping which can cause frustration when you can't quite remember the
exact name or you don't want to type it out.
west build .\path\to\application\ -p -b stm<tab> will search for
available board including 'stm' in their name.

Signed-off-by: Tais Hjortshøj <tbh@mjolner.dk>
2025-05-02 01:16:00 +02:00
Josep Puigdemont
e0dbba5bd3 samples: sensor: lps22hh: fix title
The name of the sensor in the title had one S too many, it should
be LPS22HH instead of LPSS22HH.

Same for the I3C version of the sample.

Signed-off-by: Josep Puigdemont <josep.puigdemont@gmail.com>
2025-05-01 18:18:03 +02:00
Josep Puigdemont
b915e24817 samples: sensor: i3g4250d: add missing config
Adds CONFIG_REQUIRES_FLOAT_PRINTF so that printf can display
floats correctly.

Signed-off-by: Josep Puigdemont <josep.puigdemont@gmail.com>
2025-05-01 18:17:54 +02:00
Vijayakannan Ayyathurai
32253c6159 net: ip: resolve NET_IPV4_FRAGMENT build warning
warning: format '%d' expects argument of type 'int', but argument 3 has
type 'size_t' {aka 'long unsigned int'} [-Wformat=]

Change the printf modifier to %zd for size_t variable will resolve the
warning.

Signed-off-by: Vijayakannan Ayyathurai <vijayakannan.ayyathurai@intel.com>
2025-05-01 18:17:46 +02:00
Fabrice DJIATSA
19ba839d66 tests: drivers: spi: spi_loopback: update testcase file
add stm32n6570_dk in yaml file for CI test integration
purpose.

Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
2025-05-01 18:17:15 +02:00
Fabrice DJIATSA
234efb48dc tests: drivers: i2c: i2c_target_api: update testcase file
add stm32n6570_dk in yaml file for CI test integration
purpose.


Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
2025-05-01 18:17:15 +02:00
Armando Visconti
4c34b5d725 drivers/sensor: lis2dux12: add high performance mode
Add driver capability to properly set high performance mode
while setting data rate (thru lis2duxxx_mode_set() API)
based on how power-mode is set into DTS: if it is set to
LIS2DUX12_OPER_MODE_HIGH_PERFORMANCE then configure HP mode,
LP/ULP mode otherwise.

Signed-off-by: Armando Visconti <armando.visconti@st.com>
2025-05-01 18:17:05 +02:00
Axel Le Bourhis
dc52ec7d32 soc: nxp: rw: fix wrong dependency on kconfigs
Use `defaut y if` instead of `depends on` as the related Kconfig
should be user configurable even when standby mode is not used.

Signed-off-by: Axel Le Bourhis <axel.lebourhis@nxp.com>
2025-05-01 18:16:57 +02:00
Axel Le Bourhis
0ecaef0053 drivers: mcux_flexcomm: fix character glitches at low power entry
Character glitches are observed when entering suspend and standby low
power modes.
To fix it, we make sure the `poll_out` API waits for the character
transfer to complete. This is aligned with the uart driver API
description.

Signed-off-by: Axel Le Bourhis <axel.lebourhis@nxp.com>
2025-05-01 18:16:57 +02:00
Olivier Lesage
36aa80337b bluetooth: host: Clarify docs about reading remote FAE table
There was some confusion about why this function doesn't work with
nordic devices. The explanation is that the controller is required
to return an error code if the remote device doesn't need an FAE table.

Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
2025-05-01 18:16:48 +02:00
Manuel Argüelles
3602108bd8 MAINTAINERS: add collaborator and board to NXP Robotics area
Changes on NXP Robotics Products area:
- add myself as collaborator
- move ucans32k1sic board from S32 area

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2025-05-01 18:16:39 +02:00
Manuel Argüelles
07936d7182 MAINTAINERS: add congnguyenhuu as collaborator of NXP S32
Nominate congnguyenhuu as collaborator of NXP Platforms (S32) area.

See #89219

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2025-05-01 18:16:39 +02:00
Lauren Murphy
51aa2ffec0 arc: add ram to qemu board yaml so arc tests run
With a missing RAM value in the ARC QEMU board YAML,
Twister assigns it 128. The min_ram filter for the
testcase is higher. The RAM in the ARC QEMU board DTS
is 4 MB. Update ARC QEMU board YAML to include 4 MB
of RAM so tests run on ARC QEMU.

Signed-off-by: Lauren Murphy <lauren.murphy@intel.com>
2025-05-01 18:16:30 +02:00
Lauren Murphy
e0a54835c2 llext: support ARC MPU
Make it so LLEXT allocates a memory region equal or greater
to the minimum size supported by the MPU, to ensure no region
overlap.

Signed-off-by: Lauren Murphy <lauren.murphy@intel.com>
2025-05-01 18:16:30 +02:00
Daniel Leung
0d650aebe7 boards: qemu_xtensa/sample_controller32/mpu: enable twister
Since Zephyr SDK 0.16.9, it has support for building the board
qemu_xtensa/sample_controller32/mpu. Addd the corresponding
toolchain entry in the YAML file so it can built with twister
without forcing toolchain.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-05-01 18:16:20 +02:00
Daniel Leung
d3dcf36897 libc: newlib: heap arean to support Xtensa MPU
This adds the bits to define HEAP_BASE when using Xtensa MPU.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-05-01 18:16:20 +02:00
Daniel Leung
5682a7f09e logging: backend/xtensa_sim: more generic enabling condition
Instead of using individual SoC kconfigs to determine whether
to enable the Xtensa simulator logging backend, simply use
CONFIG_SIMULATOR_XTENSA.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-05-01 18:16:20 +02:00
Thomas Lang
1a8b8f4220 drivers: sensor: Added timeout for apds9960 sampling
Timeout occurs if status register does not register an interrupt

Signed-off-by: Thomas Lang <thomaslang2003@me.com>
2025-05-01 18:16:05 +02:00
Thomas Lang
f38beeafba drivers: sensor: Make apds9960 polling wait
sensor_fetch for apds9960 will now block until a valid sample is ready

Signed-off-by: Thomas Lang <thomaslang2003@me.com>
2025-05-01 18:16:05 +02:00
Thomas Lang
999b8f85c6 drivers: sensor: Removed apds9960 interrupt pin
Made interrupt pin on apds9960 optional

Signed-off-by: Thomas Lang <thomaslang2003@me.com>
2025-05-01 18:16:05 +02:00
Emil Gydesen
6abdc389d4 Bluetooth: CSIP: Remove bt_csip_set_member_get_sirk
The bt_csip_set_member_get_sirk function is superseded by
bt_csip_set_member_get_info and uses of it has been replaced.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-05-01 18:15:56 +02:00
Jordan Yates
f4825033bc sensor: remove PM state checks from API functions
Calling sensor API functions on devices not in `PM_DEVICE_STATE_ACTIVE`
is a violation of the PM API. Adding manual checks inside of drivers
complicates the drivers and increases ROM footprint for no additional
benefit.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2025-05-01 18:15:42 +02:00
Dat Nguyen Duy
eb7ac1c0ff arm: cortex_a_r linker: move data section between rodata and bss
By moving data section between rodata and bss, and disabling
Kconfig LINKER_LAST_SECTION_ID by default if non-XIP (it is
seems only needed for XIP), the size of zephyr.bin can be
reduced significantly on non-XIP system.

As a result, moving __kernel_ram_start to another place
to ensure it still include bss + data as before.

Signed-off-by: Dat Nguyen Duy <dat.nguyenduy@nxp.com>
2025-05-01 18:15:33 +02:00
Johan Hedberg
3a07c25c65 Bluetooth: HCI: Rename BT_BUF_TYPE_INVALID to BT_BUF_TYPE_NONE
The new name is slightly clearer, since strictly speaking any value not
part of the enum is invalid.

Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
2025-05-01 14:59:12 +02:00
Johan Hedberg
dcc1d384b6 Bluetooth: HCI: Add documentation for BT_BUF_IN/OUT
Document the enum values for the recently added bt_buf_dir enum.

Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
2025-05-01 14:59:12 +02:00
Pieter De Gendt
1a64977b1f sys: dlist: Add const qualifier to immutable API functions
Allow passing structs with sys_dlist_t members as const without
discarding qualifiers if the API is used without modifying it.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-05-01 08:54:04 -04:00
Pieter De Gendt
dde8067d4a sys: slist/sflist: Add const qualifier to immutable API functions
Allow passing structs with sys_slist_t/sys_sflist_t members as const
without discarding qualifiers if the API is used without modifying it.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-05-01 08:54:04 -04:00
Pieter De Gendt
857abda15e net: lib: coap: coap_server: Change error print to debug
The POLLHUP is expected with, for example DTLS UDP sockets.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-05-01 08:53:32 -04:00
Pieter De Gendt
51a4e4c858 samples: net: sockets: coap_server: Add CoAP secure support
Update the CoAP server sample to demonstrate using DTLS for secure
sockets.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-05-01 08:53:32 -04:00
Pieter De Gendt
b596b13e7c tests: net: lib: coap_server: Add secure test
Add testcase for CoAP secure service support.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-05-01 08:53:32 -04:00
Pieter De Gendt
470b582e04 net: lib: coap: Add CoAP secure support
Add optional TLS secure tag lists for CoAP services to enable DTLS
sockets.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-05-01 08:53:32 -04:00
Patryk Koscik
6fc11ca6dd samples: hello_world_user: unify board identifier output
This patch unifies the board target identifier output to match that in
the `hello_world/src/main.c` file.

Signed-off-by: Patryk Koscik <pkoscik@antmicro.com>
2025-05-01 13:43:03 +02:00
Bartosz Miller
a1a8d28394 tests: drivers: can: Enable GPD for nrf54h in CAN host test
nrf54h should be capable of operating
the CAN interface when GPD is enabled.

Signed-off-by: Bartosz Miller <bartosz.miller@nordicsemi.no>
2025-05-01 13:42:47 +02:00
Emil Gydesen
6ddc988c1e tests: Bluetooth: Audio: Fix includes
Updates the includes in a a few files to
avoid including unused header files and include the
ones that are used.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-05-01 13:42:37 +02:00
Emil Gydesen
d38b0e9ecd tests: BSIM: Bluetooth: Audio: Fix includes
Updates the includes in a a few files to
avoid including unused header files and include the
ones that are used.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-05-01 13:42:37 +02:00
Emil Gydesen
b04d6386db Bluetooth: Audio: Fix includes
Updates the includes in a a few files to
avoid including unused header files and include the
ones that are used.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-05-01 13:42:37 +02:00
Emil Gydesen
b9ddaf7a5f Bluetooth: Audio: Shell: Fix includes
Updates the includes in a a few files to
avoid including unused header files and include the
ones that are used.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-05-01 13:42:37 +02:00
Emil Gydesen
aaec705f12 Bluetooth: Audio: Fix includes in public header files
Updates the includes in a few header files to
avoid including unused header files and include the
ones that are used.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-05-01 13:42:37 +02:00
Martin Meyer
010d7d1b9a soc: raspberrypi: common: reformat pinctrl include
Apply clang-format on source files.

Signed-off-by: Martin Meyer <meyer.m90@gmail.com>
2025-05-01 13:42:17 +02:00