Commit graph

15456 commits

Author SHA1 Message Date
Krzysztof Chruściński
d5637ec374 tests: lib: cpp: cxx: Filter out all ARMs from nRF54x and nRF92
Instead of extending list of unsupported platforms use filter that
will exclude or current and next ARM cores from platforms with HAL
that does not support C++98.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-08 19:10:24 +01:00
Andries Kruithof
c9a9f0ab08 Bluetooth: Audio: Add tests for the CAP cancel command
This adds unittests and babblesim tests for the CAP cancel command

Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
2025-01-08 19:10:11 +01:00
Krzysztof Chruściński
1115cd5698 tests: drivers: uart: async_api: nrf54h20dk: Enable device PM
Enable device runtime PM for nrf54h20dk/nrf54h20/cpuapp where
fast UARTE (uart120) is tested.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-08 19:09:57 +01:00
Khoa Nguyen
5acf8a2935 tests: drivers: flash: Support test common for RA6, RA4
Add overlay to support test flash/commone for: ek_ra6m1,
ek_ra6m2, ek_ra6m3, ek_ra6m4, ek_ra6m5, ek_ra6e2, fpb_ra6e1,
fpb_ra6e2, ek_ra4m2, ek_ra4m3, ek_ra4e2

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
Signed-off-by: Phi Tran <phi.tran.jg@bp.renesas.com>
2025-01-08 17:02:36 +01:00
Neil Chen
96a9a5ea90 tests: drivers: uart: add uart_async_api support for frdm_mcxa156 board
add uart_async_api test support for frdm_mcxa156 board

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2025-01-08 17:01:53 +01:00
Anas Nashif
08ed0f3282 tests: kernel: common: use integration_toolchains
Use new keyword integration_toolchains to build test using additional
toolchains.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2025-01-08 12:58:59 +01:00
Yiding Jia
2bf61e51fe drivers: sensor: Fix TMAG5273/TMAG3001 by adding a TMAG3001 compatible
Fixes issue introduced in #76460

The previous code attempted to detect whether TMAG5273 or TMAG3001 was
connected based on DEVICE ID register. This doesn't work as the bits that
denote the version on one part are undefined on the other part, and cannot
be relied on to be zero.

This commit adds a TMAG3001 compatible which (for now) is just derived from
the TMAG5273 compatible. This allows TMAG3001 to be specified directly in
the DT. The driver code is updated to support both compatibles.

Signed-off-by: Yiding Jia <yiding.jia@gmail.com>
2025-01-08 09:33:02 +01:00
Emil Gydesen
e45830893f Bluetooth: CCP: Introduce new CCP API
The CCP API for the Call Control Profile works on top of the
TBS API, and will eventually replace parts of the TBS API.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-08 07:50:32 +01:00
Chris Friedt
c0e0fc5d7f tests: posix: fs: declare entry statically
qemu_x86/atom was failing tests/posix/fs in
test_fs_readdir_threadsafe for some reason and only for that
platform.

All other platforms pass the testsuite properly with the dirent
declared on the stack.

Declare the dirent object statically so that qemu_x86/atom will
pass test cases.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2025-01-08 01:29:06 +01:00
Chris Friedt
fa841fe7bd posix: fs: declare _POSIX_C_SOURCE in a consistent way
Declare _POSIX_C_SOURCE in a consistent way for both the
posix/options library as well as the tests/posix/fs
testsuite.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2025-01-08 01:29:06 +01:00
Tomi Fontanilles
561ee12597 tests: secure_storage: speed up psa.its.secure_storage.custom.transform
It would time out when run on-device due to the NVS setting backend being
incredibly slow once enough entries exist.

Also, rename the tests which use different store implementations to make
that explicit.

Fixes https://github.com/zephyrproject-rtos/zephyr/issues/83210.

Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
2025-01-07 18:24:33 +01:00
Neil Chen
1a4bc137c8 tests: drivers: can: timing: enable full timing test on frdm_mcxa156
Enable the full range of CAN timing tests on the NXP FRDM-MCXA156 board.

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2025-01-07 15:56:57 +01:00
Dominik Ermel
bb0fa0746b stream_flash: Enforce size to be explicitly present on init
The commit changes requirements for stream_flash_init, where size
can no longer be 0 and has to be explicitly set, to avoid situation
where size autodetection, invoked by size == 0, would miss changes in
layout and silently allow overflow of Stream Flash into other partitions.

There has also been new Kconfig option CONFIG_STREAM_FLASH_INSPECT,
set to y by default to keep legacy behaviour, that can be used to turn
off stream_flash_ctx vs device inspection, allowing user to shed
inspection code once it is not useful anymore.

Fixes: #71042

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2025-01-07 15:56:49 +01:00
Dominik Ermel
145dd119a1 tests/stream_flash: Improve platform filtering
Improve platform filtering of common platforms, replace extra_args
with extra_configs, where applicable and add little comment on why
certain options are used.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2025-01-07 11:51:49 +01:00
Marvin Ouma
6737f6b283 tests: posix: common: separate posix timer tests into a smaller testsuite
posix.common contains testsuites that can be separated into smaller
groups of tests. This change moves clock, sleep, nanosleep and timer
into a singular testsuite at tests/posix/timer app directory.

