Commit graph

96296 commits

Author SHA1 Message Date
Sebastian Bøe 80209e4fd0 boards: nordic: 54L: Refactor the board DT
Refactor the 54L board file to be able to better support out-of-tree
non-secure boards.

This aligns better with nrf53's DT.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2024-05-24 18:00:47 -04:00
Sebastian Bøe 90332b9a0b dts: nordic: 54l: Change the peripheral address map for ns
Define peripherals with the 0x4000_0000 address range when building
for non-secure.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2024-05-24 18:00:47 -04:00
Sebastian Bøe 2c19d3ea92 dts: nordic: 54l: Don't define UICR for the non-secure domain
Don't define UICR for the non-secure domain as it is hardware fixed to
secure.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2024-05-24 18:00:47 -04:00
Sebastian Bøe 50aaaa30c2 dts: nordic: 54l: Don't define wdt30 for the non-secure domain
Don't define wdt30 for the non-secure domain as it is hardware fixed
to secure.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2024-05-24 18:00:47 -04:00
Sebastian Bøe afbaaf241d samples: wdt_basic_api: nrf: Add missing nrf overlays
Add missing nrf overlays to fix the sample at build time.

Copied from samples/drivers/watchdog/boards.

It is not clear why the build failure was not detected earlier.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2024-05-24 18:00:47 -04:00
Sebastian Bøe 9ef16f55cd boards: nordic: 54l: use wdt31 instead of wdt30
Use wdt31 instead of wdt30 as wdt30 is hardware fixed to secure.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2024-05-24 18:00:47 -04:00
Andrzej Kaczmarek a6e17b34f6 soc: renesas: smartbond: Fix exiting from suspend state
We need to enable irqs that were disabled when entering suspend state.

Signed-off-by: Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
2024-05-24 18:00:23 -04:00
Ederson de Souza 2654fdc6ba doc/services/llext: Mention the LLEXT EDK
Mention the EDK existence, the build target and discuss some features.

Signed-off-by: Ederson de Souza <ederson.desouza@intel.com>
2024-05-24 18:00:00 -04:00
Flavio Ceolin ca6f2d6ba5 maintainers: crypto: Add crypto documentation in its section
Add crypto related docs in the crypto section.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-05-24 17:59:38 -04:00
Andrzej Głąbek 9c874f0b93 samples: nrfx_prs: Fix pin assignment on nRF5340 DK
Pins P0.06 and P0.07 are shorted on nRF5340 DKs prepared for on-target
tests because that is required for UART tests. That causes background
SPIM transfers in this sample to fail because SPIM is not able to drive
its SCK line configured as P0.06. Rearrange then the pins used in this
sample, so that SCK is not on a pin involved in a GPIO loopback.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2024-05-24 10:00:07 -05:00
Alberto Escolar Piedras ab50b375e5 tests/posix/env: set CONFIG_PICOLIBC=y
Chosing by default in the prj.conf
PICOLIBC ensures we also use an embedded
libC even when built for a native target
and even if we dont set POSIX_API.

This ensures the test will build and pass
properly when built with default configuration
from command line without using the test yaml.

This change does not affect the build result
for other targets as those defaulted already
to PICOLIBC.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-05-24 09:57:31 -05:00
Francois Ramu 6db2c2c2c1 drivers: rtc: stm32 rtc driver disable alarm interrupt if not used
Note that the Init of the alarm has no need for BCD2BIN conversion,
the LL_RTC_ALMx_Init will do. Add more log debug
The driver must clear the ALARM enable bit before wrting the alarm
registers.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-05-24 09:56:29 -05:00
Francois Ramu 2499a4b226 drivers: rtc: stm32 rtc driver configure time and Date
Set a Calendar using the LL functions LL_RTC_TIME_Init
and LL_RTC_DATE_Init. Add more DBG info
On the stm32F2 serie, check RS Flag after setting calendar registers.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-05-24 09:56:29 -05:00
Francois Ramu 362588037e tests: drivers: rtc api testing with timeout
Add a timeout to the tests/drivers/rtc_api testcase so twister
can end properly when running with twister.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-05-24 09:56:29 -05:00
Babak Arisian b0dceffacc Bluetooth: Audio: add bt_audio_get_chan_count
Implement a function bt_audio_get_chan_count that takes an enum
bt_audio_location and returns the number of channels in that value.

