Commit graph zephyr/drivers
Author SHA1 Message Date
Fin Maaß
8938faa8d3 drivers: ethernet: intel: add missing net_if_carrier_off
add missing net_if_carrier_off before setting the phy callback.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-20 17:48:51 -05:00
Fin Maaß
41b1d20bb4 drivers: ethernet: intel: use iface as user_data for phy callback
use iface as user_data for phy callback,
as we only need that in the phy callback.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-20 17:48:51 -05:00
Fin Maaß
76bdf61668 drivers: ethernet: xilinx: use iface as user_data for phy callback
use iface as user_data for phy callback,
as we only need that in the phy callback.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-20 17:48:51 -05:00
Fin Maaß
9f3c8e0e8a drivers: ethernet: esp32: use iface as user_data for phy callback
use iface as user_data for phy callback,
as we only need that in the phy callback.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-20 17:48:51 -05:00
Fin Maaß
f7cfb9f843 drivers: ethernet: litex: use iface as user_data for phy callback
use iface as user_data for phy callback,
as we only need that in the phy callback.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-20 17:48:51 -05:00
Jan Carlo Roleda
7cc38a25db drivers: regulator: Extend ADP5360 Regulator Subsystem
Extends ADP5360 Regulator API support to the existing
ADP5360 Buck and Buck Boost Regulator.

Signed-off-by: Jan Carlo Roleda <jancarlo.roleda@analog.com>
Co-authored-by: Francis Roi Manabat <francisroi.manabat@analog.com>
2026-04-20 18:10:14 +02:00
Jan Carlo Roleda
497b9b25a0 drivers: fuel_gauge: Add Fuel Gauge Driver for ADP5360
Implements fuel gauge subsystem for ADP5360 MFD driver.

Signed-off-by: Jan Carlo Roleda <jancarlo.roleda@analog.com>
Co-authored-by: Francis Roi Manabat <francisroi.manabat@analog.com>
2026-04-20 18:10:14 +02:00
Jan Carlo Roleda
34692cf0ff drivers: charger: Add ADP5360 Battery Management PMIC
Adds Charger subsystem support for the ADP5360 MFD device.

Signed-off-by: Jan Carlo Roleda <jancarlo.roleda@analog.com>
Co-authored-by: Francis Roi Manabat <francisroi.manabat@analog.com>
2026-04-20 18:10:14 +02:00
Jan Carlo Roleda
5b2191f4e1 drivers: mfd: Add MFD Driver for ADP5360
Implements I2C communication used by drivers under this parent device,
interrupt support, supervisory data configuration,
and power management subsystem API.

Signed-off-by: Jan Carlo Roleda <jancarlo.roleda@analog.com>
Co-authored-by: Francis Roi Manabat <francisroi.manabat@analog.com>
2026-04-20 18:10:14 +02:00
Krisztian Szilvasi
d739e447fa drivers: ethernet: eth_w5550: increase rx thread stack size
The boards and shield using W5500 chip on latest release (v4.4)
require higher stack size to function

Signed-off-by: Krisztian Szilvasi <krisztian@atym.io>
2026-04-20 18:09:23 +02:00
Manimaran A
46d9b7f5f1 drivers: i2c: mec: invoke stop callback on idle interrupt
In target mode, a STOP condition following a read transaction is
signalled via the idle interrupt. Invoke tcbs->stop() in this path
so the application receives the stop callback for read transactions.

Signed-off-by: Manimaran A <manimaran.a@microchip.com>
2026-04-20 18:03:34 +02:00
Gowtham Palanichamy
30b22fc888 drivers: i2c: stm32_v1: fix ISR storm on write-read repeated START
During a write-read combined transfer (e.g., register read), the write
phase completes and msg_read() calls enable_transfer_interrupts() which
re-enables ITBUFEN. However, the TXE flag from the write phase is still
asserted (hardware only clears it on DR write or ADDR clear). The event
ISR sees TXE=1 but is_write is now false, so no handler matches and the
ISR returns without clearing TXE — causing an infinite interrupt loop.

Fix this with two changes:

1. In i2c_stm32_event(), catch TXE active during a read transfer and
   disable ITBUFEN to quench the stale TXE interrupt source.

2. In handle_addr(), re-enable ITBUFEN after clearing ADDR. The ADDR
   clear implicitly clears TXE, so re-enabling ITBUFEN at this point
   is safe and ensures RXNE interrupts work correctly for the read
   phase.