Signed-off-by: Marvin Ouma <pancakesdeath@protonmail.com>
2025-01-07 11:47:35 +01:00
Emil Gydesen
892e5e11fa tests: Bluetooth: BAP: Add broadcast tests with VS codec
A broadcast tests with various BASEs that use a vendor
specific (VS) codec. This tests that we support
non-LC3 codecs on both broadcast sources and sinks
in various configurations.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-07 10:11:00 +01:00
Emil Gydesen
cd98a34772 tests: Bluetooth: BAP: Move broadcast metadata update to new test
Split the default broadcast source test so that the reconfigure and
metadata update is not done in the generic test. This makes
the test simpler and easier to modify.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-07 10:11:00 +01:00
Emil Gydesen
9cfc546eba Bluetooth: Audio: Shell: Add logging and testing build tests
Added a test for disabled logging and for diabled testing
to ensure that the shell builds without error when those
are disbaled.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-07 00:27:17 +01:00
Krzysztof Chruściński
9af987d5d4 tests: drivers: uart: mix_fifo_poll: Add UARTE120 to nrf54h20dk test
Add configuration for UARTE120 fast instance. Use multi-instance capability
of the test to run same test on UARTE120 and slow UARTE peripheral.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-07 00:25:15 +01:00
Krzysztof Chruściński
146fa18b06 tests: drivers: uart: mix_fifo_poll: Tweak testcase.yaml
Do not use CONFIG_UART_NRFX_UARTE_LEGACY_SHIM=n because this option
is going to be deprecated and this option does not support all uart
instances (e.g. uart120). Limit testing of configuration with
CONFIG_UART_0_ENHANCED_POLL_OUT=y to legacy platforms. nrf54x
platforms have ENDTX-STOPTX short so this feature is not supported
and needed there.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-07 00:25:15 +01:00
Krzysztof Chruściński
b5807a98e1 tests: drivers: uart: mix_fifo_poll: Rework to support multi-instance
Rework test to allow testing multiple UART instances in a single
run.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-07 00:25:15 +01:00
Krzysztof Chruściński
90b4ddd87a tests: drivers: uart: mix_fifo_poll: Change fixture to uart_loopback
gpio_loopback fixture is used for single pair of shortened pins. For
this test 2 pairs are needed (cts-rts + tx-rx) so gpio_loopback does
not describe it correctly.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-07 00:25:15 +01:00
Fabrice DJIATSA
c7da46a243 tests: drivers: uart: uart_async_api: fix error on test_write_abort
With the changes made in PR #76061, only on the F429ZI platform, in
the test_write_abort test,the number of received data (2) is not equal
to the number of sent data (1). It looks like uart_tx_abort is done very
quickly, and the callback doesn't have enough time to deal with it.
Adding a small delay solves the problem and doesn't affect results on
other platforms.

Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
2025-01-06 20:34:17 +01:00
Fabrice DJIATSA
921e281ef0 tests: drivers: uart: uart_async_api: disable userspace permissions
Test cases on F746ZG work with USERSPACE config not enabled.
PR #80944 forces the use of the TEST_ENABLE_USERSPACE config with
the "select" statement instead of "imply," which is more restrictive
for test case dependencies.This leads to the error
"Memory region 0x2004d180 (size 8) write access denied" on boards.
By setting CONFIG_TEST_USERSPACE=n, the TEST_ENABLE_USERSPACE config will
not be enabled.

Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
2025-01-06 20:34:17 +01:00
Khoa Nguyen
bf1e996e42 tests: drivers: uart: Support test uart_async_api for Renesas RA8
Add overlay to support test uart_async_api for Renesas ek_ra8d1, mck_ra8t1

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2025-01-06 20:33:46 +01:00
Francois Ramu
04880448c7 tests: drivers: watchdog api testing on the stm32h7rs boards
Add the overlay file to run tests/drivers/watchdog/wdt_basic_api
on the nucleo_h7s3l8 and stm32h7s78_dk target boards

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2025-01-06 16:10:27 +01:00
Francois Ramu
556bf375a9 tests: drivers: adc api testing on the stm32h7s3l8 nucleo
Add the overlay file to run the tests/drivers/adc/adc_api
on the nucleo_h7s3l8

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2025-01-06 16:10:27 +01:00
Raffael Rostagno
16d7bbf63f tests: pwm_gpio_loopback: esp32: Add test overlays
Add test overlays for ESP32 devices.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2025-01-06 14:41:56 +01:00
Raffael Rostagno
ef96ed96cb tests: pwm: Add test suite with GPIO loopback
Add PWM test suite which uses GPIO as loopback input to check
the programmed timings.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2025-01-06 14:41:56 +01:00
Camille BAUD
0c3913962e boards: others: Introduce Pro Micro nRF52840 type
This introduces the pro micro nrf52840 board type,
commonly available as the cheapest nrf52840 development board,
and is based on the Nice!Nano

Signed-off-by: Camille BAUD <mail@massdriver.space>
2025-01-06 14:41:37 +01:00
Yong Cong Sin
1a578eb72c lib: os: mpsc_pbuf: do not wait when spinlock is held
Check if the spinlock is held before attempting to wait by
taking the semaphore, as that would cause a context switch which
isn't allowed and will trigger an assertion error when
`CONFIG_SPIN_VALIDATE` is enabled.

Logging in spinlock-held context when the log buffer is full can lead
to an infinite assertion error loop, as the logging subsys attempts to
allocate buffer when there's none available, it will try to wait for
one and thus triggers the assertion error, the error message will be
printed through the logging sybsys but there's no buffer available,
so it will try to wait for one and triggers another assertion error..
This loop just goes on and on forever, and nothing gets printed to
the terminal.

Added a test to validate the fix.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Signed-off-by: Maxim Adelman <imax@meta.com>
2025-01-06 06:53:52 +01:00
Fabian Blatz
e9dc495e55 tests: lib: gui: lvgl: Add testcase for OSAL implementation
This patch adds a testcase adding the OSAL to ensure the implementation is
built during CI.

Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2025-01-04 14:17:10 +01:00
Fabian Blatz
8ff8e2940a tests: lib: gui: lvgl: Migrate to version 9.2
With the update to v9.2.0 several Kconfig symbols were renamed or removed.
Adjust the test accordingly. Also several constants were renamed, rename
those also.

Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2025-01-04 14:17:10 +01:00
Tom Burdick
73f1156c5e llext: Remove simple from llext test
The simple path and naming wasn't really right, there are no other tests
and the test suite has become quite automated and extensable to cover
most things we'd like to test with llext. Building, loading, and linking
of course.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2025-01-02 09:19:35 +01:00
Chris Friedt
bc5aff3582 posix: options: fs: separate file_system_r to its own file
Move the functionality of POSIX_FILE_SYSTEM_R to its own
compilation unit and remove the unnecessary dependency on
POSIX_FILE_SYSTEM.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2025-01-02 09:18:57 +01:00
Chris Friedt
fc860e1010 tests: posix: fs: increase ztest stack size from 1k to 2k
The default stack size was causing qemu_arc/qemu_arc_em and
qemu_arc/qemu_arc_hs to fail when a dirent object was
stack-allocated.

