Commit graph

1798 commits

Author SHA1 Message Date
Alberto Escolar Piedras
fc87d05b15 tests/subsys/input: Don't test on native_posix
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-09-25 04:04:36 -04:00
Alberto Escolar Piedras
aedafdf19b tests/subsys/fs: Don't test on native_posix
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-09-25 04:04:36 -04:00
Alberto Escolar Piedras
a848f7d1b2 tests/subsys/emul: Don't test on native_posix
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-09-25 04:04:36 -04:00
Alberto Escolar Piedras
0bef883cc3 tests/subsys/dfu: Don't test on native_posix
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-09-25 04:04:36 -04:00
Alberto Escolar Piedras
38c8c7c3f9 tests/subsys/debug/mipi_stp_decoder: Switch from native_posix to native_sim
native_posix is now deprecated.
Let's use native_sim instead.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-09-25 04:04:36 -04:00
Alberto Escolar Piedras
9380f61f26 tests/subsys/debug/cs_trace_defmt: Switch from native_posix to native_sim
native_posix is now deprecated.
Let's use native_sim instead.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-09-25 04:04:36 -04:00
Alberto Escolar Piedras
24696aec43 tests/subsys/bindesc: Don't test on native_posix
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-09-25 04:04:36 -04:00
Fin Maaß
9ab8eee875 tests: logging: log_output: add cases for timestamps
add cases for the different timestamp formats.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2024-09-24 14:29:02 -05:00
Daniel Leung
71bea33894 tests: debug/coredump: crash from user thread if userspace
Modify the test to spawn a user thread if it is running
with userspace enabled. This allows testing coredump when
the crashing thread is a user thread.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-09-21 11:29:39 +02:00
Pisit Sawangvonganan
9ae9873f12 style: tests: remove unnecessary return statements
For code clarity, remove unnecessary `return` statements
in functions with a void return type they don't affect control flow.

Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
2024-09-20 11:06:55 +02:00
Kamil Piszczek
8c0bc54ab0 mgmt: mcumgr: transport: bluetooth: add all gatt permission levels
Added new Kconfigs for defining permission level of GATT
characteristics that are part of the Bluetooth SMP service in the
MCUmgr subsys.

Removed the CONFIG_MCUMGR_TRANSPORT_BT_AUTHEN as the new Kconfig
options are mutually exclusive and need to be groupa as the Kconfig
choice option.

Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2024-09-19 15:13:19 +02:00
Flavio Ceolin
0047d31eb9 intel_adsp: cavs20: Remove legacy files
Remove cavs20 leftover files.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-09-19 03:26:53 -04:00
Flavio Ceolin
72f2a04f7d intel_adsp: cavs18: Remove legacy files
Remove cavs18 leftover files.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-09-19 03:26:53 -04:00
Arkadiusz Cholewinski
9d9089edd0 ztest: Add Support for Multiple Test Runs.
Introduces new kconfig options to enable multiple test runs in the ztest.

Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
2024-09-18 15:32:28 +02:00
Guennadi Liakhovetski
665e69d71d llext: (cosmetic) fix a name in an error message
test_dependent() was changed to test_entry() but one location was
missed - in a warning message string. Fix it too.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2024-09-17 17:49:29 +01:00
Anas Nashif
0bca19588a tests: remove misnamed platforms from platform_exclude
Few tests with wrongly names platforms. This section is now being
verified for correctness like all others.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-09-16 10:07:51 +02:00
Tom Burdick
db22e1a3f0 tests: Fix the platform exclude board name
qemu_xtensa_dc233c didn't pan out like I expected, needed to be
qemu_xtensa/dc233c/mmu to be excluded.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-09-12 17:05:24 -04:00
Guennadi Liakhovetski
96852bc45e llext: add a test for inter-extension linking
This test uses two LLEXT objects: one of them exports a symbol and
the other one calls the exported function.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2024-09-12 13:02:59 -04:00
Guennadi Liakhovetski
697c5fd80e llext: test-simple: replace ARRAY_SIZE() with sizeof()
When identifying the size of an extension image we simply need its
size in bytes, not the number of array elements, that contain it.
Both happen to return the same value, because we use arrays of bytes,
but using sizeof() is clearer.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2024-09-12 13:02:59 -04:00
Adam Wojasinski
3082b9c509 llext: Add aarch64 to LLEXT tests
Include `qemu_cortex_a53` (ARMv8-A ISA) target in intergation platforms
for LLEXT subsys tests.

Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
2024-09-12 14:48:55 +02:00
Tom Burdick
73cde7242e rtio: Disable xtensa dc233c
This particular qemu platform seems to run into a strange TLB exception
with unclear cause. Disable the test suite on xtensa qemu for the time
being.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-09-10 17:16:50 -04:00
Tom Burdick
4dc082da37 rtio: Fix dc233c tlb exception
It appears some strangeness occurs around the consume semaphore today
that causes a TLB exception on qemu_xtensa_dc233. Unclear *why* just yet
but this fixes things in CI today.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-09-10 12:40:21 -04:00
Tomasz Moń
7282e4ee3d tests: usb: uac2: test High-Speed only instance
Add and verify against reference descriptors a High-Speed only 192 kHz
24-bit stereo headphones with explicit feedback UAC2 instance.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2024-09-10 14:41:32 +01:00
Tomasz Moń
dd4ec82477 tests: usb: uac2: test High-Speed descriptor macros
Generate and test both Full-Speed and High-Speed descriptors against
reference values. Verify that IAD, interface and endpoint descriptors
are not shared between Full-Speed and High-Speed descriptor sets because
the number of non-UAC2 interfaces can be different at different speeds
and thus the assigned interface numbers and endpoint numbers can differ.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2024-09-10 14:41:32 +01:00
Tomasz Moń
de8710bf46 usb: device_next: uac2: Handle speed properties
Generate full and high speed descriptors based on UAC2 instance
properties. Fail the build if an instance does not have speed properties
or if the instance with given speed property exceeds the bandwidth
available at the selected speed.