Signed-off-by: Gowtham Palanichamy <gowtham.palanichamy@rapyuta-robotics.com>
2026-04-20 18:03:27 +02:00
Gowtham Palanichamy
83f8c21a23 drivers: i2c: stm32_v1: disable ITBUFEN in handle_txe on completion
When BTF fires after the last byte is transmitted, it calls handle_txe()
with data->current.len already at 0. The else branch generates a stop
condition and signals completion via k_sem_give, but does not disable
ITBUFEN first. Since TXE is level-triggered and remains asserted until
DR is written, the event ISR can re-fire on the stale TXE flag.

Add LL_I2C_DisableIT_BUF() at the top of the else branch as a defensive
measure so the level-triggered TXE cannot re-enter the ISR after the
transfer is logically complete.

Signed-off-by: Gowtham Palanichamy <gowtham.palanichamy@rapyuta-robotics.com>
2026-04-20 18:03:27 +02:00
Gowtham Palanichamy
9f5bde79fc drivers: i2c: stm32_v1: disable IRQs before completion on error
After an I2C error (NACK, ARLO, BERR), the error handler jumps to the
end: label which calls i2c_stm32_controller_mode_end() (k_sem_give)
without first disabling transfer interrupts. If ITBUFEN (CR2 bit 10) is
still asserted and TXE is high, the event ISR re-fires immediately after
the error ISR returns, creating an infinite interrupt storm that
hard-freezes the CPU.

Disable all transfer interrupts (ITEVTEN, ITERREN, ITBUFEN) before
calling i2c_stm32_controller_mode_end() so the ISR cannot re-enter on a
stale TXE flag. When CONFIG_I2C_TARGET is enabled, only do this for the
controller path to avoid interfering with target mode operation.

Signed-off-by: Gowtham Palanichamy <gowtham.palanichamy@rapyuta-robotics.com>
2026-04-20 18:03:27 +02:00
Manimaran A
ce71fb46af drivers: crypto: mec: update to support MEC174x/5x/165xb
Updated PCR and GIRQ properties to use new macros.
Updated symcr and romapi node for mec174x/5x/165xb

Signed-off-by: Manimaran A <manimaran.a@microchip.com>
2026-04-20 18:03:17 +02:00
Carlo Caione
0585ff2b50 lora: sx126x: apply silicon errata workarounds
Apply three documented SX1261/62 silicon errata from DS_SX1261-2_V1.2:

- IQ Polarity (chapter 15.4): after every SetPacketParams command,
  manually fix bit 2 of REG_IQ_POLARITY to match the requested IQ
  inversion setting. Without this, inverted-IQ packets (used by
  LoRaWAN downlinks) may be silently corrupted.

- TX Modulation Quality at 500 kHz (chapter 15.1): clear bit 2 of
  REG_TX_MODULATION when using 500 kHz bandwidth, set it otherwise.
  Without this, 500 kHz transmissions have degraded modulation quality.

- Register Retention: add REG_RX_GAIN and REG_TX_MODULATION to the
  chip's internal retention list so their values survive warm-start
  sleep cycles, matching the upstream Semtech reference driver.

Signed-off-by: Carlo Caione <ccaione@baylibre.com>
2026-04-20 13:22:47 +02:00
Carlo Caione
b357d13f66 lora: sx126x: enforce minimum preamble length for SF5/SF6
The SX126x requires a minimum preamble length of 12 symbols when using
spreading factors 5 or 6 (DS.SX1261-2.W.APP, Rev 2.2, section 6.1.1).
Shorter preambles at these spreading factors can cause failed detection
on the receiver side.

Clamp the stored preamble length after configuration so that all TX, RX,
and airtime paths use the corrected value.

Signed-off-by: Carlo Caione <ccaione@baylibre.com>
2026-04-20 13:22:47 +02:00
Carlo Caione
79d4e791ca lora: sx126x: serialize native CW tests
test_cw() only checked that the radio was idle before starting a
continuous-wave transmission. It never moved the driver out of the rest
state, so another TX or RX operation could start while the CW test was
still active.

Signed-off-by: Carlo Caione <ccaione@baylibre.com>
2026-04-20 13:22:47 +02:00
Carlo Caione
dd069ab527 lora: sx126x: validate native bandwidth selections
The native SX126x driver accepted unsupported LoRa bandwidth enums and
silently mapped them to 125 kHz. That could leave the modem running with
a different configuration than the caller requested, and it also skewed
airtime calculations.

Signed-off-by: Carlo Caione <ccaione@baylibre.com>
2026-04-20 13:22:47 +02:00
Armando Visconti
8712e72d6a drivers/sensor: lsm6dsvxxx: fix bad odr restore
When setting SFLP game gbias the accel/gyro data rate must be temporarily
changed and then restored back to original values. But in the process the
saved rates got mistakenly corrupted.