Increase the default stack size to accomodate for additional
usage.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2025-01-02 09:18:57 +01:00
Chris Friedt
e967120b9a tests: posix: fs: correct arguments to readdir_r()
Previously, a NULL pointer was passed as the second argument to
readdir_r(). This is incorrect. The passed pointer should be
to a valid, externally-allocated struct direct.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2025-01-02 09:18:57 +01:00
Vinayak Kariappa Chettimada
3a8db2715f tests: bsim: Bluetooth: Add -RealEncryption=1 to pass in-system UT
BSIM tests that enabled CONFIG_BT_CTLR_TEST=y now require
-RealEncryption to pass the Controller's in-system unit test
of ECB module.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2025-01-01 02:04:33 +01:00
Vinayak Kariappa Chettimada
9678ff2041 Bluetooth: Controller: Include mem and ecb in-system tests
Include mem and ecb implementation in-system tests.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2025-01-01 02:04:33 +01:00
Fabio Baltieri
b716b0672d dts: ite: refactor the it8801 template hierarchy
The it8801 template is helpful but in the current state it does not
allow changing the device address as that is in the template itself. Fix
that by moving the template content down a level in the hierarchy, so
that it extends the mfd device itself rather than than instantiate it,
then the base instance can have any address, now the only limitation is
that only one instance is possible, but that is probably alright for
now.

Alternatives would be to use a define for the address, or even a
template per address, but this feels like a better compromise for now.
This may also use
https://github.com/zephyrproject-rtos/zephyr/pull/82825 in the future if
that ever becomes a thing.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-12-31 19:45:49 +01:00
Yishai Jaffe
0f948fdb1c soc: silabs: efr32xg23: add DMA support
Added DMA support to efr32xg23 socs and boards containing them.

Signed-off-by: Yishai Jaffe <yishai1999@gmail.com>
2024-12-30 19:47:19 +01:00
Simone Orru
2bd101132e kernel: Add tests for k_heap_calloc
Add tests for the k_heap_calloc function.

Signed-off-by: Simone Orru <simone.orru@secomind.com>
2024-12-30 17:32:03 +01:00
Jamie McCrae
1b70bfa14e tests: boot: mcuboot_recovery_retention: Fix testcase
Fixes an issue with the expected output of this test having
changed slightly

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-12-29 05:59:37 +01:00
Vinayak Kariappa Chettimada
fdf0ec2e5f tests: Bluetooth: BAP: Fix test wrt stream args to broadcast_source
Due to adding subgroup count and streams per subgroup
arguments to the broadcast_source test, fix the sink
test that was not ported due to being merged for change
in a different PR.

Relates to commit 01e8d0e3e0 ("tests: Bluetooth: BAP:
Add subgroup and stream args to broadcast_source").

Fixes commit 303d0b786f ("tests: Bluetooth: BAP: Add
test to test invalid bcode").

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2024-12-28 11:05:27 +00:00
Fabian Blatz
4966d620d3 tests: drivers: build_all: stepper: Adjust tmc2209 device instance
Adds the counter property to the tmc2209 node to ensure counter dependant
step-dir code is build by CI.

Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2024-12-28 04:37:05 +01:00
Armando Visconti
f9eceaebf9 drivers/sensor: lis2dux12: add lis2duxs12 support
The LIS2DUXS12 is a smart, digital, 3-axis linear accelerometer whose
MEMS and ASIC have been expressly designed to combine the lowest current
consumption possible with features such as always-on antialiasing
filtering, a finite state machine (FSM) and machine learning core (MLC)
with adaptive self-configuration (ASC), and an analog hub / Qvar sensing
channel.

(https://www.st.com/en/mems-and-sensors/lis2duxs12.html)

Signed-off-by: Armando Visconti <armando.visconti@st.com>
2024-12-27 19:34:46 +01:00
Emil Gydesen
fb1fcec983 tests: Bluetooth: Tester: More logging and verification for ISO RX
Add additional data to the logs and only send the event once we have
receive a successful SDU.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-27 14:09:29 +01:00
Emil Gydesen
38a32b768a tests: Bluetooth: BAP: Add broadcast tests with multiple subgroups
Add 4 new tests for BAP broadcast:
1) One subgroup with one stream per subgroup
2) One subgroup with two streams per subgroup
3) Two subgroups with one stream per subgroup
4) Two subgroup with two streams per subgroup

To support these, the number of broadcast streams and data paths
was updated to be up to 4.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-27 12:36:40 +01:00
Emil Gydesen
2b197aff02 Bluetooth: BAP: Modify range of BT_BAP_BROADCAST_SNK_SUBGROUP_COUNT
The range of BT_BAP_BROADCAST_SNK_SUBGROUP_COUNT should be relative to
BT_BAP_BASS_MAX_SUBGROUPS. The broadcast sink depends on the scan
delegator, and thus it does not make sense for the broadcast sink
to support more subgroups than what the scan delegator supports.

Since this no longer relates to the number of streams, there
may be new runtime errors if applications attempt
to sync to more subgroups than the number of ISO channels
supported.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-27 12:36:40 +01:00
Emil Gydesen
01e8d0e3e0 tests: Bluetooth: BAP: Add subgroup and stream args to broadcast_source
Add subgroup count and streams per subgroup arguments to the
broadcast_source test. This will allow us to run multiple
test setups using the same build and test case.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-27 12:36:40 +01:00
Emil Gydesen
0d933f4e46 tests: Bluetooth: BAP: Split bap_broadcast_audio.sh
Split the file into 2 so that each test script only runs a single test.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-27 12:36:40 +01:00
Jamie McCrae
5442687488 tests: cmake: snippets: Exclude sysbuild
Prevents sysbuild from being used as this adds a local snippet root
which should only be used (and tested) by application

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-12-27 07:18:13 +01:00
Jamie McCrae
06fd7389bd tests: cmake: Add sysbuild snippets test
Adds a new test that ensures sysbuild snippets work and are
applied correctly

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-12-27 07:18:13 +01:00
Khoa Nguyen
483a8df2f4 tests: drivers: i2c: Add support i2c_api test for RA4, RA2
Add conf and overlay to run i2c_api test on: ek_ra4w1,
ek_ra4m2, ek_ra4m3, ek_ra2a1

Signed-off-by: Tri Nguyen <tri.nguyen.wj@bp.renesas.com>
Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2024-12-26 17:20:23 +01:00
Cong Nguyen Huu
a4006e4d4e tests: bsim: bluetooth: audio fixes build failure
Fixes build failure, correct the variable is using for
k_sem_take in function test_sink_encrypted_incorrect_code