Remove obsolete no longer used macros to determine offsets inside
complete UAC2 descriptors blob. Only speed-specific descriptors arrays
are supported.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2024-09-10 14:41:32 +01:00
Tomasz Moń
462077b2f2 tests: usb: uac2: Add speed properties to UAC2 instances
Add full-speed property to build all configuration and to UAC2
descriptor tests because this is what the tests were written for
(UAC2 class originally was full-speed only and there were no speed
properties available).

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2024-09-10 14:41:32 +01:00
Luca Burelli
dfef264bed tests/llext: add init_fini test
Add a test to check the proper support of ELF init arrays, using
the new llext_bootstrap function in place of llext_entry in the
LLEXT test suite.

Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
2024-09-10 14:41:17 +01:00
Luca Burelli
92385a90d8 tests/llext: refactor: rename perm_setup to test_setup, add test_cleanup
This commit renames the perm_setup callback to test_setup and provides
the extension as an additional parameter. It also adds a test_cleanup
callback that is called after each test completes.

Setup and cleanup functions are now called regardless of whether
CONFIG_USERSPACE is enabled or not.

Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
2024-09-10 14:41:17 +01:00
Luca Burelli
2d322725d3 tests/llext: refactor: simplify test case definition
This patch refactors the macro for test case definition to simplify the
generic case. By using variable macro arguments and default-0 fields,
the most common case does not require arguments at all and tests that
have special requirements can be defined with only the necessary fields.

Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
2024-09-10 14:41:17 +01:00
Marek Matej
a3f71f13bf boards: espressif: Use default partition tables
Include the predefined partition table in the Espressif boards.

Signed-off-by: Marek Matej <marek.matej@espressif.com>
2024-09-09 18:42:01 -04:00
Riadh Ghaddab
12a437c4c9 pm: policy: change the policy event handling
Some events needs to be handled with a very low latency constraint.
If the system is in deep sleep, exit latency from this low level state
exceeds sometimes the maximum latency constraint of these events.

Before suspending the system, select which events is happening sooner,
kernel events or normal events.
CPU will be up just before the next event occurs taking into account the
exit latency of the current power state

Change also the policy event API to take as argument absolute time in HW
cycles instead of time in us

Signed-off-by: Riadh Ghaddab <rghaddab@baylibre.com>
2024-09-09 13:56:04 -04:00
Henrik Brix Andersen
159f7dbbb1 lib: net_buf: rename header file from zephyr/net/buf.h to zephyr/net_buf.h
Move the network buffer header file from zephyr/net/buf.h to
zephyr/net_buf.h as the implementation now lives outside of the networking
subsystem.

Add (deprecated) zephyr/net/buf.h header to maintain compatibility with old
file path.

Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
2024-09-07 11:19:05 -05:00
Krzysztof Chruściński
c77a54327d tests: logging: Add test for log_frontend_stpesp_demux
Add test for message demultiplexer from STPv2 data stream generated
by STMESP frontend.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-09-06 11:31:27 -04:00
Krzysztof Chruściński
fc162f74c0 debug: mipi_stp_decoder: Align naming to 2.4 standard
Align naming to STP v2.4. Changing Master to Major.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-09-06 11:31:27 -04:00
Adam Wojasinski
7e3580070f llext: Add filesystem based testcase to llext test suite
Extend tests with case where extension is copied from RAM buffer
into filesystem and then loaded from filesystem.

Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
2024-09-06 11:26:09 -04:00
Tomi Fontanilles
17545c17a5 dts: arm: st: h7: fix flash on M4 board targets
The flash controller is nowadays supported on the M4 core.
Add the bank2-flash-size property to the board definitions as required
by the STM32 H7 flash driver.

Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
2024-09-04 19:10:19 -04:00
Yuval Peress
8974c248cf rtio: Add default i2c submit handler
Use the RTIO work queue to fake the i2c submit calls for drivers which
haven't yet implemented the API. Applications can change the size of
the work queue pool depending on how much traffic they have on the buses.

