Change the condition so that ESP32 SoCs are using `_heap_sentry` to
get actual run-time heap size.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
Adds a check for Kconfig settings that are disallowed from being
used in defconfig files (because it is the complete wrong place
for them), with the default entry being PINCTRL
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Co-authored-by: Benjamin Cabé <benjamin@zephyrproject.org>
The Zaamo and Zalrsc Extension (Version v1.0.0, 2024-04-25; Ratified) split
the standard A extension into two subextensions. As of date, the `_zaamo`
and `_zlrsc` extension specifications are accepted by the upstream
in-development GCC through the `march` argument. This means that those
subextensions are not yet supported by GCC shipped with Zephyr SDK.
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
For Nuclei ECLIC, the interrupt level (mintstatus.MIL) is restored from
the previous interrupt level (mcause.MPIL) only if mcause.interrupt is set.
This behavior is not defined in the RISC-V CLIC spec.
If an ISR causes a context switch and mcause.interrupt is not set in the
next context (e.g. the next context is yielded from ecall), interrupts will
be masked after MRET because the interrupt level is not restored.
Use SOC-specific context to set mcause.interrupt to ensure the interrupt
level is restored correctly.
Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
CLIC supports mintstatus.MIL (RO) and mcause.MPIL (RW) for the current
interrupt level and the previous interrut level before a trap. Each ISR
must execute MRET to set mcause.MPIL back to mintstatus.MIL.
This commit introduces CONFIG_CLIC_SUPPORT_INTERRUPT_LEVEL to handle
mcause.MPIL for interrupt preemption in nested ISR, and uses
CONFIG_RISCV_ALWAYS_SWITCH_THROUGH_ECALL to ensure ISR always switch out
with MRET.
e.g.
With CONFIG_RISCV_ALWAYS_SWITCH_THROUGH_ECALL=n, a context-switch in
ISR may skip MRET in this flow:
IRQ -> _isr_wrapper -> z_riscv_switch() -> retrun to arch_switch()
Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
This function allows to not restart DMA engine for driver that gives
new buffer to the DMA engine while a transfer is ongoing.
Signed-off-by: Martin Hoff <martin.hoff@silabs.com>
Improve the silabs ldma driver to support P2M and M2P transfer. It also
adds signal binding to support source request binding in the dts.
Signed-off-by: Martin Hoff <martin.hoff@silabs.com>
The Sample Output section is missing a blank line before the code block
markup, resulting in the sample output text showing up with an incorrect
format. Fixed by adding a blank line.
Signed-off-by: Irfan Ahmad <irfan.ahmad@siemens.com>
The gecko_uart.c driver supports both `silabs,gecko_uart` and
`silabs,gecko_usart` compat strings, however `PM_DEVICE_DT_INST_DEFINE()`
was missing when defining `uart` type instances. The
efm32wg_stk3800/efm32wg990f256 platform enables by default one
`gecko_uart` DT node and no `gecko_usart` nodes. This results in the
following build warning/error:
uart_gecko.c:673:12: warning: 'uart_gecko_pm_action' defined but not used
Add the missing call to `PM_DEVICE_DT_INST_DEFINE()`.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
In the current pipe_api test file we inadvertantly use VLA.
Toolchains are allowed by standard to allocate VLA on
heap for example. Therefore in my opinion we shouldn't
use VLA atleast in kernel+kernel tests.
Signed-off-by: Robin Kastberg <robin.kastberg@iar.com>
Add verification of the parameter struct, so that it returns
-EINVAL if the values are invalid.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Instead of using the bt_conn struct directly, only
access the field via the public API. This ensures that
changes to the struct won't affect PACS, unless it also
affects the public API.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
It seems ZTEST has been moved to ROM in
86cadf9 and this keeps linker generator
up to date. It is also causing some
issues with IAR toolchain where pbits
are being placed in RAM.
Signed-off-by: Robin Kastberg <robin.kastberg@iar.com>
Adds additional documentation to the callbacks of uac2_ops
to describe if/when they are mandatory to register.
Additionally add asserts before calling them to help debugging
if the user did not register the required ones.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Since a separate CONFIG_NET_TC_RX_SKIP_FOR_HIGH_PRIO was introduced for
RX TC queues, CONFIG_NET_TC_SKIP_FOR_HIGH_PRIO became ambiguous,
rename it to CONFIG_NET_TC_TX_SKIP_FOR_HIGH_PRIO and deprecate the old
config.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
The family and proto type was not set for the IPv4 autoconf ARP packets.
Since those should be set for all ARP packets, just move the code
outside of the if block.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Recent versions fixed issues for EXMIF and TDM pins as well as support
for dynamic placement of the ETR buffer.
Signed-off-by: Karsten Koenig <karsten.koenig@nordicsemi.no>
When the UDC buffer gets submitted it should no longer reside in the
endpoint queue. While this commit does not address the underlying issue
of not being able to start transfer for whatever reason, it prevents the
problem from cascading into buffer double completion (e.g. receive
buffer double free in UAC2).
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
The main thread, if configured with coop priority (don't do that :D)
breaks gpd since it has a non yielding while loop (also don't do that)
Add an explicit yield() to allow other threads to run if main or other
threads use gpd with coop prio.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Tests use nordic specific comparator api which enable it's
runtime reconfiguration.
As there were no tests prepared when introducing this api,
PR adds some to extend test coverage.
Signed-off-by: Bartlomiej Buczek <bartlomiej.buczek@nordicsemi.no>
ST engineer has moved STM32 DMA controllers bindings under ./dma/stm32/
in Linux source code reference by this commit:
https://git.kernel.org/torvalds/c/8494ae75dde4
Signed-off-by: Haiyue Wang <haiyuewa@163.com>
DWC2 otg versions earlier than 5.00a are subject to randomly occurring
glitch on Hibernation Exit by Host Initiated Resume, Hibernation Exit by
Device Inititated Resume and Hibernation Exit by Host Initiated Reset.
When the glitch happens the device address is not correctly restored.
If the address is not correctly restored then the tokens addressed to
the device will timeout leading to host resetting the bus.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Programming Guide states that bit 17 on PCGCCTL writes should be set if
the controller was enumerated for High Speed operation. Add the missing
bit set to adhere to the Programming Guide.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add additional property to allow a configurable delay to the display
initialization to allow the st7789v to be ready to receive commands.
Signed-off-by: Peter Johanson <peter@peterjohanson.com>
Make clock init functions in SOC level weak and global so they can be
overriden by board/app level.
Ideally these should have been put at board level but for now just make
them weak so they can be overriden without breaking anything.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Update the Central and Peripheral GATT write command sample
to measure throughput across all supported connection PHYs.
Cover the sample in BabbleSIM CI testing to validate the 2M
PHY throughput after all supported PHYs have been changed
once.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Workaround HCTO calculation for BabbleSIM due to need of
addition timeout value required to have anchor point sync.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix incorrect peripheral drift compensation when connection
events are overlapping and a PHY update causes the currently
used PHY to change.
Incorrect preamble to address that is calculated using
updated PHY was used causing supervision timeout.
Fixed by storing the PHY used in the current connection
event and using that for drift compensation calculation.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix connection event busy check when peripheral role is
using minimal time reservation.
Peripheral and Central have a anchor point sync if the
Peripheral has successfully transmitted once to the Central.
Fixes commit cadef5a64f ("Bluetooth: Controller: Introduce
BT_CTLR_PERIPHERAL_RESERVE_MAX")'.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
This commit fix the pin function configuration for mii and rmii
setting of Renesas RA8 ethernet driver
Correct pin function setting for mii is
PFENET = (uint8_t)(0x1 << R_PMISC_PFENET_PHYMODE0_Pos);
and rmii is:
R_PMISC->PFENET = (uint8_t)(0x0 << R_PMISC_PFENET_PHYMODE0_Pos);
Change code to intialize ping in driver init function, change
method of getting and checking via enum index of device tree.
Add build assert for invalid phy type.
Signed-off-by: Duy Nguyen <duy.nguyen.xa@renesas.com>
Building kernel.threads.apis with clang warns:
tests/kernel/threads/thread_apis/src/main.c:362:6: error: variable 'ret'
is used uninitialized whenever 'if' condition is true
[-Werror,-Wsometimes-uninitialized]
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:380:6: note: uninitialized
use occurs here
if (ret != 0) {
^~~
tests/kernel/threads/thread_apis/src/main.c:362:2: note: remove the 'if'
if its condition is always false
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:362:6: error: variable 'ret'
is used uninitialized whenever '||' condition is true
[-Werror,-Wsometimes-uninitialized]
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:380:6: note: uninitialized
use occurs here
if (ret != 0) {
^~~
tests/kernel/threads/thread_apis/src/main.c:362:6: note: remove the '||'
if its condition is always false
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:329:9: note: initialize the
variable 'ret' to silence this warning
int ret;
^
= 0
Signed-off-by: Tom Hughes <tomhughes@chromium.org>