Fixes #83388

Signed-off-by: Cong Nguyen Huu <cong.nguyenhuu@nxp.com>
2024-12-26 09:31:21 +01:00
Luca Burelli
d492c849a3 tests: cmake: run zephyr_get() tests in script mode
Re-run the zephyr_get() testsuite in script mode after the project
mode testsuite has been executed. This is to ensure that the
zephyr_get() function works correctly in script mode as well.

Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
2024-12-26 09:31:11 +01:00
Torsten Rasmussen
4e29a35b22 cmake: use GLOBAL property instead TARGET properties for scoping
Targets are not available in script mode.
To support the Zephyr scoping feature used by snippets and yaml module
then this commit moves from using custom targets to use GLOBAL
properties for scopes.

A scope property is prefixed with `<scope>:<property>` to avoid naming
collisions.
A `scope:<scope-name>` global property is used to track created scopes.
Tracking valid scopes ensure that properties are only set on known
scopes and thus catches typos / naming errors.

Add zephyr_scope_exists() and zephyr_get_scoped() to abstract the
implementation details of the scoped property retrieval and refactor
current code to use them.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
2024-12-26 09:31:11 +01:00
Dawid Niedzwiecki
229c257522 tests: drivers: flash: stm32: fix uninitialized variable
Make sure not to accidentally enable WP by uninitialized variable during
FLASH_STM32_EX_OP_SECTOR_WP call.

Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
2024-12-25 18:03:06 +01:00
Quy Tran
d74020160f tests: subsys: fs: Support tests/subsys/fs on RA8 boards
Add overlay property node and configs to support tests/subsys/fs/ext2,
tests/fs/fat_fs_api and tests/subsys/sd on RA8 boards

Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
2024-12-25 06:33:12 +01:00
Théo Battrel
18c2ea2336 Tests: Bluetooth: Check GATT settings cleanup
Check that the GATT settings added when bonding to a peer and
subscribing to a CCC are correctly deleted when calling `bt_unpair`.

Testing hooks have been added in the Bluetooth settings abstraction
layer to know which key are being added/deleted.

Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
2024-12-24 16:07:32 +01:00
Seppo Takalo
4a7ef5c010 net: lwm2m: Convert tickeless to use eventfd()
For waking up the poll() use eventfd() instead of socketpair()
so we save some buffer space and one file descriptor.

Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
2024-12-24 13:54:39 +01:00
Mikkel Jakobsen
e4c21da41b drivers: fuel_gauge: make read-only pointer args const in api
For the lists of properties passed as a pointer to the get_props and
set_props functions, there is no reason to not make the pointer const as
the called functions will not and should not alter the pointed-to data.

In practice, not having the pointers const can cause compilation errors
if trying to pass in a const array of properties.

Signed-off-by: Mikkel Jakobsen <mikkel.aunsbjerg@escolifesciences.com>
2024-12-24 13:54:15 +01:00
Dawid Niedzwiecki
be5d44eb7e drivers: flash: stm32: update ex_op API
Use uint64_t instead of uint32_t for the FLASH_STM32_EX_OP_SECTOR_WP
extended operation.

Some chips have two banks, more than 16 sectors each e.g. stm32h7a3xx
chips, so more than 32 bits are required.

Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
2024-12-24 13:54:04 +01:00
Emil Gydesen
c5fc9a2b17 tests: Bluetooth: BAP: Add retry with correct broadcast code
Expand test_sink_encrypted_incorrect_code to retry the sync with
the correct broadcast code after failing the initial sync
with the incorrect broadcast code.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-24 13:53:34 +01:00
Peter Mitsis
31ebd6036a tests: Test k_reschedule() with deadline scheduler
Setting a deadline is not a schedule point. This makes it a
perfect place to verify the behavior of the new k_reschedule()
routine at both thread and ISR level.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2024-12-24 04:22:51 +01:00
Andrew Featherstone
498ded5dd9 tests: drivers: dma: Increase test coverage for RP2350A
Increase test coverage for Raspberry Pi's SoCs. Use the `socs` folder
rather than `boards` to enable these tests to run on any boards with the
same SoCs.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-12-23 23:57:57 +01:00
Andrew Featherstone
b6b38e6808 drivers: dma: rpi_pico: Refactor DMA files for Raspberry Pi SoCs
Avoid referring to Pico 2 (the name of a board). In this context,
RPI_PICO is used to refer to the (Zephyr) `SOC_FAMILY` rather than the
Pico 1 board. This clarifies common numerical values between the RP2040
and RP2350 SoC series, and enables existing DTS files to be used with
RP2350-based boards with fewer changes.

Remove the use of Zehpyr's `CONFIG_` macros from the device tree files,
and replace them with `SOC_SERIES`-specific files. Update the driver
implementation to conditionally include the correct file. Update
documentation and samples to match.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-12-23 23:57:57 +01:00
Andrew Featherstone
2d768fd3a5 rpi_pico2: rp2350: Add DMA support
Add initial support for the RP2350's DMA peripheral, allow tests
under drivers/dma/loop_transfer to run on on the Raspberry Pi Pico 2,
and update the board's documentation.

Signed-off-by: Manuel Aebischer <manuel.aebischer@belden.com>
Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-12-23 23:57:57 +01:00
Andrew Featherstone
aeecc3c282 tests: gpio_api_1pin: rpi_pico2: Support using external pulldowns
Extend gpio_api_1pin so that tests can require a test fixture to provide
an external pulldown resistor to the board under test. Use the new
test-gpio-external-pulldown device tree binding to define where that
GPIO is, and, finally, add a device tree overlay for the Raspberry Pi
Pico 2 board that defines where the pulldown provided by the fixture
will be.