Signed-off-by: Yuval Peress <peress@google.com>
2024-09-04 21:28:26 +02:00
Jordan Yates
1ed77cb50c zbus: remove unneeded const qualifiers
Remove `const` qualifiers on fields in structures that are only created
or instantiated as `const`.

This if primarily for consistency, in the same way that `struct device`
fields and `device->config` struct fields are not additionally marked as
`const`.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-09-04 12:52:01 +02:00
Jamie McCrae
4384e4b575 tests: mgmt: mcumgr: enum_mgmt: Fix removed zcbor function
Fixes use of a function that has been removed

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-09-03 10:41:11 +02:00
Guennadi Liakhovetski
19ccec6a03 llext: use EXPORT_SYMBOL() universally
Replace LL_EXTENSION_SYMBOL() with EXPORT_SYMBOL() in all tests and
samples.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2024-09-02 12:31:52 -04:00
Daniel Leung
060538ee28 logging: fix color being shown even if disabled
If CONFIG_LOG_BACKEND_SHOW_COLOR is disabled, error and warning
lines are still being outputted with color, which is contrary to
what the Kconfig says. So change the color settings for error
and warning lines to no color if this Kconfig is disabled.

The log_output test is also amended to account for this.
Though the test is not skipped as no color is still some colors
(... well... maybe).

Fixes #77150

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-09-02 09:07:19 +02:00
Jordan Yates
ffc46baeb7 tests: rtio: test rtio_sqe_prep_callback_no_cqe
Test that SQE's created with `rtio_sqe_prep_callback_no_cqe` run, but
don't create a completion queue event.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-08-30 09:06:36 +02:00
Andrzej Drabarek
166b9bf35a soc: polarfire: split into cpu clusters
Split Polarfire SoC into CPU clusters as they have different
capabilities.

Signed-off-by: Andrzej Drabarek <adrabarek@antmicro.com>
2024-08-28 06:50:40 -04:00
Daniel Leung
82d56e8f0b tests: thread_analyzer: test for privileged stacks usage
This adds the bits to test the displaying the usage of
privileged stacks for user threads. Note that this only
adds the printk part as this is to test the code path to
fetch usage data rather than the display part.

Also add qemu_xtensa/dc233c/mmu to platform allow list so
the privileged stack code can be tested on that platform.

This replaces mps2/an385 with qemu_x86 as an integration
platform due to the privileged stack test. Since ARM does
not currently support getting privileged stack info, test
would result in twister error due to kconfig warnings.
The board cannot be excluded since it's an integration
platform. So for now, use qemu_x86 as an integration for
32-bit testing. Once ARM has proper support, we can go
back to having mps2/an385 as an integration platform.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-28 06:50:30 -04:00
Daniel Leung
96bb97a54f tests: thread_analyzer: disable QEMU icount
This disables QEMU icount for all the simulated platforms
in the allowed list. With icount enabled, the printout from
the thread analyzer would be continuous and non-stop instead
of the default once every 60 seconds. Besides, the console
harness only needs one, and these is no need to waste CPU
cycles and memory for processing the extra ones.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-28 06:50:30 -04:00
Théo Battrel
cfeb325b4f Tests: Shell: Take into account startup new line
Update `shell_backend_uart` to take into account the new line print by
`z_cursor_next_line_move`.

Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
2024-08-27 18:37:28 -04:00
Felipe Neves
419edffabf boards: arduino_nicla_vision: add Arduino Nicla Vision
Initial board support and documentation.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
2024-08-27 18:36:21 -04:00
Daniel Leung
c4e3afe621 tests: logging/dictionary: limit allowed platforms
Instead of using filter (which is expensive in terms of CI as
it needs to run cmake on everything to get the full kconfigs
before filtering can be done), change that to a curated list
of allowed platforms. This avoids the expensive filtering
operation, yet can still run on some emulated platforms to
verify the dictionary output.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-27 15:21:31 -04:00
Jamie McCrae
edee1ed9a0 tests: mgmt: mcumgr: Add enum_mgmt test
Adds a test that checks the functionality of this new management
group

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-08-26 17:05:27 +02:00
Daniel DeGrasse
744f67c587 tests: fs: fat_fs_api: add support for testing SDMMC devices
Add support for testings SDMMC devices using the fat_fs_api test.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-08-20 10:30:41 +02:00