Signed-off-by: Armando Visconti <armando.visconti@st.com>
2026-04-20 13:22:37 +02:00
Armando Visconti
018a044e71 drivers/sensor: lsm6dsvxxx: fix interrupt lost
If gpio level gets immediately at high level after sensor is started,
then call interrupt stream handler in order to avoid losing it. As a
side effect no data would be ever read.

Co-authored-by:Brenden Adamczak <cerebralasylum1@gmail.com>
Signed-off-by: Brenden Adamczak <cerebralasylum1@gmail.com>
Signed-off-by: Armando Visconti <armando.visconti@st.com>
2026-04-20 13:22:30 +02:00
Jari Tervonen
36ce7ae44b drivers: clock_control: Add handling of missing NRF_BICR LFOSC modes
Add handling of missing NRF_BICR LFOSC modes MODE_PIERCE and MODE_PIXO
and filter out unsupported modes with preprocessor macros provided by
nrfx.

Signed-off-by: Jari Tervonen <jari.tervonen@nordicsemi.no>
2026-04-20 13:22:21 +02:00
Philipp Steiner
a7cdc70c64 net: fix PTP TX timestamping on native_tap and AF_PACKET
native_tap only queued TX timestamp callbacks for gPTP packets, which
left PTP SO_TIMESTAMPING socket traffic without TX timestamps.

Add host-clock packet timestamp updates in native_tap TX/RX paths, queue
TX timestamp callbacks when net_pkt_is_tx_timestamping() is set (while
preserving gPTP behavior without double-queueing), and propagate
SO_TIMESTAMPING TX/RX flags for AF_PACKET packets in net_context.

Signed-off-by: Philipp Steiner <philipp.steiner1987@gmail.com>
2026-04-20 13:22:07 +02:00
Philipp Steiner
5bbef54237 drivers: ethernet: stm32: use PLL1_Q as the H5 PTP reference clock
RM0481 Rev 4 documents the Ethernet PTP timestamp clock as a dedicated
reference clock (`clk_ptp_ref_i`), not the `eth_hclk` bus clock.
Table 115 ("Kernel clock distribution overview", p. 470/3154) lists
`ETH (ptp)` on `pll1_q_ck`, and the IEEE 1588 section states that the
64-bit PTP time is updated from `clk_ptp_ref_i`.

Add an explicit `mac-clk-ptp` clock for STM32H5 sourced from
`STM32_SRC_PLL1_Q`, use that clock rate for PTP addend programming.

Because this change introduces source-clock configuration for STM32
Ethernet clocks, update the STM32H7 DWMAC path as well: use
`clock_control_configure()` for source clocks such as `eth-ker`, while
keeping `clock_control_on()` for gated clocks.

Signed-off-by: Philipp Steiner <philipp.steiner1987@gmail.com>
2026-04-20 13:22:07 +02:00
Antonio Tessarolo
d8a56ad0ea drivers: serial: nxp: added uart runtime configuration
Add uart runtime configuration to uart_imx

Signed-off-by: Antonio Tessarolo <anthonytexdev@gmail.com>
2026-04-20 11:50:39 +02:00
Jakub Zymelka
91830dd575 soc: nordic: remove haltium and lumos platform abstractions
1. Remove the NRF_PLATFORM_HALTIUM and NRF_PLATFORM_LUMOS Kconfig
symbols and eliminate all "haltium"/"lumos" naming from the zephyr
directory.
2. The shared haltium_power.c/h and haltium_pm_s2ram.c/h files from
soc/nordic/common/ are duplicated into the per-SoC-series directories
(nrf54h/ and nrf92/) as soc_power.c/h and soc_pm_s2ram.c/h. The
corresponding build rules are moved from common/CMakeLists.txt to the
per-series CMakeLists.txt files.
3. Kconfig guards that relied on the platform symbols are replaced with
individual hardware feature checks derived from nrfx/MDK:
- select NRFX_POWER if !NRF_PLATFORM_HALTIUM -> if HAS_HW_NRF_POWER
- CLOCK_CONTROL default ... !NRF_PLATFORM_HALTIUM -> HAS_HW_NRF_CLOCK
- depends on NRF_PLATFORM_LUMOS -> SOC_SERIES_NRF54L||SOC_SERIES_NRF71
4. C preprocessor guards using CONFIG_NRF_PLATFORM_HALTIUM are replaced
with explicit SoC series checks (CONFIG_SOC_SERIES_NRF54H ||
CONFIG_SOC_SERIES_NRF92).
5. The sysbuild option NRF_HALTIUM_GENERATE_UICR is renamed to
NRF_GENERATE_UICR.