Tested locally using `--fixture gpio_external_pull_down` when running
Twister on the command line, or by creating and using a Hardware Map
file, in combination with a modified Pico 2.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-12-23 23:57:57 +01:00
Andrew Featherstone
8bea756542 tests: drivers: adc_api: Add support for the Raspberry Pi Pico 2
For these tests' needs, the RP2350 on the Pico 2 is compatible with the
RP2040 on the Pico 1. #include the latter's overlay in preference to
duplicating the content.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-12-23 23:57:57 +01:00
Benedikt Schmidt
0603637fc7 tests: misc: test_build: add testcase for LTO with picolibc module
Add a testcase which builds with LTO and the picolibc module.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2024-12-23 22:00:53 +01:00
Sebastian Głąb
7c606c29c6 tests: drivers: gpio: gpio_basic_api: Enable test on nrf54l20pdk
Add overlay required to run gpio_basic_api test on nrf54l20pdk.

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
2024-12-23 17:10:17 +01:00
Jilay Pandya
59064a409e dts: bindings: stepper: add en-gpios to common stepper-controller.yaml
- rename enable-gpios to en-gpios in adi,tmc2209
- place en-gpios in common stepper-controller.yaml

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
2024-12-23 17:10:06 +01:00
Cory Andrew Mayer
8094f92cd3 tests: subsys/fs/nvs: add test for initializing bad region
Add unit test to exercise bad memory region recovery path

Signed-off-by: Cory Andrew Mayer <corymayer@meta.com>
2024-12-23 09:15:48 +01:00
Dominik Ermel
196fc5c36c storage/stream_flash: Make write callback optional
The commit adds Kconfig option CONFIG_STREAM_FLASH_POST_WRITE_CALLBACK
that allows to turn off support for callback invoked after data
is written to storage device.
If the feature is not used disabling it allows to save some storage.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-12-21 20:48:53 +01:00
Aleksander Wasaznik
e8c5405609 Bluetooth: Controller: Fix headroom reservation for ISO
Calling `net_buf_reserve` removed any previous reservation, which
includes the reservation by hci_ipc to hold the H4 type byte. This
resulted in a out-of-bounds net_buf_push in hci_ipc.

This commit also enables asserts in hci_ipc in the audio bsim test,
which reveal the out-of-bounds write.

Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
2024-12-21 05:52:37 +01:00
Raffael Rostagno
a249eb51f4 tests: drivers: counter: esp32c6: Add test config
Add test config files for ESP32C6 for GP and RTC timers.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-12-21 05:52:20 +01:00
Declan Snyder
8ed80ddb37 boards: mimxrt1060_evk: Convert to variants
Convert qspi and hyperflash to variants instead of revisions by popular
demand.

And convert evkb into a revision instead of a different board.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-12-20 22:59:59 +01:00
Declan Snyder
0cdb35d978 boards: mimxrt1050_evk: Switch to variants
Switch from using revisions for hyperflash/qspi to using variants, by
popular demand.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-12-20 22:59:59 +01:00
The Nguyen
8d2a9b3fac tests: memc: ram: support test for sdram controller on Renesas RA family
Add SDRAM controller test support

Signed-off-by: The Nguyen <the.nguyen.yf@renesas.com>
2024-12-20 23:53:37 +02:00
The Nguyen
07291fb6aa tests: display: add support test GLCDC on ek_ra8d1
This commit to add support to build tests/drivers/display on ek_ra8d1

Signed-off-by: The Nguyen <the.nguyen.yf@renesas.com>
2024-12-20 23:53:37 +02:00
Manuel Argüelles
c16ccf8e7d dts: bindings: rename nxp,kinetis-ftm-pwm compatible
Rename "nxp,kinetis-ftm-pwm" compatible to "nxp,ftm-pwm" to remove the
device family from its name.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-12-20 23:53:14 +02:00
Peter Mitsis
60b38d50db tests: latency_measure: Update README.txt
Updates the README.txt with more current sample output.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2024-12-20 23:51:02 +02:00
Peter Mitsis
b3b94731d5 tests: latency_measure: Remove timeslicing
Removes the timeslicing configuration from the latency
measure benchmark as its numbers are nearly identical
to the default. This makes sense as the benchmark was
not really designed for exercising the timeslicing
feature.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2024-12-20 23:51:02 +02:00
Keith Short
af1fbf8199 tests: drivers: Add PS8xxx driver
Add a build test to verify the parade,ps8xxx driver builds correctly.

Signed-off-by: Keith Short <keithshort@google.com>
2024-12-20 23:50:50 +02:00
Danh Doan
7c55a540f4 tests: drivers: pwm: Support RA2, RA4, RA6 to test pwm_loopback
Add overlay to support test pwm_loopback on boards: ek_ra2a1,
ek_ra4e2, ek_ra4m2, ek_ra4m3, ek_ra4w1, ek_ra6e2, ek_ra6m1,
ek_ra6m2, ek_ra6m3, ek_ra6m4, ek_ra6m5, fpb_ra6e1, fpb_ra6e2.

Signed-off-by: Danh Doan <danh.doan.ue@bp.renesas.com>
2024-12-20 18:31:12 +01:00
Danh Doan
2e0688878b drivers: pwm: update namming of pwm driver for RA family
- update namming for pwm driver.

Signed-off-by: Danh Doan <danh.doan.ue@bp.renesas.com>
2024-12-20 18:31:12 +01:00
Raffael Rostagno
ffa676dd44 tests: pwm_loopback: esp32c6: Add test config
Add test config file to test MCPWM loopback on ESP32C6

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-12-20 18:30:59 +01:00
Bjarki Arge Andreasen
0617bd306a tests: drivers: i2c: target api: add nrf5340 cpuapp
Extend i2c_target_api test suite with the nrf5340 cpuapp, using the
new TWIS device driver.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2024-12-20 16:14:05 +01:00
Seppo Takalo
341f78102a net: lwm2m: Need heap for native_sim
When using tickless mode, the socketpair()
seem to use heap by default on native_sim, so
add some space for it.

Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
2024-12-20 16:09:13 +01:00
Tim Lin
2821a9e588 test/driver/build_all: Modify the dts configure example of board for it8801
Modify the board file when using gpio, input and pwm drivers dts
configuration example for it8801.

