This is required if boards make use of such definition in their Kconfig
files. In Kconfig.board.v2, only `boards/Kconfig.v2` is loaded, but
BOARD_REVISION is part of `boards/Kconfig`, which can't be loaded in this
context.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The goal of this commit is to reduce the overall test time by optimizing
the time spent sleeping.
However while doing so, a few glitches became apparent and those have
been fixed as well.
1. The way the ZSOCK_POLLIN event is managed has been modified
In most tests, the event would stick for the whole test and this would
sometimes results in the client receiving more data than intended which
in turn would results in various unexpected warnings and errors.
The management of the ZSOCK_POLLIN event has now been mostly moved to
the send/receive overrides which better represent how things would
happen outside of the test scenario.
For example, when sending data, if this send would normally result in
receiving some response, the send function sets the ZSOCK_POLLIN event.
Then when receiving, we clear the event as the data has been received.
There are a few exceptions to this for cases where we need to simulate
some specific abnormal behavior.
2. The `messages_needing_response` queue now includes a valid bit
The test manages a queue of messages id to be able to respond to the
correct id in the receive hooks.
It was built in a way that the id 0 would be treated as invalid
although it is a valid id.
In practice, it would not be an issue in most cases however, it would
result in an unexpected behavior if the `test_multiple_requests` test
would be run first.
To fix this issue in the simplest way, the queue has been changed to
uint32_t which gives us 16 extra bits for the management of the queue,
1 of which is used to tell if the entry is valid or not.
Signed-off-by: Francois Gervais <francoisgervais@gmail.com>
Since CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC is tied to the slow RTC clock
for the nRF53, use the default SYSCLK of 64MHz instead.
Signed-off-by: Maximilian Deubel <maximilian.deubel@nordicsemi.no>
Fixes MCUBoot Serial Recovery compilation error
"Serial recovery/USB DFU button must be declared
in device tree as 'mcuboot_button0'"
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
PHYTEC currently supports five boards in Zephyr, with another in
development. Given the growing interest from our customers and our
commitment to expanding support for PHYTEC platforms, I am
volunteering to take over the maintenance of these boards.
This will help streamline contributions and reduce the workload on
the silicon vendor maintainers.
Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
Front picture was listed twice, despite the back picture
(max32666fthr_img2.jpg) actually being checked into the repo, so switch
to that one.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
A response returned after a request times out would increment the
semaphore and stay until the next request is made which will immediately
return when k_sem_take is called even before a response is returned. This
will once again have the same problem when the actual response arrives.
So the wait semaphore just needs to be reset before transmitting.
Signed-off-by: Abram Early <abram.early@gmail.com>
Correct several inconsistent parameter names in the following functions:
- stm32_gpio_intc_select_line_trigger: rename `trigger` to `trg`
to match the header file.
- stm32_gpio_intc_set_irq_callback: rename the callback argument to `user`
to match the `stm32_gpio_irq_cb_t` type.
- stm32_exti_get_line_src_port: rename `pin` to `line` to align with
the Doxygen comment and implementation.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Using a separate workqueue causes issues without any special locking to
synchronize with networking threads e.g., interface being removed while
the workqueue is trying to synchronize with WPA supplicant.
It's easier to use the net_mgmt thread which is in better sync with
networking.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In case of error conditions post successfully sending the message, the
event is already freed but we attempt to free it again.
Rejig the labels to easily reflect thier purpose.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
When an event is sent the receiver gets is asynchronously and hence is
responsible for free the event, the sender should only free in case of
error conditions i.e., unable to send.
Else, this causes a tough to debug double-free.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In case WPA supplicant disabled DPP, we need to compile out the
corresponding DPP code in Wi-Fi shell too.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
These priorities can be resolved automatically with the sub-priority
mechanism, so set them to the same value.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
This prevents recursive logging loop when USB CDC ACM is used for shell
with logging.
Change affects both USB stacks.
Signed-off-by: Xudong Zheng <7pkvm5aw@slicealias.com>
Update the migration guide to indicate that the STM32 ADC that selects an
asynchronous clock also need to set a domain clock.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Update ADC bindings documentation to state that a domain clock is now
necessary if asynchronous clock is selected.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Add a compile-time check to verify that a domain clock is explicitly
defined if a STM32 ADC is configured to use an asynchronous clock.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
For all STM32 boards that define an asynchronous clock for ADC, specify
which clock is to be used in the clock node.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
For STM32L1, U5 and WBA, the ADC always uses an asynchronous clock source,
so we add the default clock source in the clock node.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Fix assertion when enabling simultaneous multiple Extended
Advertising chain reception that is enabled by increasing
supported auxiliary scan contexts.
ULL sets the association of aux context to scan and sync
context, and LLL resets the association; this is safer
compared to earlier implementation where ULL did both the
association and reset which caused aux context memory
leak.
Supported auxiliary scan contexts can be increased using
CONFIG_BT_CTLR_SCAN_AUX_SET value.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Adds a semaphor to make sure the stream has properly been stopped by the
controller before returning from btp_bap_broadcast_source_stop.
Signed-off-by: Frode van der Meeren <frode.vandermeeren@nordicsemi.no>
One needs the 32bit version of the SDL development library when
building for 32bit native_sim, and for the 64bit native_sim the
64bit version. Let's clarify this.
Also fix the SDL2 link.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
It includes both the high-level documentation of the subsystem and
that of APIs defined in code (PSA Secure Storage and internal APIs of
the subsystem).
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Add a sample to demonstrate use of persistent keys in the PSA Crypto API.
The implementation of the PSA ITS API that allows storage of persistent
keys is provided either by the just-introduced secure storage subsystem
or by TF-M.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Add a sample to demonstrate direct use of the PSA ITS API.
The implementation of the API is provided either by the just-introduced
secure storage subsystem or by TF-M.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Add one suite to test the PSA ITS API directly, and another to test it
through the PSA Crypto API.
The PSA ITS API test suite is run with different configurations to also
test customization possibilities that the secure storage subsystem offers.
Both test suites also have a test scenario with TF-M instead of the
secure storage subsystem.
This serves as compatibility testing to ensure that the PSA Secure
Storage API behaves the same from the user's point of view regardless
of the underlying implementation provider.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
With the secure storage subsystem now providing an implementation of
the PSA ITS API, let Mbed TLS use it when it's enabled.
This allows the use of persistent keys in the PSA Crypto API.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Fixes the systemview tracing backend for soc families, such as max32,
that don't subdivide into soc series and therefore don't define
CONFIG_SOC_SERIES. Use CONFIG_SOC_FAMILY instead in the system
description since it should always be defined.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
Sets CONFIG_HAS_SEGGER_RTT on the max32 soc family to allow using RTT
backends in the logging, shell, and tracing subsystems.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
x86 architectures require a dynamic stack size that is a multiple
of 4096 bytes due to mmu restrictions.
For example, this test would previously fail when using the
default dynamic stack size of 1024 bytes for 32-bit
platforms.
```
west build -p auto -b qemu_x86/atom/nopae -t run \
tests/posix/common/ -- -DCONFIG_USERSPACE=y
```
It would pass with an additional argument
```
west build -p auto -b qemu_x86/atom/nopae -t run \
tests/posix/common/ -- -DCONFIG_USERSPACE=y \
-DCONFIG_DYNAMIC_THREAD_STACK_SIZE=4096
```
Add a special default for x86 when using dynamic thread stacks.
The x86 default removes the need for `boards/qemu_x86*.conf`,
with the exception of `qemu_x86_tiny`.
qemu_x86_tiny did not have sufficient memory (or configuration)
to run the non-userspace tests, so bump up the available ram
from 256k to 512k for this test and clone the .conf from the
demand paging tests.
Eventually, the common posix test should be split into more
concise functional categories.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The `cmd_wifi_dpp_ap_auth_init` function was added but is not yet
aligned with others.
This update enhances consistency with the following changes:
- Unified the order of declaration for `opt`, `opt_index`,
`state`, and `long_options`.
- Wrapped lines in the `long_options` declaration to prevent them
from extending too far to the right.
- Applied `struct option` as `static const`
- Unified the wrapping of `getopt_long` calls, regardless of
the length of the `options` string.
- Using `getopt_state` to access `optarg` and also `optopt` offers
a better alternative to direct global access.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
The `ident` of L2CAP BR connection req will be cleared if
function l2cap_br_conn_req_reply called to send L2CAP BR
connection rsp with result `BT_L2CAP_BR_PENDING`.
Then the invalid `ident` (it is zero) will be filled in
the L2CAP BR connection rsp after the ACL connection is
encrypted.
Recover `ident` if the result of the connection rsp is
`BT_L2CAP_BR_PENDING`.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Currently, error code `-ENOTSUP` will be
returned if start security with security
level 4.
For SC supported case, level 4 for ssp
should be supported.
Remove the code limitation to support
security level 4.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
The flags of L2CAP_CONFIGURATION_REQ are set.
But in L2CAP_CONFIGURATION_RSP, all bits of
flags are cleared.
When used in the L2CAP_CONFIGURATION_RSP
packet, the continuation flag shall be set
to one if the flag is set to one in the
Request.
Copy flags from Request to Response if it
is a successful result.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Currently, Only configuration opt MTU is handled.
For opt `Flush timeout`, `QOS`, `Retransmission
and Flow Control`, and `FCS`, response wilt
result `BT_L2CAP_CONF_UNACCEPT`.
For opt `extended flow specification` and
`extended windows size`, response wilt result
`BT_L2CAP_CONF_REJECT`.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>