Signed-off-by: Jakub Zymelka <jakub.zymelka@nordicsemi.no>
2026-04-20 11:44:28 +02:00
Guillaume Gautier
6ec2b8d4f9 drivers: crc: stm32: adapt crc driver to stm32 hal2
Adapts the STM32 CRC driver for STM32 HAL2: some #define have a new name.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2026-04-20 11:44:11 +02:00
Lluis Miquel Martinez Campos
bae0fb09f3 drivers: i2c: nrfx_twi: use timeout error code
Analog to a8e6e17c22.

Use timeout error code instead of generic EIO.

Signed-off-by: Lluis Miquel Martinez Campos <lluiscampos@proton.me>
2026-04-20 08:28:17 +02:00
Holt Sun
241f08509c drivers: watchdog: wdt_mcux_wwdt: allow reset-none callback
Allow WWDT callbacks without warning configuration when
WDT_FLAG_RESET_NONE is selected.

This restores callback-at-expiry behavior for reset-none
flows while keeping reset-enabled modes on the guarded
warning-interrupt path.

Signed-off-by: Holt Sun <holt.sun@nxp.com>
2026-04-20 08:26:32 +02:00
Fabian Blatz
04cfca3141 drivers: sdhc: sam_hsmci: Initialize variables in sam_hsmci_request_inner
Initialize `transfer_count`, `is_write`, and `byte_mode` variables to
prevent potential use of uninitialized variables.

Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2026-04-19 16:44:56 +01:00
Ryan Erickson
68e702294b drivers: serial: pl011: fix CTS loop
If CTS hardware flow control is in use, prevent an
infinite loop of callbacks.

Enable the CTS interrupt if TX is unavailable from
CTS blocking.

Signed-off-by: Ryan Erickson <ryan.erickson@ezurio.com>
2026-04-18 12:38:40 -04:00
Peter van der Perk
51c9266329 drivers: input: add CRSF remote controller support
Add input driver support for CRSF (Crossfire) receivers, originally
developed by Team BlackSheep (TBS) and used by ExpressLRS (ELRS) and
others.

The driver allows mapping up to 16 CRSF channels to Zephyr input events,
supporting both absolute axes (joysticks) and key events (switches), and
operates over a standard non-inverted UART interface.

Signed-off-by: Peter van der Perk <peter.vanderperk@nxp.com>
2026-04-17 15:50:37 -05:00
William Markezana
0be8143217 drivers: sensor: si7006: add meas,htu21d compatible
The HTU21D is register-compatible with the SHT21 and uses the same
measurement commands. Add it as another DT_DRV_COMPAT entry in the
existing Si7006 driver rather than a standalone driver.

Signed-off-by: William Markezana <william.markezana@gmail.com>
2026-04-17 15:49:47 -05:00
Fin Maaß
f70515e69c pcie: fix type casting
Without this we will get a warning on 32 bit
platforms.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-17 15:56:48 +02:00
Fin Maaß
662f59c675 pcie: use z specifier when used on size_t
use z specifier when used on size_t,
otherwise we will get build warnings.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-17 15:56:48 +02:00
Krzysztof Chruściński
61db1027dc drivers: debug: nrf_etr: Fix and improve shell support
Shell support with STM logging was broken as it was not used by any
test or sample. Applying fixes and improvements.

When shell was used with STM logging then the last log often was not
printed on time as it got stuck in the ETR buffer until more data was
written. Fixed by adding a periodic initial processing of the ETR
buffer content (in k_work context). If pending message is found then
shell thread is notified. We don't want to do the processing in shell
thread unless we are sure that there is at least one message to process
because shell thread erases line and prints prompt during each call to
the log processing function.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2026-04-17 13:43:51 +02:00
Krzysztof Chruściński
be7c5a896a drivers: debug: nrf_etr: Fix logs coloring
Short (0 and 1 arguments) logs where not using colors.
Align flags used for log_output formatting for both paths
used for log processing.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2026-04-17 13:43:51 +02:00
Krzysztof Chruściński
4a3cf66c07 drivers: debug: coresight_nrf: Re-enable early logging
At some point CONFIG_LOG_FRONTEND_STMESP_EARLY_BUF_SIZE default value
was set to 0 on cpuapp. It meant that log entries which happend before
STM and Coresight initialization were lost. Add buffer which is used
to store those logs.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2026-04-17 13:43:51 +02:00
Fin Maaß
4247c8787a pcie: dependency for PCIE_CONTROLLER
When CONFIG_PCIE_CONTROLLER is enabled,
the chosen zephyr,pcie-controller also needs to
be enabled.