test: west build -p always -b it82xx2_evb tests/drivers/build_all/gpio
      west build -p always -b it82xx2_evb tests/drivers/build_all/input
      west build -p always -b it82xx2_evb tests/drivers/build_all/pwm

Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
2024-12-20 12:36:21 +01:00
Maochen Wang
f6b3a022a9 tests: net: wifi: update DPP extra confis
Remove CONFIG_WIFI_NM_WPA_SUPPLICANT_CRYPTO_ENTERPRISE from DPP build
case.

Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
2024-12-20 10:19:14 +01:00
Dmitrii Golovanov
33a91daf3b tests: benchmarks: wait_queues: Record metrics
Enhance the wait_queue benchmark to output resulting summary
metrics as records, so when it runs with Twister the results
are parsed and saved into twister.json and recording.csv files
for further analysis.
Minor documentation edits and make ClangFormat happy.

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-12-20 08:33:14 +01:00
Dmitrii Golovanov
422c9d6c7b tests: benchmarks: wait_queues: Turn off verbose output
Turn off verbose output by default as described in the README.

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-12-20 08:33:14 +01:00
Dmitrii Golovanov
f3358259d6 tests: benchmarks: sched_queues: Record metrics
Enhance the sched_queue benchmark to output resulting summary
metrics as records, so when it runs with Twister the results
are parsed and saved into twister.json and recording.csv files
for further analysis.
Minor documentation edits and make ClangFormat happy.

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-12-20 08:33:14 +01:00
Dmitrii Golovanov
2fd8abef7f tests: benchmarks: sched_queues: Turn off verbose output
Turn off verbose output by default as described in the
README.

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-12-20 08:33:14 +01:00
Mariëlle Korthout
f5d71a3db3 tests: build_all: Add HS400x
Adds HS400x to build_all tests
Signed-off-by: Mariëlle Korthout <marielle.korthout.jc@renesas.com>
2024-12-20 03:18:19 +01:00
Gerard Marull-Paretas
b51f998063 tests: fix zephyr/drivers/gpio.h usage
Only include the header if using any of the GPIO API calls/
struct/defines.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2024-12-20 03:17:25 +01:00
Gerard Marull-Paretas
179576d059 tests: add missing CONFIG_GPIO=y
All tests using the GPIO API must enable the CONFIG_GPIO Kconfig
option.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2024-12-20 03:17:25 +01:00
Daniel Leung
f786ecc075 tests: mem_protect/mem_map: add data cache manipulations
This adds data cache manipulations, flushing and invalidation,
to the tests where buffer content are being written and
compared. These tests map different virtual pages to the same
physical pages, and write to one of the mapped virtual
addresses. Some SoCs may cache the virtual address separately
and writes to one virtual address will not be reflected to
another virtual address, this failing the comparison. So we
need to manually flush the cache after writing to the buffer,
and invalidating cache before reading. Note that not all reads
and writes need this treatment as some of them only needs to
test for access permissions, and not the memory content.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-12-19 21:54:16 +01:00
Daniel Leung
352fed6b21 tests: mem_protect/mem_map: limit CPUs to 1 if incoherent cache
For CPUs with incoherent cache under SMP, the tests to read/write
buffer (... majority of tests here) may not work correctly if
the test thread jumps between CPUs. So use the test infrastructure
to limit the test to 1 CPU.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-12-19 21:54:16 +01:00
Raffael Rostagno
f98868eb81 tests: uart_elementary: esp32: Add test configs
Add test configuration for ESP32 devices.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-12-19 19:56:06 +01:00
Raffael Rostagno
31ea95fb52 tests: uart_basic_api: uart_elementary: Get baudrate from device tree
Add option (BAUDRATE_FROM_DTS) to get baudrate value from
device tree, for devices which differ from standard (115200).

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-12-19 19:56:06 +01:00
Manuel Argüelles
bf7837b8ac dts: bindings: rename nxp,kinetis-rtc compatible
Rename "nxp,kinetis-rtc" compatible to "nxp,rtc" to remove the
device family from its name.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-12-19 19:55:43 +01:00
Riadh Ghaddab
e0f0256538 zms: optimize write function by skipping unnecessary reads
when performing a write ZMS checks if the data exists in the storage to
avoid double writing the same data and save some memory cycle life time.
However this downgrades the write performance.
Enable this feature only when CONFIG_ZMS_NO_DOUBLE_WRITE is enabled.

Signed-off-by: Riadh Ghaddab <rghaddab@baylibre.com>
2024-12-19 19:55:30 +01:00
Valerio Setti
3fa522c720 tests/samples: remove ENTROPY_GENERATOR from BT related tests/samples
Since now Mbed TLS automatically selects ENTROPY_GENERATOR (or the
test generator, depending on the platform) we can remove this dependency
from all BT related tests and samples.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-12-19 17:53:37 +01:00
Valerio Setti
aa64dd32f1 samples|tests: secure-storage: allow all test rng sources
Add MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG_ALLOW_NON_CSPRNG to the list of
test Kconfigs. Typical use case of this:

- the platform has "zephyr,entropy" defined in the devicetree which means
  that CSPRNG_AVAILABLE is set;
- for some reason the board actually does not have any entropy driver
  enabled (ex: ENTROPY_BT_HCI is disabled in nrf5340bsim when BT is _not_
  enabled in the build);
- since TEST_RANDOM_GENERATOR is enabled then also TEST_CSPRNG_GENERATOR
  would be;
- unfortunately the call to psa_generate_random() would fail in
  get_random_data() (in modules/mbedtls/zephyr_entropy.c) because
  MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG_ALLOW_NON_CSPRNG is not set and it would
  not reach "subsys/random/random_test_csprng.c".

This commit fixes this problem.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-12-19 17:53:37 +01:00
Jan Behrens
75463fe950 drivers: stepper: test: Added drv8424 to stepper_api and build_all tests
Adds the drv8424 stepper driver to the build_all/stepper test and the
stepper_api test. The later test is also modified to ensure compatibility.

Signed-off-by: Jan Behrens <jan.behrens@navimatix.de>
2024-12-19 15:21:44 +01:00
Jan Behrens
4bd2ab7e1d drivers: stepper: test: Added drv8424 driver tests
Adds 2 test suites for the drv8424 stepper driver, testing API conformity
and return values in the first suite and gpio pin values in the second
suite

Signed-off-by: Jan Behrens <jan.behrens@navimatix.de>
2024-12-19 15:21:44 +01:00
Pieter De Gendt
05b89ffafb tests: modules: nanopb: Test on Big Endian platform
Add a big endian test platform for validating serialization.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-12-19 15:20:11 +01:00
Sara Touqan
d7034e041c tests: drivers: i2c: Enable i2c2 for nucleo_u083rc board.
This commit enables I2C2 on nucleo_u083rc board
for i2c_target_api test.

