This tests generate tenths of thousands of lines of debug logs, which is
slow and can on its own make the test fail in loaded runners.
And when the test fails in CI, all those debug lines slow down fetching
the log.
So let's lower the verbosity from debug to info level.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Increase socket, DNS, CoAP, and DTLS timeout settings in the
HL78xx NTN overlay to support satellite NTN connectivity. NTN
links have high RTT (10–15s or more), requiring larger timeout
values for DNS, CoAP ACKs, connect operations, and DTLS
handshake retransmission.
This overlay enables the sample's NTN mode and configures
extended DTLS handshake min/max timeouts to improve reliability
when operating over satellite networks.
Signed-off-by: Zafer SEN <zafersn93@gmail.com>
Introduce optional NTN (Non-Terrestrial Network) mode for the LwM2M
sample client. NTN links have very high latency, typically 10–15s
RTT, which causes DTLS handshakes to fail with default timeout
values.
This change adds Kconfig options to enable NTN mode and configure
DTLS handshake min/max timeout values. When enabled, the client sets
custom socket options to increase DTLS retransmission timers before
performing the DTLS handshake.
This improves connection reliability when using satellite-based NTN
connectivity.
Signed-off-by: Zafer SEN <zafersn93@gmail.com>
Expand the allowed range for NET_SOCKETS_CONNECT_TIMEOUT and
NET_SOCKETS_TLS_CONNECT_TIMEOUT from 60s to 300s. Satellite and
NTN links can experience very high RTT, making the previous
60s maximum too small for reliable connect() and TLS handshake
operations.
Increasing the upper bound allows applications and overlays to
set longer, realistic timeout values when operating over high
latency networks such as NTN.
Signed-off-by: Zafer SEN <zafersn93@gmail.com>
Now that obtaining the GPIO port device object is always done, the IOsync
configuration logic can be cleaned up. Notably, we can perform it while
still holding the PM Device Runtime reference to avoid an unnecessary
clock_disable and clock_enable.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
The `gpio_stm32_configure()` function is used by both the GPIO and PINCTRL
drivers to configure I/O pins. Move it to the GPIO port manager module's
code so it can be shared properly and update both drivers accordingly.
With this change, the GPIO and PINCTRL drivers are completely decoupled.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
On STM32 hardware, the GPIO port's MMIO interface is used for two purposes
which have their own separate Zephyr API: controlling the state of digital
I/O pins directly (GPIO API) and configuring I/O pins for a specific usage
(PINCTRL API). Historically, this was handled by having the PINCTRL driver
call inside the GPIO driver which works but creates a dependency loop.
Introduce a new `GPIO port manager` module in SoC-specific common code that
takes over various from the existing GPIO/PINCTRL drivers: GPIO port device
instantiation and `GPIO port index -> device` mapping respectively.
Modify the GPIO and PINCTRL drivers to make use of this GPIO port manager
module - a first step in decoupling both drivers from each other.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
Move the helper function which computes the LL pin value from a pin number
to the <stm32_gpio_shared.h> header as this function can be useful for
modules other than the GPIO driver.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
Move the ports list from the GPIO driver to a shared SoC-specific header.
This will allow reuse from other drivers such as pinctrl.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
The function is only used from the device's PM action and is very trivial.
Inline it inside gpio_stm32_pm_action to simplify the driver.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
The STM32 pinctrl dt-bindings headers were full of definitions used by the
SoC-specific pinctrl header (<pinctrl_soc.h>) rather than from Devicetree.
Move these definitions to the appropriate header. While at it, include the
<pinctrl_soc.h> header from GPIO driver instead of series-specific pinctrl
header since it uses these definitions.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
Remove ext_flash_app variant of stm32h573i_dk and stm32h750b_dk boards
from the platform_allow list of test_mcuboot. These configuration variants
do not allow to run these tests where the zephyr application executes
in place from an external flash while it is expected to write to that
same flash. The current implementation does not support that.
Add stm32h573i_dk (normal variant) for test bootloader.mcuboot.assert
which is applicable.
Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
Improve Kconfig options with information about different build symbols
and document devicetree configuration used / needed when entropy
drivers are used.
Signed-off-by: Flavio Ceolin <flavio@hubblenetwork.com>
Add a new section with examples of usage of both, cryptographically
and non-cryptographically APIs.
Signed-off-by: Flavio Ceolin <flavio@hubblenetwork.com>
Simplify the subsys overview expliciting stating two different
types of random number generator APIs and use cases.
Signed-off-by: Flavio Ceolin <flavio@hubblenetwork.com>
Fix warnings about using char * for %p argument in cbprintf. It's
recommended to cast it to void * because it may cause misbehavior
in certain configurations.
Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
My recent work has focused mainly on Power Management for
NXP i.MX MPU platforms. I have been contributing in areas
such as PM subsystem, SoC-level PM enablement,
driver PM support, and SCMI power related work.
I also have some practical experience with Power Management
on multi-core SoCs, especially around system-level PM flows
and SoC integration.
Through this work, I have gained a deeper understanding of Zephyr PM
from subsystem level down to SoC and driver integration.
I hope to contribute not only by submitting patches, but also
by helping maintainer to reviews and support ongoing PM maintenance.
Signed-off-by: Yongxu Wang <yongxu.wang@nxp.com>
The ED value measured during ED scanning is converted
to RSSI in dBm at the ieee802154 driver level before
it is reported to upper layer through the scan callback.
Signed-off-by: Vincent Tardy <vincent.tardy@st.com>
ARMv8-R AArch32 cores determine the CPU start address on reset from
RVBAR (Reset Vector Base Address Register), which only stores bits
[31:5] — bits [4:0] are RES0. Any firmware or boot-loader that
programs RVBAR from the ELF entry point will silently truncate
a non-aligned address to a 32-byte boundary, causing the CPU to
begin executing at the wrong location.
Whether __start lands on a 32-byte boundary depends on the size of
code sections placed before it, which changes with Kconfig options.
This makes the failure non-deterministic: a build may work today and
break after enabling an unrelated feature like logging.
Force 32-byte alignment on z_arm_reset/__start for ARMv8-R so the
entry point survives RVBAR truncation on any SoC.
Signed-off-by: Appana Durga Kedareswara rao <appana.durga.kedareswara.rao@amd.com>
The L2 PPP driver was not working for any other
Async-Control-Character-Map values than 0xffffffff.
This was caused by two issues:
* modem_ppp.c was expecting CONTROL field to be always escaped.
* lcp.c was decoding async_map values wrongly. Either as 16bit,
or raw 32bit, instead of big-endian 32 bit.
Now it should be safe to default my_options.async_map to a zero.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
When peer sends the Async-Control-Character-Map option on LCP
phase, Zephyr correctly responsed with Configure-Ack.
But the LCP negotiation phase have not been finnished yet,
so the remote end may not expect us to immediately
update the value.
This is seen when trying to use Zephyr's PPP stack against
PPPD from Linux, where default asyncmap option is zero.
However, if we delay the update of the asyncmap to the network phase,
it works just fine.
Fixes#105291
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
Fix issue in the function
stm32wba_802154_configure_mac_key() : avoid keys copy
in case of the value field of first key in the mac_key
pointer is null.
Signed-off-by: Vincent Tardy <vincent.tardy@st.com>
Add instrumentation hooks for transitions and actions, as well as
error states. This will allow us to track the state of the state
machine during testing, and also provide a way to debug issues
that may arise during execution.
Signed-off-by: Glenn Andrews <andrewsglenn@meta.com>
Prevent gen_periphconf_entries.py from generating duplicate entries
in the C output. This can happen when a resource is used multiple
places in the devicetree, for example.
Signed-off-by: Jonathan Nilsen <jonathan.nilsen@nordicsemi.no>
Remove CONFIG_SPI_ASYNC=n from the conf file for STM32 DMA.
Since CONFIG_SPI_ASYNC is set in prj.conf, this change enabled ASYNC
for STM32 SPI DMA test.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Add error logging in pm_resume_devices() to report when a device
fails to resume. This improves debuggability by making resume
failures visible in the system log.
Signed-off-by: Yongxu Wang <yongxu.wang@nxp.com>
Use PSCI CPU suspend to implement CPU idle for Cortex-A55 Core on i.MX 93.
Signed-off-by: Chenhui Zhao <chenhui.zhao@nxp.com>
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
Only define variable for enabled CPU Core to fix the following building
warning in case of any CPU Core is not enabled but with "cpu-power-states"
dts node property:
zephyr/subsys/pm/state.c:15:43: warning: 'pmstates_DT_N_S_cpus_S_cpu_0'
defined but not used [-Wunused-const-variable=]
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
Add interrupt locking to arc_core_mpu_buffer_validate() to be atomic.
The function iterates through MPU regions using bank selection, which
requires multiple register accesses. Without interrupt protection, an
interrupt or context switch during iteration can corrupt the bank
selection state, causing incorrect region lookups and spurious access
denials.
Signed-off-by: Mohamed Moawad <moawad@synopsys.com>
Allow passing custom J-Link commands to the jlink runner via
--pre-script-cmd argument. The argument can be given multiple times. The
commands are prepended to runner.jlink in the given order.
Signed-off-by: Thorsten Klein <thorsten.klein@bshg.com>
As of commit c92c8ab461
("firmware: scmi: core: merge send_message() logic"), the SCMI core is
able to figure out that it needs to use polling-based messaging whenever
in PRE_KERNEL stage. Thus, consumers are no longer required to query the
kernel's state via a `k_is_pre_kernel()` call and pass its value to
`scmi_send_message()`.
Furthermore, said commit also changes the semantic of the "use_polling"
parameter. Now, for interrupt-based messaging, the core may choose to
ignore the caller's request and use polling instead.
Thus, replace all usages of `k_is_pre_kernel()` with a hardcoded value.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Configure qemu based on the
devicetree and the
"riscv,isa-base" and the
"riscv,isa-extensions" dt prop.
Only activate the riscv extensions, that
we need.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
Enabling and disabling interrupts may happen concurrently from thread
and interrupt context. Add locks to synchronize the access to the ctrl
register.
This was observed to improve the stability of the zephyr,bt-hci-uart
driver when used with the cmsdk_apb uart driver.
Signed-off-by: Marco Widmer <marco.widmer@bytesatwork.ch>
Similar to the TX interrupt, the RX interrupt is also an edge interrupt
that only fires when a new bytes is received. When enabling the RX
interrupt, data may be already present in the RX FIFO. Call the
interrupt handler manually to start processing.
Also check if calling the interrupt handler is really required.
Signed-off-by: Marco Widmer <marco.widmer@bytesatwork.ch>
irq_is_pending should not return 1 when interrupts are disabled through
irq_XX_disable. Check the interrupt enable bit before returning.
Signed-off-by: Marco Widmer <marco.widmer@bytesatwork.ch>
Add unit tests that stress the driver in various ways. The concurrent
access test is a best effort attempt to trigger race conditions.
Signed-off-by: Henrik Lindblom <henrik.lindblom@vaisala.com>
For use in tests where the existing "vnd,dac" driver doesn't work as it
returns error codes for all API functions. The approach is mimicked from
the adc-emul driver.
Signed-off-by: Henrik Lindblom <henrik.lindblom@vaisala.com>