Commit Graph

103374 Commits

Author SHA1 Message Date
Jordan Yates a1d6f8081a fs: fatfs: additional ELM FAT options
Make additional ELM FAT library options configurable to the user.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-10-11 13:20:08 -04:00
Jordan Yates 4235dbfd2b fs: fatfs: add missing dependency
Add a missing dependency on `!FS_FATFS_READ_ONLY`` for `FS_FATFS_MKFS`.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-10-11 13:20:08 -04:00
Jamie McCrae 3406515f12 sysbuild: images: bootloader: Add RAM load note
Adds a note about MCUboot RAM requirements for this

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-10-11 13:19:39 -04:00
Jamie McCrae 525f2b9153 samples: mgmt: mcumgr: smp_svr: Add RAM load configuration
Adds configuration for booting this sample in RAM load mode on
nrf52840dk

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-10-11 13:19:39 -04:00
Jamie McCrae 646f116cca mcuboot: Add support for RAM load mode
Adds supporting code that allows the RAM load mode of MCUboot to
be used and for applications to build successfully with it.
Sysbuild can be used to build images for this mode

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-10-11 13:19:39 -04:00
Jamie McCrae 8774f15bd2 sysbuild: cmake: Add set_config_int() function
Adds a function that will add an integer value to an image

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-10-11 13:19:39 -04:00
Krzysztof Chruściński e11d050b23 drivers: pwm: nrfx: Improve runtime PM
Rework PM handling to use pm_device_driver_init(). Shim is not using
put and get internally as there is no api that disables or stops
pwm so it is hard to determine when to put the device. There are cases
when PWM peripheral is stopped but PWM is still active because
duty cycle is 100% or 0% and pin is driven by GPIO and not PWM.

If user want to use runtime PM with PWM it is possible and getting
the device will initialize internal data and putting will suspend
by forcing PWM stop if used and setting pins to sleep state. However,
from power consumption perspective it is enough to set 0% or 100%
duty cycle on all channels.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-10-11 13:18:34 -04:00
Krzysztof Chruściński c3a33cfd3e drivers: pwm: nrfx: Disable PWM peripheral when not used
Shim was not correctly disabling PWM when it was not used. Task
STOP was triggered but PWM->ENABLE remained set which caused
increased current. Added interrupt and enabled event handler in
the nrfx driver to allow disabling PWM on STOPPED event.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-10-11 13:18:34 -04:00
Krzysztof Chruściński 0ab86c48dd drivers: pwm: nrfx: Improve device generation macros
Use NRFX_FOREACH_PRESENT macro to iterate over all PWM instances
and create device only for those enabled in the devicetree.
This approach removes need of changing driver code when new
instance id is added.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-10-11 13:18:34 -04:00
Yangbo Lu 85501c5414 include: arm: arm_mpu_v8: support memory attribute for device for Cortex-M
Supported memory attribute for device for Cortex-M.
Not sure why such code was conditional compile for only Cortex-R,
but Cortex-M also suited.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
2024-10-11 13:18:21 -04:00
Guillaume Gautier ded9e11d59 drivers: dma: stm32 dmamux: fix for c0 hal update
Fix the DMAMUX driver for the STM32C0 HAL update. Typedef used in function
is now const.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2024-10-11 13:18:01 -04:00
Guillaume Gautier 48ba84bb95 drivers: clock: stm32 common: update ahb prescaler
STM32C0 have a different prescaler for SYSCLK and for HCLK.
Updates the clock driver to use the appropriate prescaler for each series.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2024-10-11 13:18:01 -04:00
Guillaume Gautier d61a984bd6 west.yml: update hal_stm32 to use latest version
Update hal_stm32 to use the latest version.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2024-10-11 13:18:01 -04:00
Sudan Landge 8bdd45be47 arch: arm: cortex_a_r: smp: minor fix for non cache coherent cores
What is changed?
1. Updated the data sync barrier to make sure the other parameters of
   `arm_cpu_boot_params` are updated before updating its member `mpidr`
2. Updated the MPIDR affinity level mask to account for affinity level
   1 and 2 along with level 0.

Why do we need this change?
1. As reported in issue #76182, on Cortex_A_R, the current code
   execution fails to consider the correct sequence of data sync
   barrier and cache maintenece for the code to work on non cache
   coherent cores in SMP enabled mode.
   The secondary cores are waiting in a loop for primary core to set
   `arm_cpu_boot_params.mpidr`. As soon as primary core set this,
    the secondary cores start reading other parameters from the
   `arm_cpu_boot_params` however, the existing position of DSB
   instruction doesn't guarantee that `arg`, `cpu_num` and other
   parameters of `arm_cpu_boot_params` would be updated before `mpidr`
   is udpated and this could lead to a unpredicatble behaviour so,
   we need to move the DSB instruction.
2. The affinity level mask is updated because it didn't account for
   level 1 to identify individual cores within a cluster and
   level 2 to identify different clusters within the system which can
   lead to an incorrect conversion between mpidr to core-id.

Signed-off-by: Sudan Landge <sudan.landge@arm.com>
2024-10-11 13:17:25 -04:00
Sudan Landge 67f3d0b923 tests: kernel: smp: Test cpu affinity with custom ROM offset
What is the changed?
CPU affinity test for SMP cores will now cover a change in ROM offset.

How is it changed?
Add a new testcase section with ROM offset set to something other than
the default 0.

Why is it change?
There is no test to cover the issue reported in #76182 and the cpu
affinity test is the closest to test the issue. Adding a new testcase
will makes sure there is no breaking change in the future.

Signed-off-by: Sudan Landge <sudan.landge@arm.com>
2024-10-11 13:17:25 -04:00
Sudan Landge ac2de3fa7c arch: arm: cortex_a_r: Set VBAR for all cores
What is changed?
Secondary cores can now boot successfully on cache and non-cache
coherent systems if the Zephyr image/vector table is loaded at an
address other than the default address 0x0.

How is it changed?
1. By calling the relocate_vector() from reset.S as part of EL1 reset
   initialization instead of prep_c to have VBAR set for all cores and
   not just for the primary core.
2. Remove dead code under CONFIG_SW_VECTOR_RELAY and
   CONFIG_SW_VECTOR_RELAY_CLIENT.

Why do we need this change?
1. As reported in issue #76182, on Cortex_ar, VBAR is set only for
   the primary cores while VBAR for the secondary cores are left with
   default value 0.
   This results in Zephyr not booting on secondary cores if the vector
   table for secondary cores is loaded at an address other than 0x0.
   VBAR is set in relocate_vector() so we move it to reboot.c which is
   better suited to have configs related to system control block.
2. The two SW_VECTOR_RELAY configs have a direct dependency on
   CONFIG_CPU_CORTEX_M, which is disabled while compiling for
   Cortex-A and Cortex-R hence leading to a dead code.

How is the change verified?
Verified with fvp_baser_aemv8r/fvp_aemv8r_aarch32/smp.

Signed-off-by: Sudan Landge <sudan.landge@arm.com>
2024-10-11 13:17:25 -04:00
TOKITA Hiroshi 2c95978f3b MAINTAINERS: Add build_all test files for bbram and flash
Add build_all to `files:` entry to bbram and flash.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-10-11 13:16:53 -04:00
TOKITA Hiroshi eebed141cf tests: drivers: build_all: Add a build_all test for flash
The test targets the following devices at this time.

- atmel,at45
- jedec,spi-nor

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-10-11 13:16:53 -04:00
TOKITA Hiroshi 60dc055f9e tests: drivers: build_all: Add a build_all test for bbram
The test targets the following devices at this time.

- microchip,mcp7940n

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-10-11 13:16:53 -04:00
TOKITA Hiroshi 23496f5208 tests: drivers: build_all: eeprom: Add config for ti,tmp116-eeprom
Add configuration to add `ti,tmp116-eeprom` to build test.

Also, adding emulator build test.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-10-11 13:16:53 -04:00
Francois Ramu 48a2aedb78 soc: st: stm32h7rs serie requires specific power rails
Enables the XSPIM2 rail when using GPIO bank N
Enables the XSPIM1 rail when using GPIO bank O or P
Enables the USBvoltage detector when using the GPIO M

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-10-11 13:16:43 -04:00
Marek Pieta bc5f1c8186 doc: releases: Add note for CONFIG_BT_CONN_TX_NOTIFY_WQ
Change adds a release note informing about the newly introduced Kconfig
option for Bluetooth stack.

Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
2024-10-11 13:16:26 -04:00
Marek Pieta 341f1f502d bluetooth: conn: Use a separate workqueue for connection TX notify
Use a separate workqueue instead of system workqueue for connection TX
notify processing. This makes Bluetooth stack more independent from the
system workqueue.

Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
2024-10-11 13:16:26 -04:00
Reto Schneider 7fa5a222a0 drivers: flash: Sort CMake and Kconfig files alphabetically
By sorting the lines alphabetically, merge conflicts can be reduced.

Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
2024-10-11 13:16:15 -04:00
Joakim Andersson d794d58d64 drivers: nrf_qspi_nor: Check poll period before sleep
Check that the poll period is non-zero before sleeping.

Signed-off-by: Joakim Andersson <joerchan@gmail.com>
2024-10-11 13:16:05 -04:00
Joakim Andersson 14c896b647 drivers: nrf_qspi_nor: Fix build without multithreading
Fix build of nrf_qspi_nor flash driver without multithreading enabled.
This is required for builds like mcuboot.

Signed-off-by: Joakim Andersson <joerchan@gmail.com>
2024-10-11 13:16:05 -04:00
Alexandre Bailon 0d5f8e3524 cmake: flash: Update OPENOCD variables to work with sysbuild
Defining OPENOCD and OPENOCD_DEFAULT_PATH when we are using sysbuild
doesn't make any effect.
This updates flash.cmake to make these variables compatible with sysbuild.

Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
2024-10-11 13:15:56 -04:00
Torsten Rasmussen 32e5894ab9 manifest: update picolibc to avoid setting of CMAKE_BUILD_TYPE
This commit updates picolibc module so that CMAKE_BUILD_TYPE is not
defined by picolibc when building with Zephyr.

The avoids a situation where both picolibc and Zephyr defines the
optimization level, for example like: `-Os -O2`.

And remove the warning:
> CMake Warning at .../zephyr/CMakeLists.txt:2166 (message):
>
> The CMake build type was set to 'MinSizeRel', but the optimization
> flag was set to '-O2'.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2024-10-11 13:15:37 -04:00
Fabio Baltieri 523efee132 tests: build_all: input: clean up the i2c device list
Make the address sequential again, drop a stray blank line.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-10-11 13:15:27 -04:00
Wajdi ELMuhtadi 9af50a7b19 drivers: sensor: wsen_tids: remove wsen_tids driver
Remove wsen_tids since the hal update
is no longer compatible with this version.

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-10-11 13:15:10 -04:00
Wajdi ELMuhtadi 8f684cfe9b drivers: sensor: wsen_pdus: remove wsen_pdus driver
Remove wsen_pdus since the hal update
is no longer compatible with this version.

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-10-11 13:15:10 -04:00
Wajdi ELMuhtadi 8c0b09ddc3 drivers: sensor: wsen_pads: remove wsen_pads driver
Remove wsen_pads since the hal update
is no longer compatible with this version.

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-10-11 13:15:10 -04:00
Wajdi ELMuhtadi 449bf8019c drivers: sensor: wsen_hids: remove wsen_hids driver
Remove wsen_hids since the hal update
is no longer compatible with this version.

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-10-11 13:15:10 -04:00
Wajdi ELMuhtadi 5f584052d8 drivers: sensor: wsen_itds: remove wsen_itds driver
Remove wsen_itds driver since the hal update
is no longer compatible with this version.

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-10-11 13:15:10 -04:00
Henrik Brix Andersen 164447a3c6 boards: st: stm32h745i_disco: m7: remove CAN sample-point properties
Remove explicit CAN controller sample-point/sample-point-data values and
instead rely on the defaults, as they change with the configured bitrate.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-10-11 13:14:40 -04:00
Benjamin Cabé 3af51ddce1 doc: boards: extensions: fix vendor selection from URL
Apply selection from the hash URL *after* having sorted the vendors
alphabetically.
Remove the initial call to updateBoardCount() as it is useless to
have one this early.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-10-11 13:14:29 -04:00
Benjamin Cabé a1261773db doc: boards: extensions: fix CSS rule
Fix a regression introduced at the last minute when cleaning up
the stylesheet. The rule as it was made no sense.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-10-11 13:14:29 -04:00
Benjamin Cabé a5ecd339d7 doc: boards: extensions: update code comment for consistency
Very minor fix for having consistent style in the coment

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-10-11 13:14:29 -04:00
Carles Cufi b0f6f1d33a Revert "lib: fix ubsan errors in cbvprintf_package"
This reverts commit 6f95a50553.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2024-10-11 13:13:49 -04:00
Quy Tran 4793e00ae8 boards: renesas: Add configurations to support pwm on EK-RA8D1
Add support for PWM driver on EK-RA8D1

Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
2024-10-11 09:28:29 +02:00
Quy Tran 1391355ac4 boards: renesas: Add configurations to support pwm on MCK-RA8T1
Add support for PWM driver on MCK-RA8T1

Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
2024-10-11 09:28:29 +02:00
Duy Phuong Hoang. Nguyen 59dbbb347d drivers: pwm: Initial support for PWM driver on RA8
Add PWM driver code support for RA8. This support is using
GPT HW

Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
2024-10-11 09:28:29 +02:00
Curtis Malainey 6f95a50553 lib: fix ubsan errors in cbvprintf_package
It is undefined behaviour to shift / add offsets to a null pointer.

Move to direct offset tracking to satisfy UBSAN.

Simple translation of code:
buf0 -> buf
buf +=/++ -> offset +=/++
buf = -> buf+offset =

Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
2024-10-11 09:28:21 +02:00
Lucas Dietrich d056455fce dts: Enable AES node in nucleo_l4a6zg.dts
Activate AES node in nucleo_l4a6zg.dts to enable testing of the
st,stm32l4-aes driver in CI.

Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
2024-10-11 09:28:12 +02:00
Lucas Dietrich 1d9af414d6 dts: stm32l4: Update AES node for stm32l4 series
The stm32l4 devices were previously assigned the generic STM32 AES driver,
which turned out to be incompatible with the stm32l4 series. This commit
updates the nodes to use the new driver specifically designed for this
series.

Add missing node for stm32l4a6, stm32l4q5, stm32l4s5 and stm32l486 socs.

It appears stm32l4p5 and stm32l496 socs do not have the AES accelerator
present, so the nodes are removed from the dts files.

Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
2024-10-11 09:28:12 +02:00
Lucas Dietrich 11abb5e4fc drivers: crypto: Fix pointer type warnings in STM32 AES driver
This patch resolves compiler warnings related to mismatched pointer types
between the STM32L4 and generic STM32 AES HAL by introducing CAST_VEC
macro.

Fix github CI warning

Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
2024-10-11 09:28:12 +02:00
Lucas Dietrich ad431dcc23 drivers: crypto: Add support for STM32L4 AES accelerator
This patch completes the addition of support for the STM32L4 AES
accelerator by introducing conditional handling for different STM32 AES
HAL variants. Key changes include:

- Created device tree bindings `st,stm32l4-aes` for STM32L4 AES
- Replaced `copy_reverse_words` with `copy_words_adjust_endianness`
to handle endianness conversion for different variants.

Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
2024-10-11 09:28:12 +02:00
Lucas Dietrich 8f0de8455d drivers: crypto: Refactor encryption and decryption functions for STM32 AES
This patch introduces a unified function pointer approach to handle
encryption and decryption operations for the STM32 AES accelerator.

- Replace separate `do_encrypt` and `do_decrypt` functions with a generic
`do_aes` function, using function pointers to AES HAL functions.

Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
2024-10-11 09:28:12 +02:00
Alexander Kozhinov fbeda5959d drivers: ethernet: eth_stm32_hal_priv.h
Remove unused missleading definition.

Signed-off-by: Alexander Kozhinov <ak.alexander.kozhinov@gmail.com>
2024-10-11 09:28:05 +02:00
Alexander Kozhinov 0036b8bf21 drivers: ethernet: eth_stm32_hal
Drop preprocessor redefinitions

Some preprocessor defines were redefined to follow
stm32 hal naming conventions.
People seems to be confused by redefines and use
them with alternating names.
This PR does not change code behaviour,
but shall increase it's readability.

Signed-off-by: Alexander Kozhinov <ak.alexander.kozhinov@gmail.com>
2024-10-11 09:28:05 +02:00