Signed-off-by: Mohammad Badawi <zephyr@exalt.ps>
Signed-off-by: Sara Touqan <zephyr@exalt.ps>
2024-12-19 15:19:56 +01:00
Mohammad Badawi
fb5c4c9042 tests: drivers: adc: Enable DMA for nucleo_u083rc board for adc_api
Since DMA is supported by the nucleo_u083rc board, it should be enabled
in the board overlay for the ADC adc_api test, similar to the board
nucleo_h743zi.

Signed-off-by: Mohammad Badawi <zephyr@exalt.ps>
Signed-off-by: Sara Touqan <zephyr@exalt.ps>
2024-12-19 15:19:56 +01:00
Dominik Ermel
44e5f952ac tests/flash: Correct flash size for nrf52840 mx25 hi-perf tests
Correct expected flash size from flash_get_size.

Fixes #82619

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-12-19 15:19:32 +01:00
Dominik Ermel
9dad01c6dd tests/flash: Improve flash_get_size output on error
Now expected vs read size will be logged in case of error
to make it easier to understand problem or correct test
settings.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-12-19 15:19:32 +01:00
Jukka Rissanen
a2a0cc8074 tests: net: vlan: Add testing of link layer header embedding
Create a special Ethernet interface that supports link layer
embedding. Add a test that uses this special Ethernet interface
to verify that the L2 header is embedded to the first net_buf.

Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
2024-12-19 10:21:28 +01:00
Sebastian Głąb
df20c6d70f tests: drivers: watchdog: Run tests on nRF54L20pdk
Add overlays and align watchdog tests
to be executed on nrf54L20pdk.

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
2024-12-19 10:21:11 +01:00
Jukka Rissanen
9fcf424d41 tests: net: igmp: Add re-join multicast group test
Make sure we send IGMP report when re-joining the multicast group
when interface goes up after operative down event.

Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
2024-12-19 10:20:56 +01:00
Dominik Ermel
54435e000a storage/flash_map: Add FIXED_PARTITION_BY_NODE macro
Macro allows to instantiate flash_area object pointer from DTS node.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-12-19 07:07:07 +01:00
Andries Kruithof
b8428df7c6 tests: Bluetooth: CAP: remove compiler warning
There is an unused variable, which may result in a compiler warning.

Since we can not guarantee the value of this variable
we can not test for it, so it is removed.

Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
2024-12-19 04:19:01 +01:00
Robin Kastberg
3405648b7d tests: arm: remove GNUC ifdef
It is better to get compile error rather than #error

Signed-off-by: Robin Kastberg <robin.kastberg@iar.com>
2024-12-19 04:18:48 +01:00
Ryan McClelland
73af324c07 tests: drivers: sensor: add build_all for lsm6dsv16x
Add a build test for the i3c lsm6dsv16x.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-12-18 22:12:04 +01:00
Sylvio Alves
74d4008cc1 drivers: wifi: make WIFI_BUILD_ONLY_MODE global symbol
Convert vendor specific **_WIFI_BUILD_ONLY_MODE symbol as global
in order to provide common build flag to enable CI with no blobs.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2024-12-18 18:17:16 +01:00
Peter Mitsis
35435928c2 kernel: Decouple sleep from suspend
Sleeping and suspended are now orthogonal states. That is, a thread
may be both sleeping and suspended and the two do not interact. One
repercussion of this is that suspending a thread will no longer
abort its timeout.

Threads are now created in the 'sleeping' state instead of a
'suspended' state. This dovetails nicely with the start delay that
can be given to a newly created thread--it is as though the very
first operation that a thread with a start delay is a sleep.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2024-12-18 18:17:03 +01:00
Peter Mitsis
5710e034e7 kernel: Introduce _THREAD_SLEEPING state bit
At the present time, Zephyr does has overlap between sleeping and
suspending. Not only should sleeping and suspended be orthogonal
states, but we should ensure users always employ the correct API.
For example, to wake a sleeping thread, k_wakeup() should be used,
and to resume a suspended thread, k_thread_resume() should be used.
However, at the present time k_thread_resume() can be used on a
thread that called k_sleep(K_FOREVER). Sleeping should have nothing
to do with suspension.

This commit introduces the new _THREAD_SLEEPING thread state along
with some prep-work to facilitate the decoupling of the sleeping and
suspended thread states.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2024-12-18 18:17:03 +01:00
Karthikeyan Krishnasamy
b0389ce5b5 drivers: adc: add ads131m02 adc driver
ADS131M02 is Texas Instruments 2-channel, 24-Bit differential
input ADC which support wide range datarate.
Driver add support for adc read, channel configure, adc sampling
mode configuration and power management.

[1]. https://www.ti.com/lit/ds/symlink/ads131m02.pdf

Signed-off-by: Karthikeyan Krishnasamy <karthikeyan@linumiz.com>
2024-12-18 18:16:40 +01:00
Robert Lubos
3be01802cf tests: net: lib: http_server: Add tests for PUT/PATCH/DELETE methods
Add additional test cases which verify that the HTTP server code can
handle PUT/PATCH/DELETE request types.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2024-12-18 18:15:02 +01:00
Guillaume Gautier
ccf5e1ede2 tests: drivers: adc: api: add test for nucleo_f103rb with dma
Adds an ADC DMA test for Nucleo F103RB board now that support for it is
added in the ADC driver.
Reading multiple channels in F1 is only possible with the DMA, hence the
necessity to have a dedicated twister test for it.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2024-12-18 15:32:35 +01:00
Raffael Rostagno
30542797d9 tests: drivers: pwm: Revert PWM capture change for pulse check
Reverts a change regarding how the test checks the pulse output
from a capture event. A pulse capture will produce a value that has
the same polarity (and range) as programmed by pwm_capture().
Checking 'pulse_capture' against 'period - pulse' means expecting
the driver to return a capture value that is not inverted as well,
which would cause test cases to fail.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-12-18 15:32:23 +01:00
Jordan Yates
17925dde0e tests: zbus: channel_id: test channel IDs
Test the new channel identifiers.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-12-18 12:47:24 +01:00
Khoa Nguyen
40744c36d7 tests: drivers: adc: Support RA8, RA6, RA4 to test accuracy and api
Add overlay to support test adc_accuracy_test and adc_api in boards:
EK-RA8D1, MCK-RA8T1, EK-RA6M1, EK-RA6M2, EK-RA6M3, EK-RA6M4, EK-RA6M5,
EK-RA6E2, FPB-RA6E1, FPB-RA6E2, EK-RA4M2, EK-RA4M3, EK-RA4E2, EK-RA4W1

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2024-12-18 12:46:31 +01:00
Khoa Nguyen
d54353bce8 tests: drivers: adc: Remove test id for EK-RA8M1
- Remove test id device of ek_ra8m1 in testcase.yaml of
adc_accuracy_test

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2024-12-18 12:46:31 +01:00
Sebastian Głąb
eaf9992889 tests: drivers: retained_mem: Run test on nrf54l20pdk
Add overlays to execute retained_mem test on nrf54l20pdk.

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
2024-12-18 12:45:42 +01:00
James Roy
4553a21fe5 devicetree: Add DT_FOREACH_ANCESTOR macro
Add 'DT_FOREACH_ANCESTOR' macro to get a list of
ancestor node of a given node_id.

