SPI_SILABS_SIWX91X_GSPI_DMA and SPI_SILABS_SIWX91X_GSPI_DMA_MAX_BLOCKS are
redundant. We can achieve the same by checking if
SPI_SILABS_SIWX91X_GSPI_DMA_MAX_BLOCKS > 0.
Then, rather than pulling the DMA if one device use it, automatically use
the DMA it exist (the user can still disable it by settings DMA_MAX_BLOCKS
== 0).
Thanks to that change, we can remove allthe #ifdef in the SPI driver.
A test in spi_siwx91x_is_dma_enabled_instance() is sufficient to make the
DMA relative functions orphans.
Then, we can enable the dma instances in the board DTS, so the user just
have to set DMA=y to enable DMA in the drivers.
The two errors cases are:
- DMA=y while referenced DMA instance in the DT is disabled. The user get
a compilation error
- DMA=n (or DMA driver is disabled) but the user explicitly set
DMA_MAX_BLOCKS > 0. The user get an error during runtime.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Until now, the SPI driver had to take care about the size of the blocks
sent to the DMA. There were several drawbacks:
- The SPI driver need to know the DMA internal parameter and the SPI
driver has configured for a specific DMA hardware block.
- For large transfer, the user has to allocate a large number of
descriptor in the SPI driver. The user had to know the DMA block size
of set the right parameter and the descriptors were duplicated with the
DMA driver (which store them in the hardware format).
However, our DMA drivers now automatically split the large blocks. So the
SPI driver no longer need to do that.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
The UDMA scatter-gather mode rejected any block whose size exceeded
DMA_MAX_TRANSFER_COUNT * burst_length bytes (1024 transfers). The was
caller responsible for splitting.
Apply the same fix as the GPDMA driver: when a dma_block_config block is
too large for a single scatter-gather descriptor, automatically split it
into as many chained descriptors as needed, advancing src/dst addresses
for each chunk (honoring DMA_ADDR_ADJ_INCREMENT / DMA_ADDR_ADJ_NO_CHANGE).
Assisted-by: GitHub Copilot:claude-sonnet-4.6
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
The GPDMA rejected any block whose size exceeded
GPDMA_DESC_MAX_TRANSFER_SIZE (4096 transfers). The was caller responsible
for splitting. There is no way for the caller to be aware of this
restriction.
This patch allow the GPDMA driver to automatically split the oversized
block and run the DMA with a linked descriptors.
Assisted-by: GitHub Copilot:claude-sonnet-4.6
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
SiWx91x provide two DMA hardware block: GPDMA and UDMA, The GPDMA is
properly named: silabs,gpdma. However, the UDMA is named
"silabs,siwx91x-dma" without any reference to the hardware block it is
supposed to run.
Rename the UDMA driver to fix this inconsistency.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
The NXP Wi-Fi middleware unconditionally accesses IPv4 network
structures and DHCPv4 APIs, causing compiler and linker failures
when CONFIG_NET_IPV4 is disabled (e.g., in IPv6-only environments).
This commit introduces Kconfig guards around the IPv4-specific
logic. Functionally, when IPv4 is disabled, the middleware now
safely bypasses IPv4 static address assignment, IPv4 address and
netmask retrieval, and DHCPv4 client initialization.
Additionally, variables that become unused in IPv6-only builds
are properly suppressed using the ARG_UNUSED() macro.
Fixes#87647
Signed-off-by: T Madhusudhan Rao <tetakalam@aerlync.com>
Drop all the symbols that were incorrectly part of the public header
and move them to a driver-internal header.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
When there are multiple zephyr,bt-hci-uart nodes, we currently use the
reset-assert-duration-ms property from the first one for all of them due
to a typo in the initializer macro. Fix it.
Fixes: 9f44b011de ("bluetooth: hci: h4: optional reset pin")
Signed-off-by: Thomas Hebb <tommyhebb@gmail.com>
esp_wifi_set_mode can fail silently if esp_wifi_init was not successful.
Move the mode set and handle its return value post esp_wifi_init error
checking.
Signed-off-by: Madhab Sharma <madhabsharma94@gmail.com>
Include MSPI_DEVICE_CONFIG_IO_MODE in XIP_DEV_CFG_MASK and populate
mspi_cfg.io_mode from dev_config->read_io_mode so the XIP setup call
configures the XIP io-mode which wasn't previously the case.
Signed-off-by: David Jewsbury <david.jewsbury@nordicsemi.no>
Some configurations of the DesignWare IP support concurrent XIP
(memory mapping) as part of the IP. The driver currently supports
concurrent XIP using a software workaround and this HW feature is not
yet supported by the driver. However, if concurrent XIP is supported as
well as write XIP not being supported, this will introduce a new
register called XIPSER which this commit adds support for.
Signed-off-by: David Jewsbury <david.jewsbury@nordicsemi.no>
Some configurations of the designware IP support write access but not
all. Therefore, this is a configurable devicetree option to enable or
disable support for the mem-map (memory mapped) write registers. Otherwise,
devices that don't support this will come into a bus fault.
signed-off-by: David Jewsbury <david.jewsbury@nordicsemi.no>
Enabling of the nrf-mspi XIP is done via the core registers and hence
these functions can just be placeholders to stop compilation errors.
signed-off-by: David Jewsbury <david.jewsbury@nordicsemi.no>
Enabling the driver while QEMU is configured to use SLIP driver (which
is the default) causes crash on boot, making any networking sample
defunct in default configuration when running on qemu_x86.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Always use RX FIFO0 when adding RX filters to ensure CAN frames are
processed in the order (priority) received on the bus.
With two FIFOs there is a risk that frames are processed out-of-order by
the application layer.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Use net_eth_set_if_type_wifi() instead of directly accessing
ethernet_context->eth_if_type to set the interface type.
Signed-off-by: Madhab Sharma <madhabsharma94@gmail.com>
Uses generic nomenclature for TDK ntcg series NTC thermistors, which use a
naming scheme that indicates their resistance (R25) and beta (B25/85)
values. Compensation tables are identical for parts with the same
resistance and beta values.
Signed-off-by: Dan Mangum <georgedanielmangum@gmail.com>
Implement the M5PM1 watchdog as a Zephyr watchdog controller child
of the MFD device.
The driver supports a single reset-only timeout channel with one-second
granularity (1 to 255 s).
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.7
Expose the M5PM1 switchable power rails as fixed-voltage regulator devices
child of the MFD device. The driver supports enabling and disabling the 3.3
V DCDC, 3.3 V LDO, and 5 V boost outputs via the PMIC power config
register.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.7
Expose the M5PM1 GPIO bank as a Zephyr GPIO controller child of the MFD
device. The driver supports five pins with input/output configuration,
pull-up/pull-down, and open-drain outputs; pin interrupts are not
supported.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.7
Expose the M5PM1 on-chip ADC as a Zephyr ADC controller child of the MFD
device.
The driver supports rail monitoring channels (VREF, VBAT, VIN, 5VOUT),
GPIO1/GPIO2 inputs via the ADC mux, and an internal temperature channel
at 12-bit resolution.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.7
The M5PM1 is a small companion microcontroller used on M5Stack boards to
provide power management (battery charging, switchable rails), a small
bank of GPIOs, and an on-chip ADC.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Assisted-by: Claude:opus-4.7
Adds the MFD parent driver for the Infineon HPPASS analog subsystem.
HPPASS houses a SAR ADC and Comparator and Slope Generator coordinated
by an Autonomous Controller executing a hardware state machine defined
by a configurable State Transition Table (STT). The HPPASS MFD driver
owns the following shared resources:
- Subsystem Initialization including factory trimming.
- AC Management, including AC start and STT configuration.
- Trigger I/O routing
- MCPASS interrupt handling.
Signed-off-by: John Batch <john.batch@infineon.com>
Add compilation of sl_openthread library to silabs 15.4 radio
driver to enable RAIL operations for OpenThread.
Co-Authored-by: David Boullie <David.Boullie@silabs.com>
Co-Authored-by: Sree Sreerajatha <sree.sreerajatha@silabs.com>
Signed-off-by: David Boullie <David.Boullie@silabs.com>
Add the driver itself and Kconfig/CMakeLists/dts/bindings related to it.
Other files and libraries needed are in Silabs' dedicated folder
hal_silabs (modules/hal/silabs).
Co-Authored-by: David Boullie <David.Boullie@silabs.com>
Co-Authored-by: Sree Sreerajatha <sree.sreerajatha@silabs.com>
Signed-off-by: David Boullie <David.Boullie@silabs.com>
Set LEX10Q1-specific defaults for CMUX buffering and virtual-channel
flow control in Kconfig.cellular.
This modem exhibits the same CMUX behavior as LE910C1TX: it can hit
DLCI receive-buffer pressure during bursty traffic with the generic
defaults. Virtual-channel flow control support is limited, so a
conservative flow control threshold helps avoid buffer exhaustion
without relying on full MSC FC signaling.
Use modem-specific defaults when DT_HAS_TELIT_LEX10Q1_ENABLED is set:
MODEM_CMUX_WORK_BUFFER_SIZE_EXTRA defaults to 256
MODEM_CMUX_MSC_FC_THRESHOLD defaults to 0.
Signed-off-by: Luca Impagliazzo <Luca.Impagliazzo@telit.com>
This modem can hit DLCI receive-buffer pressure during bursty traffic
with the generic defaults. Virtual-channel flow control support is
limited, so a conservative flow control threshold helps avoid buffer
exhaustion without relying on full MSC FC signaling.
Use modem-specific defaults when DT_HAS_TELIT_LE910C1TX_ENABLED is set:
MODEM_CMUX_WORK_BUFFER_SIZE_EXTRA defaults to 256
MODEM_CMUX_MSC_FC_THRESHOLD defaults to 64.
Signed-off-by: Luca Impagliazzo <Luca.Impagliazzo@telit.com>
kernel.h implies kernel_structs.h via kernel_includes.h, making
explicit inclusion of kernel_structs.h unnecessary whenever kernel.h
is already included in the same translation unit.
Remove the redundant includes across arch, boards, drivers, kernel,
lib, samples, subsys, and tests trees.
in include/zephyr/kernel_structs.h:
* 2. kernel.h shall imply kernel_structs.h, such that it shall not be
* necessary to include kernel_structs.h explicitly when kernel.h is
* included.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
is_sg_enabled, sg_velocity_check_interval_ms and
sg_threshold_velocity should not be dts properties as they
are not actuallly hardware configurations.
dropping the check for is_sg_enabled in init routines, since
the configuration happens at runtime now.
Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
Implements the `get_info` API for `leds_group_multicolor`. This exposes
the `color-mapping` and `label` devicetree properties, if they are
provided.
Signed-off-by: Ole Johan Walderhaug <olejodd10@gmail.com>
replace BUILD_ASSERT for fifo-watermark with min/max in bindings
replace all enums with min/max with their corresponding ranges
Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
use min/max for fifo-watermark in bosch,bmi08x-gyro.yaml
and bosch,bmi08x-accel.yaml
drop BUILD_ASSERT in bmi08x_gyro.c
Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
VIDEO_CID_FOCUS_AUTO is a boolean control type, so its range
is max=1. The previous range of max=65535 was rejected
by check_range() with -ERANGE, causing initialization to fail
with "Unable to initialize controls" on AF-capable variants.
Signed-off-by: Mario Paja <mariopaja@hotmail.com>
Fix compilation issues in the Arducam Mega video driver:
- Fix incompatible pointer type when calling arducam_mega_await_bus_idle()
by aligning const-correctness of struct arducam_mega_bus.
- Correct LOG_DBG format string mismatch in JPEG quality logging
(fix incorrect argument usage with %d).
- Address deprecated SPI DT macro usage by updating initialization
to avoid deprecated delay parameter warning.
Signed-off-by: Mario Paja <mariopaja@hotmail.com>
Updates the SoC initialization to configure PSRAM IO GLB register such that
PSRAM GPIO registers (32-37) are reused for pins whose registers are
allocated for SF2 internal flash (23-28), and modifies the GPIO driver to
use those offset registers when configuring.
Signed-off-by: Dan Mangum <georgedanielmangum@gmail.com>
Co-authored-by: Camille BAUD <mail@massdriver.space>
cache_data_flush_all() was accidentally removed in e17bf15
but it is still used by the cache API and needs to be present.
Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
Adds the missing config member that is common to all GPIO drivers
and that is expected to be the first element in the object pointed
to by the config field in the device structure.
Signed-off-by: Jesse Hörkkö <jesse.horkko@sasken.com>
Move the can_mcan.h header file out of the public include path. This file
should solely be used for implementing CAN driver frontends for Bosch
M_CAN-based CAN controller IPs.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
Move the can_sja1000.h header file out of the public include path. This
file should solely be used for implementing CAN driver frontends for
SJA1000-based CAN controller IPs.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>