This PR fixes #69617
(https://github.com/zephyrproject-rtos/zephyr/issues/69617)

Signed-off-by: Babak Arisian <bbaa@demant.com>
2024-05-24 09:55:37 -05:00
Dmitrii Golovanov d38913ba48 tests/kernel/timer/timer_behavior/pytest: aligh grpcio version
Align grpcio version with logic2-automation package fixing its fail
on Channel.unary_unary() call with missing _registered_method argument..

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-05-24 09:54:05 -05:00
Flavio Ceolin f54232e912 intel_adsp/ace: power: Do not re-implement cache func
Do not re-implement a function to get a cached pointer. Zephyr cache
API already provides it.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-05-24 09:53:04 -05:00
Flavio Ceolin 693b65583c power_domain: intel_adsp: Use register definitions
Make it a little bit easier to read using already existent
definitions for the registers used here.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-05-24 09:53:04 -05:00
Flavio Ceolin b496d0e52d intel_adsp/ace: pm: Remove unnecessary cache flush
soc_cpus_active is not in cached memory.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-05-24 09:53:04 -05:00
Flavio Ceolin c335cb542c intel_adsp/ace: pm: Keep irq locked until restore context
Keep interruptions locked until we properly restore the core
context.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-05-24 09:53:04 -05:00
Flavio Ceolin e728adffd2 intel_adsp/ace: pm: Remove unnecessary cache flush
core_desc is not located (nor is accessed) in cached memory.
There is no need to flush it.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-05-24 09:53:04 -05:00
Flavio Ceolin 301055dec0 intel-adsp/ace: pm: Only core 0 can d0i3
Secondary cores are not allowed to be power gated on
runtime-idle. They have to explicitely set off by host command.

Remove this state from secondary CPUs so power management logic
does not need workarounds to enforce this behavior.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-05-24 09:53:04 -05:00
Maciej Perkowski 48665f2636 scripts: Allow using quarantine mechanism with test_plan.py script
In twister, applying quarantine is a part of apply_filters() function.
However, this function is not called when --load-test is used.
Therefore, if one wants to use quarantines in combination with
dynamic scope from the test_plan.py script, one has to pass such
info through the script.

Signed-off-by: Maciej Perkowski <Maciej.Perkowski@nordicsemi.no>
2024-05-24 08:25:20 -04:00
Andrzej Głąbek 418210dbf3 tests: drivers: wdt_basic_api: Allow testing without PAUSE_HALTED_BY_DBG
This is a follow-up to commit e53e5448ee.

In the above commit, the calls to `wdt_setup()` were modified to use
the `WDT_OPT_PAUSE_HALTED_BY_DBG` option to prevent problems with
flashing of boards after this test was executed on them (the still
active watchdog could interrupt such flashing), but this option
is not essential to the test itself. And if a watchdog driver does not
support pausing when the CPU is halted by a debugger (this is the case
for example for wdt_counter), it is not able to pass the test because
of that option. Add then the possibility to continue the test when
pausing by debugger is not supported.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2024-05-24 08:24:56 -04:00
Andrzej Głąbek ccedcd1ac0 tests: drivers: wdt_basic_api: Add missing failure indications
Two API calls that are supposed to set up the watchdog are not actually
causing the test to fail, only error messages are printed. This patch
adds the proper return statements.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2024-05-24 08:24:56 -04:00
Nikolay Agishev 84898f62a3 DOC: ARCMWDT: Add tip for arc-gnu-toolchain installation
Installation of single toolchain causes problems for customers who
are not familiar with Zephyr infrastructure. This tip is supposed
to help them.

Signed-off-by: Nikolay Agishev <agishev@synopsys.com>
2024-05-24 08:05:39 -04:00
Alexander Sarmanow 1ed18ad5b2 samples: bluetooth: df: fix misleading comment in rx overlay
The comment is talking about Tx and AoD, while this sample code is about
Rx and AoA.

Signed-off-by: Alexander Sarmanow <asarmanow@gmail.com>
2024-05-24 08:05:19 -04:00
Kapil Bhatt cc42d16b1c net: wifi: Add disconnection success code
When disconnect request is successful, the status
was taking as WIFI_REASON_DISCONN_UNSPECIFIED only.
Adding WIFI_REASON_DISCONN_SUCCESS which can be help
to determine status of disconnect request. If this status
is failed then reason can be useful.

Signed-off-by: Kapil Bhatt <kapil.bhatt@nordicsemi.no>
2024-05-24 08:04:59 -04:00
Ping Wang 1339ce4bf0 Bluetooth: Audio: Get function for bt_audio_codec_qos_pref.
Get the preferred QoS settings via bt_bap_ep_get_info()
Therefore no need to use the internal header file to get it.

This PR fixes https://github.com/zephyrproject-rtos/zephyr/issues/72359

Signed-off-by: Ping Wang <pinw@demant.com>
2024-05-24 08:04:45 -04:00
Jerzy Kasenberg bd6bb64d8a drivers: timer: smartbond: Fix timer2 timeout set
When function sys_clock_set_timout() is called with small value
(i.e. 1) calculated time to be programmed to TIMER2 reload
register may be such that is expires before code set's it
up. In that case timer interrupt will be scheduled in far
future.

With this change, code checks after it sets reload value if
requested time already passed and if so TIMER2 interrupt
is marked as pending to avoid races.

Signed-off-by: Jerzy Kasenberg <jerzy.kasenberg@codecoup.pl>
2024-05-24 08:04:18 -04:00
Celina Sophie Kalus bbbb2865c3 dts: stm32h7_dualcore: Add MBOX driver
Adding the new STM32 hardware semaphore driver into the device tree.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Celina Sophie Kalus 59bfe591ef samples: drivers: mbox: Add support for stm32h747i_disco board
With the addition of the STM32 hardware semaphore MBOX driver, this
sample is now supported by the board.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Celina Sophie Kalus 3290da8f1d samples: ipc: icmsg: Add support for stm32h747i_disco
With the addition of the STM32 hardware semaphore MBOX driver, ICMsg is
now supported on the stm32h747i_disco board.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Celina Sophie Kalus 7da8ca3113 samples: ipc: icmsg: Do not return busy error codes
When sending a lot of data, a busy error code returned by the IPC is to
be expected. But if the last attempted send returns busy, this error
code is returned to the calling function, causing an error log message.
Fix this by setting return variable to 0 on this acceptable error.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Celina Sophie Kalus 9e0d4ef88f samples: ipc: icmsg: Add received bytes metric
By adding this metric, any problem with the remote core sending messages
is observable.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Celina Sophie Kalus e178d21b96 dts: bindings: ipm: Add dummy mbox-cells property
The MBOX driver interface expects a device tree property '#mbox-cells'
which is not known by the IPM driver. This causes build problems when
both drivers are given for a single shared DT node.

To fix this problem for this driver specifically, add a dummy
'#mbox-cells' property to the bindings of the STM32 HSEM IPM driver.
This does not affect any other IPM driver, and the STM32 HSEM IPM driver
is still functioning with this dummy property.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Celina Sophie Kalus e1ec8f5884 dts: bindings: mbox: Add STM32 HSEM MBOX driver
Add a device tree binding for the new driver. Since there already
exists an IPM driver using the unsharable hardware semaphore interrupt,
the new driver is not added to any boards or SOCs per default to avoid
compatibility problems. See #37300 for the IPM driver.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Celina Sophie Kalus 051dc14bb6 drivers: mbox: Add driver for STM32 HSEM
This driver implements a simple MBOX device which supports a single
instance, two channels (one for each direction), and only signalling
mode with no data transfer. Signalling to another core is achieved by
taking and giving two hardware semaphores, similar to the STM32 HSEM
IPM driver.

Signed-off-by: Celina Sophie Kalus <hello@celinakalus.de>
2024-05-24 07:52:06 -04:00
Andrew Davis 39863b66bd lib: open-amp: Use struct fw_resource_table type instead of void
The type of the resource table is known, casting to and from void* only
hides this type which can prevent the compiler from giving helpful
warnings. One warning would have been the accidental use of
"st_resource_table" in a cast, a struct which does not exist.

Use the fw_resource_table type when dealing with resource tables.

Signed-off-by: Andrew Davis <afd@ti.com>
2024-05-24 07:51:42 -04:00
Andrew Davis 4c5eb92650 lib: open-amp: Use fixed width types for resource table
This structure is shared between cores which may have different type
widths. Use fixed width types when defining the structure. We can
also use struct resource_table to help as it is already defined with
fixed width types and removes the need to redefine these elements.

Signed-off-by: Andrew Davis <afd@ti.com>
2024-05-24 07:51:42 -04:00
Robert Hancock 1af474b575 flash: spi_nor: error-checking fixes
Check the return values of commands such as spi_nor_cmd_* and
spi_nor_wait_until_ready and ensure they are propagated back to the
caller on error.

Signed-off-by: Robert Hancock <robert.hancock@calian.com>
2024-05-24 07:51:20 -04:00
Krzysztof Chruściński c026b55fe5 tests: drivers: clock_control: nrf_lf_clock_start: Fix SYNTH test
Test was not covering nrf54l15 which had Synth source bitfield
renamed. Changing the test to use Kconfig to determine if
Synth is present.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-05-24 07:50:53 -04:00
Alex Bellon a655deb046 docs: security: Create CVE-2024 section
Create new section for CVE-2024.

Signed-off-by: Alex Bellon <github@alex-bellon.com>
2024-05-24 07:50:38 -04:00
Dominik Ermel deabfa3c3a drivers/flash/spi_nor: Fix and rework spi_nor_set_address_mode
The commit removes unneeded check for enter_4byte_addr_exist in
the function, as the utility function is supposed to set the address
by parsing enter_4byte_addr parameter, while the enter_4byte_addr_exist
used to exist only for DTS entries that directly set enter-4byte-addr
parameters for a flash node.

The change also moves LOG_DBG reporting enter_4byte_addr before
it is processed, to allow logging what actually function will be working
with, before it does so.

The enter_4byte_addr_exist is removed as it is no longer used anywhere.

Setting of data->flag_access_32bit has been moved in the same code block
as call to the spi_nor_cmd_write, as it can be only consequence of
successful call to that function.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-05-24 07:50:25 -04:00
Aurelien Jarno 18c73de93d drivers: spi: stm32: Skip pinctrl suspend/resume for subghzspi
Subghzspi instances cannot have any pinctrl configs. This causes a
failure of the power management suspend and resume operations for the
subghzspi instance because no "default" pinctrl is found.

Fix that by skipping the pinctrl parts on subghzspi instances.

At the same time fix a copy and paste in the suspend error message.

Fixes: b567a7db83

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2024-05-24 07:50:09 -04:00
Piotr Kosycarz 8ba222c56a samples: subsys: ipc: ipc_service: keep using remote harness
Temporary solution as there is no such harness as remote.
However console regex are not defined yet.

Signed-off-by: Piotr Kosycarz <piotr.kosycarz@nordicsemi.no>
2024-05-24 07:49:57 -04:00
Tomasz Chyrowicz 7d23bd2859 boards: nrf54h20dk: Add SUIT storage definition
Add a definition of SUIT storage, so there will be a common source of
the SUIT storage location for both SDFW and scripts generating SUIT
storage areas, assigned to local domains.

Signed-off-by: Tomasz Chyrowicz <tomasz.chyrowicz@nordicsemi.no>
2024-05-24 07:49:42 -04:00
Yong Cong Sin e993e994ea sensors: add new channel SENSOR_CHAN_POS_DXYZ
Add new channel: `SENSOR_CHAN_POS_DXYZ`, so that it is
consistent with other 3-axis channels.

Updated pytest, `sensor_shell` & `fake_sensor` accordingly.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-05-24 07:49:27 -04:00
Yong Cong Sin 4e7168028b sensors: shell: use SENSOR_CHANNEL_3_AXIS whenever possible
Instead of specifying 3 axis channels manually, use
`SENSOR_CHANNEL_3_AXIS` instead.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-05-24 07:49:27 -04:00
Yong Cong Sin c13105750d samples: sensor: sensor_shell: update pytest to validate fix
Update the pytest script to exercise the entire
`sensor_channel_name` table with `parse_named_int()`.

The `gauge_desired_charging_current` is selected because
it is the last one in the table before `all`, `all` is not
used because `sensor get sensor@0 all` doesn't return anything.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-05-24 07:49:27 -04:00