Signed-off-by: James Roy <rruuaanng@outlook.com>
2024-12-18 10:17:09 +01:00
Benjamin Bigler
f1087d2042 drivers: adc: tla202x: add support for tla2022 and tla2024
This extends the tla2021 driver to support tla2022 and tla2024

Signed-off-by: Benjamin Bigler <benjamin.bigler@securiton.ch>
2024-12-18 08:33:49 +01:00
Nathan Olff
6b03380778 tests: drivers: adc: adc_emul: write test for raw func set
write test for raw value func set function

Signed-off-by: Nathan Olff <nathan@kickmaker.net>
2024-12-18 08:33:26 +01:00
Nathan Olff
3f55e21691 tests: drivers: adc: adc_emul: add test for const raw value function
write test for raw const adc emul function

Signed-off-by: Nathan Olff <nathan@kickmaker.net>
2024-12-18 08:33:26 +01:00
Stoyan Bogdanov
92aeb787c7 drivers: gpio: max22190: Add MAX22190 octal input with diagnostics
Add max22190 gpio driver with input functionality, since device
support only input without output.

Implemented diagnostic functionality for all 8 channels
which include various check to over/under voltage and wire break.
Filtering configuration is done from devicetree on per channel
bases and is configured on chip start.

In case some fault condition occure FAULT pin drive LOW which
prop to FAULT registers to be read. Data is stored in data structure
for furter analizes and ERR message is printed in console.

Signed-off-by: Stoyan Bogdanov <sbogdanov@baylibre.com>
2024-12-18 03:04:46 +01:00
Aurelie Fontaine
e12b23d3de tests: sensor: update sensor compatible icm42670p
Update i2c and spi dtsi test to comply with new compatible icm42670p.

Signed-off-by: Aurelie Fontaine <aurelie.fontaine@tdk.com>
2024-12-18 03:04:31 +01:00
Raffael Rostagno
b98bedeeb9 drivers: mcpwm: overlays: Move test config files
Move test config files to 'socs' folder, for cleanup.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-12-17 23:14:19 +01:00
Jiafei Pan
968b22802d tests: gpio: basic_api: not use pull up if it is not supported
Don't use pull_up if it is not supported by GPIO controller, so that
can make the test is not broken.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
2024-12-17 23:13:40 +01:00
Matías Román Camilletti
4ca5acac45 dsp: utils: Implemented float/fixed type conversions
The DSP library does not provide functions to convert fixed
representations (Q7,Q15,Q31) to float or double and viceversa. This commit
implements those functions using a shift argument to indicate the number
of decimal places.

Signed-off-by: Matías Román Camilletti <matias.camilletti@owl-services.com>
2024-12-17 20:55:27 +01:00
Guennadi Liakhovetski
527d1020fe llext: add a detached section test
Test LLEXT "detached section" functionality. This adds a test to load
an extension with a function placed in an ad-hoc section and run a
function in it.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2024-12-17 20:55:15 +01:00
William Tambe
f510314a28 tests: guard variable used only with CONFIG_TRACE_SCHED_IPI
Change to prevent build failure when CONFIG_SCHED_IPI_SUPPORTED is
defined and CONFIG_TRACE_SCHED_IPI is not.

Signed-off-by: William Tambe <williamt@cadence.com>
2024-12-17 20:54:48 +01:00
Emil Gydesen
62f90c62ab tests: Bluetooth: Tester: Refactor audio TX
Instead of relying on the bap_send_cmd and a ring buffer,
the tester will now automatically start transmitting on
streams can that transmit once they enter the streaming state,
and stop again once once they leave the streaming state.

This ensures that we are always sending, which help pass
the PTS tests that require us to send, without having the
autopts client constant telling the tester to send.

This also ensures that we actually send SDUs of the right size
by not relying on a ring buffer, but using a separate thread
that sends data from a predefined array of ISO mock data.

This is easily expandable to multiple streams (including a mix
of unicast and broadcast) using different SDU sizes and easy to
expand to also use one or more software codecs.

The design is based on the TX thread for the BAP Unicast
Client sample and the audio babblesim tests.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-17 17:53:23 +01:00
Bjarki Arge Andreasen
3c7e49956d tests: drivers: clock_control: nrf: add global hsfll clock
Extend test suite to test global HSFLL clock.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2024-12-17 15:22:37 +01:00
Vinayak Kariappa Chettimada
8e3bf831d4 tests: bsim: Bluetooth: Multiple single central to multilink peripheral
Test covering multiple single link central devices
connecting to single multilink peripheral device.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2024-12-17 15:22:18 +01:00
Vinayak Kariappa Chettimada
1aa68de993 tests: bsim: Bluetooth: Single multilink central to multiple peripheral
Test covering single multilink central device connecting to
multiple single link peripheral devices.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2024-12-17 15:22:18 +01:00
Vinayak Kariappa Chettimada
6794b5ebf2 tests: bsim: Bluetooth: Enable GATT client in multiple_id test
Enable GATT Client, MTU exchange in the multiple_id bsim
test.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2024-12-17 15:22:18 +01:00
Vinayak Kariappa Chettimada
5f06511e91 samples: Bluetooth: Update central multilink and peripheral identity
Update central multilink sample to use continuous scanning
to speed up connection setup.

Update peripheral identity sample to be configurable for
bsim testing as multiple devices with configurable count
of supported connections.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2024-12-17 15:22:18 +01:00
Fabio Baltieri
8a92eec91b tests: secure_storage: fix the platform_allow list
It really wants to be a list list, not a space list.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-12-17 13:41:16 +01:00