Make cc13xx_cc26xx_irq_tx_ready check that the TX Ready interrupt
occurred, instead of checking whether there is some free space in
the UART TX FIFO. This prevents a race condition from occurring in
OpenThread Spinel protocol implementation, when a UART RX interrupt
is received right after otPlatUartSend was called, between the
assignement of 1 to ot_uart.tx_busy and the initialization of
write_length.
Signed-off-by: Pascal Bodin <pbodin@baylibre.com>
Add lldbac runner configuration to arc_v nSIM board family for
simulator debugging with run-lldbac tool.
Configure --nsim-props argument using the same NSIM_PROPS variable as
arc-nsim runner for consistency. This enables the lldbac runner to
use the board-specific nSIM properties for simulator mode debugging.
The lldbac runner supports both simulator and hardware modes, with
simulator mode being enabled via the --simulator flag. For hardware
debugging, users need to provide --board-json configuration separately.
Signed-off-by: Afonso Oliveira <afonsoo@synopsys.com>
Introduce a new Zephyr runner, `lldbac`, providing interactive debugging
for both nSIM (simulator) and physical hardware using the run-lldbac
tool from Synopsys ARC MWDT.
This runner provides integrated debugging support:
- debug: Interactive debugging with integrated server management,
Available for both simulator and hardware (integrated mode)
- flash: Flash and run on physical hardware,
Available for hardware only (simulator should use arc-nsim)
Key features:
- Hardware mode: Flash and debug on physical hardware using JTAG flags
- Simulator mode: Interactive debugging on nSIM using run-lldbac with
--nsim flag (props or --tcf). Enable with --simulator flag.
- Board-driven config: Boards can specify defaults in board.cmake
- TCF support: Optional --tcf for simulator mode (mutually exclusive
with --nsim-props)
- GUI support: Optional --gui flag for VS Code debugging
- Postconnect support: Execute commands after connection via
--postconnect-cmd and --postconnect-file for hardware initialization
- Board JSON: Optional --board-json for complex board configurations
Hardware configuration (flag-based):
- --jtag-device: JTAG device name (optional, auto-detected)
- --jtag: JTAG adapter type (default: jtag-digilent)
- --jtag-frequency: JTAG clock frequency (default: 500KHz)
- --postconnect-cmd: Command to execute after connection
(can be used multiple times)
- --postconnect-file: File containing commands to execute after
hardware initialization
- --board-json: Path to board.json file for board configuration
Simulator configuration:
- --simulator: Enable simulator mode (required)
- --nsim-props: nSIM properties file path
- --tcf: Tool Configuration File (alternative to --nsim-props)
Signed-off-by: Afonso Oliveira <afonsoo@synopsys.com>
Signed-off-by: Mohamed Moawad <moawad@synopsys.com>
Zephyr supports CMake 3.20, which doesn't support
`file(COPY ... ONLY_IF_DIFFERENT)` and requires `BRIEF_DOCS` and
`FULL_DOCS` when defining properties.
This commit ensures the build system is CMake 3.20 compliant.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
According to STM32F411xC/E refman(RM0383) and the clock tree, there
is no PLLI2SQ output.
Remove the div-q property to fix build error.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Sender address and address length were not set in recvfrom() when called
for TCP socket. Fix this by reusing the code used to set source address
on accept().
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
recvfrom() and recvmsg() were not properly tests in terms of the address
structure they returned, therefore improve the tests in this area.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Use internal buffer pointers for I2C read and write paths instead of
advancing i2c_msg->buf directly. This avoids unintended pointer side
effects while keeping the read and write data flow unchanged.
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
Use internal buffer pointers for I2C read and write paths instead of
advancing i2c_msg->buf directly. This avoids unintended pointer side
effects while keeping the read and write data flow unchanged.
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
Use internal buffer pointers for I2C read and write paths instead of
advancing i2c_msg->buf directly. This avoids unintended pointer side
effects while keeping the read and write data flow unchanged.
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
Initial implementation of an adc driver for the ads79xx series of
spi-adc chips.
This driver sets the device in auto-1 mode, and supports devices
in the series, with different resolutions (12/10/8-bit),
and number of channels.
Signed-off-by: James Walmsley <james@fullfat-fs.co.uk>
make the rxtx size a define, as this driver
does not support any other value and it's
also not configureable in litex.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
If CONFIG_ROMSTART_RELOCATION is enabled, create a *separate* load/exec
memory region for the vector table. This must be separate for armlink,
otherwise moving .rom_start changes the LR base and drags .text with it.
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
arch_irq_enable(), arch_irq_disable(), arch_irq_is_enabled() are
exported to assembly via GTEXT() but are implemented as C macro mappings
in some configurations. This can leave undefined symbol in objects that
include irq.h, which some linkers diagnose as errors as seen below with
armlink:
```
Error: L6218E: Undefined symbol arch_irq_enable (referred from reset.o).
Error: L6218E: Undefined symbol arch_irq_disable (referred from
reset.o).
Error: L6218E: Undefined symbol arch_irq_is_enabled (referred from
reset.o).
```
Map the arch_irq_* to appropriate underlying implementation in the
_ASMLANGUAGE path so that all assembly-visible exports resolve to real
symbols.
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
`armclang` doesn't support picolibc right now so disable it and fix
few issues related to it as below:
```
zephyrproject/zephyr/lib/libc/validate_libc.c:17:14: error: static
assertion failed due to requirement 'sizeof(unsigned int) >= 8': time_t
cannot hold 64-bit values
17 | BUILD_ASSERT(sizeof(time_t) >= 8, "time_t cannot hold 64-bit
values");
```
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
Add system symbols in right region (FLASH) instead of the first
non-empty load section to fix below build errors:
```
Error: L6384E: No Load Execution Region of name ramfunc seen yet at line
11.
Error: L6384E: No Load Execution Region of name bss seen yet at line 13.
Error: L6384E: No Load Execution Region of name bss seen yet at line 17.
```
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
`armlink` does not accept -O* flags so, drop linker optimization flags
to avoid below build error:
```
Fatal error: L3903U: Argument 's' not permitted for option 'O'.
```
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
Fix race condition between DMA ISR and work queue that caused RX
length underflow when calculating len = counter - offset.
Both mcux_lpuart_async_rx_timeout (work queue) and dma_callback
(ISR) modified rx_dma_params without locking, causing the ISR to
update counter/offset mid-calculation, resulting in integer
underflow and system crash.
Solution: Add irq_lock() protection around all rx_dma_params
accesses in async_evt_rx_rdy(), mcux_lpuart_async_rx_flush(),
and async_evt_rx_buf_release().
Signed-off-by: Holt Sun <holt.sun@nxp.com>
Split error handling in mcux_lpuart_rx_enable() to distinguish
between DMA status query failures (error) and busy status (debug).
- Use LOG_ERR for get_status failures with specific error code
- Use LOG_DBG for busy status (expected condition, valid -EBUSY)
- Improves debuggability by providing clearer diagnostic messages
Signed-off-by: Holt Sun <holt.sun@nxp.com>
The binding function `mctp_i3c_target_tx()` is called by (libmctp)
`mctp_message_tx()`, and it uses `k_sem_take()`.
In the mctp/i3c_bus_endpoint sample, `mctp_message_tx()` is executed
from isr callback (`stop_cb`). However, `k_sem_take()` must not be
called from isr context. This issue can be detected when
`CONFIG_ASSERT` is enabled.
To fix this, this patch moves the rx message handler to the system
workqueue.
Signed-off-by: Ren Chen <Ren.Chen@ite.com.tw>
The return value greater than 0 from `i3c_target_tx_write()`
indicates the number of bytes written. This patch fixes
the incorrect check.
Signed-off-by: Ren Chen <Ren.Chen@ite.com.tw>
Different flash parts have different requirements on the number of dummy
bytes to send when issued a RDID request, so allow configuring the read ID
dummy byte count in devicetree for the MAX32 SPIXF flash driver.
Signed-off-by: Pete Johanson <pete.johanson@analog.com>
Pass the selected channel and bandwidth to WHD, so the AP
enables on the requested channel/width.
Signed-off-by: Liu Gavin (CSS ICW ENG WFS SW WFSW 1) <Gavin.Liu@infineon.com>
SiWx917 does not support concurrent read and write on the flash.
sli_mv_m4_app_from_flash_to_ram() ensure that requirement. Especially, it
disable the Zephyr scheduler. However, to guaranty the instruction cache
won't access to the flash, this function has to be located in RAM.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
NET_CONFIG_NEED_IPV6 is by default
already not enabled, so we don't need
to add that default again in a shield.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
The xen_sysctl_getdomaininfo function (which calls the
XEN_SYSCTL_getdomaininfolist hypercall) returned meaningless data
because the xen_domctl_getdomaininfo structure in Zephyr was 8 bits
smaller than in Xen.
This happened because the xen_arch_domainconfig structure, which is used
in both xen_domctl_getdomaininfo and xen_domctl_createdomain, was
missing the uint8_t sve_vl field introduced in Xen Domctl interface
version 0x16.
To fix this, the sve_vl field was added to xen_arch_domainconfig under
the appropriate config macro, synchronizing the structure with Xen and
resolving the data mismatch.
Signed-off-by: Svitlana Drozd <svitlana_drozd@epam.com>
Fix redundant initialization of vif_ctx_zep where the variable was
initialized at declaration and immediately overwritten before being
read.
Remove the redundant initialization to improve code clarity.
Signed-off-by: Gaetan Perrot <gaetan.perrot@spacecubics.com>
settings_zms_dst() and settings_zms_src() never reports errors and
always returns 0.
The error check at the call site is therefore dead code.
Make the function void and drop the unused error handling.
Signed-off-by: Gaetan Perrot <gaetan.perrot@spacecubics.com>
Check and handle errors returned by pthread_create() when using
SIGEV_THREAD notification.
Previously, the return value was ignored, which could lead to silent
failures.
Proper error handling is added to propagate failures and set errno
accordingly.
Signed-off-by: Gaetan Perrot <gaetan.perrot@spacecubics.com>
This patch adds support for the STM32 XSPI memory controller in order to
enable PSRAM testing. It also adds a board overlay for the STM327S78
Discovery Kit that includes a PSRAM memory.
Signed-off-by: Arthur Gay <arthur.gay@marshmallow.kids>
Setting the prompt to the empty string allows it to be hidden. This is the
intent of the shell command 'shell prompt off'. However, in the most recent
change to the prompt handling, this functionality was lost. Presumably,
the check for 'prompt_length == 0' was to avoid a NULL prompt. However,
NULL is already checked for. Remove the zero-length check and restore the
ability to set the prompt to the empty string.
Signed-off-by: Ryan Smith <elryno@elryno.com>
Fix spelling and wording issues in comments and assert across tests
modem files.
No functional change.
Signed-off-by: Gaetan Perrot <gaetan.perrot@spacecubics.com>
Remove linker optimization workaround for IAR linker as the new
inheritance scheme allows empty linker values.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Switch manual linker and assembly inheritance settings from custom
handling of checking and setting linker/assembly optimization settings
based on compiler properties to instead use CMake's property inheritance
mechanism.
This reduces code to maintain as well as allow toolchain infrastructure
to clear optimization property flags when no flag is required or
supported, for example by the linker.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>