Also on platforms where this chosen is set the
pcie controller is needed for the pcie to work,
therefor enable it by default.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-17 12:37:16 +01:00
Fin Maaß
85917d8086 drivers: pcie: enable PCIE_ECAM based on dt
enable PCIE_ECAM based on dt.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2026-04-17 12:37:16 +01:00
Tim Pambor
0fe8f5541c ethernet: dwmac: fix multicast reception
By default the DWMAC ethernet controller is configured
to drop all multicast packets. Currently, HW filtering is
not supported, so we need to configure the controller to
pass all multicast packets.

Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
2026-04-17 12:36:21 +01:00
Fabian Otto
289ea35e30 drivers: sdhc: mcux_sdif: optional GPIO card-detect via cd-gpios
When present, configure the pin as input and use GPIO for card presence
instead of SDIF_DetectCardInsert(). Useful if the board uses a pin other
than SD0_CARD_DET_N for card detection.

On the LPC55S28 we needed it to work around an issue where configuring
PIO1_13 as SD0_CARD_DET_N stalled Flexcomm6 I2C transfers. The same pin
works when muxed as GPIO.

Signed-off-by: Fabian Otto <fabian.otto@rohde-schwarz.com>
2026-04-17 12:34:45 +01:00
Marcin Niestroj
9fa9dfefe4 nsi: move nsos_fcntl to more generic nsi_fcntl
This will allow to reuse fcntl middle layer in other parts besides NSOS,
such as planned Native Simulator host FS mounting.

Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2026-04-17 10:40:50 +02:00
Venkatesh Odela
8d2b1e308b drivers: dma: dma_xilinx_axi_dma: fix unsigned hex constant literals
Replace literal 0xffffffff hex constants with UINT32_MAX.
This improves readability.

Signed-off-by: Venkatesh Odela <venkatesh.odela@amd.com>
2026-04-17 10:37:43 +02:00
Venkatesh Odela
9021b0ea2f drivers: dma: dma_xilinx_axi_dma: clear reset state on stop
Clear DMA reset state in dma_stop() to allow proper restart during
interface up/down cycle.

Signed-off-by: Venkatesh Odela <venkatesh.odela@amd.com>
2026-04-17 10:37:43 +02:00
Venkatesh Odela
50e3ffe7a8 drivers: ethernet: eth_xilinx_axienet: fix missing start/stop support
Add ethernet_api start() and stop() callbacks to support the Zephyr
net iface down/up workflow.

stop() disables MAC RX, stops DMA RX and TX channels,disables MAC TX,
and resets all descriptor ring indices.

start() seeds the RX DMA ring and enables MAC RX and TX.

Signed-off-by: Venkatesh Odela <venkatesh.odela@amd.com>
2026-04-17 10:37:43 +02:00
Venkatesh Odela
bdb7b85cc7 drivers: ethernet: eth_xilinx_axienet: fix TX enable bit position
The Transmitter Configuration register (offset 0x408) TX enable bit is
bit 28 as per the AXI Ethernet Subsystem product guide (PG138), not bit 11.

Fixes: 4342d7108b ("drivers: ethernet: Add Xilinx AXI Enet driver")
Signed-off-by: Venkatesh Odela <venkatesh.odela@amd.com>
2026-04-17 10:37:33 +02:00
Richard Mc Sweeney
9e8b3cf7ea drivers: Refactor pse84 autanalog-adc to use MFD
- Added autanalog MFD support in PSE84 DTS files
- Refactored autanalog ADC in PSE84 to use a common
MFD for handling the global AC configuration
- Constructed AC to use phandle in the overlay
for a better the user experience.
- Added support for a basic and advanced mode
with custom AC

Assisted-by: Claude:claude-opus-4.6
Signed-off-by: Richard Mc Sweeney <Richard.McSweeney@infineon.com>
2026-04-17 10:36:07 +02:00
Martin Anschütz
7d99139128 drivers: spi: xlnx: Enable SPI CS active-high
Enable Active-High polarity for SPI chip-select in Xilinx AXI QSPI Driver.
Required e.g. for SD-Card support.

Signed-off-by: Martin Anschütz <martin.anschuetz@vert-tec.io>
2026-04-17 10:34:22 +02:00
Muhammad Waleed Badar
17b702fdb2 drivers: i2c: nxp: use I2C_BUS_RECOVERY kconfig
Default I2C_MCUX_FLEXCOMM_BUS_RECOVERY to y when
I2C_BUS_RECOVERY is enabled.

Signed-off-by: Muhammad Waleed Badar <walid.badar@gmail.com>
2026-04-16 11:40:50 -05:00