Commit graph

23353 commits

Author SHA1 Message Date
Benjamin Cabé
d7c0244487 drivers: comparator: adopt SHELL_HELP
Adopt SHELL_HELP macro for comparator_shell

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-06-13 10:14:24 -07:00
Fin Maaß
c481fedc5b drivers: ethernet: phy: only use one worker
only use one worker for monitoring and
autoneg.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-13 10:12:46 -07:00
Fin Maaß
b0048e34cd drivers: ethernet: phy: use kernel timepoint api
use kernel timepoint api.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-13 10:12:46 -07:00
S Mohamed Fiaz
f61b5bd705 driver: gpio: siwx91x: Add device runtime support for gpio driver
This commit enables the device runtime driver support
for the siwx91x device.

Signed-off-by: S Mohamed Fiaz <fiaz.mohamed@silabs.com>
2025-06-13 10:08:38 -07:00
Adib Taraben
9b8be4971e drivers: ethernet: nxp: timestamping to all potential packets.
add timestamping on Tx to packets marked for timestamping
add timestamping on Rx to all packets for later use
fix race condidition on adding timestamp when sending delay_req

Signed-off-by: Adib Taraben <theadib@gmail.com>
2025-06-13 10:40:49 -04:00
Jason Yu
e420d446f7 drivers: spi: mcux_flexio: Fix flexio SPI loop delay issue
The function FLEXIO_SPI_MasterTransferNonBlocking has a bug when
works in CS continuous mode. In this mode, both RX and TX
interrupts are enabled, they share the same IRQ line.

In the ISR, the RX event and TX event are not handled well,
so a short delay in ISR is needed.

The function FLEXIO_SPI_MasterTransferNonBlocking issue is fixed,
the delay in ISR can be removed.

Signed-off-by: Jason Yu <zejiang.yu@nxp.com>
2025-06-13 10:38:32 -04:00
Nirav Agrawal
ffe8daa767 drivers: bluetooth: add BT-CAL data load for NXP IW612/IW416 SoC
- Add support for default Annex-55 Bluetooth calibration data load
 for both IW612 and IW416 SoC.
- Add support for default Annex-100 Bluetooth calibration data load
 for both IW612 and IW416 SoC.

Signed-off-by: Nirav Agrawal <nirav.agrawal@nxp.com>
2025-06-13 10:36:28 -04:00
Sebastian Głąb
c0a28ab561 drivers: spi: Support spim23 and spim24 instances
Extend SPI driver with possibility to use
- spim23, spim24,
- spis23, spis24.

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
2025-06-13 10:31:17 -04:00
sudarsan N
357434e908 drivers: usb_c: fusb307: Check return value gpio_add_callback()
The result of gpio_add_callback() was not checked, which may
lead to silent failure in alert interrupt setup.

CID: 525074

Signed-off-by: sudarsan N <sudarsansamy2002@gmail.com>
2025-06-13 14:29:23 +02:00
Daniel Schultz
e1db87e515 driver: serial: uart_shell: Add read command
This command waits for a given time (in seconds) and will continuously
poll from the UART device and print on the Shell console. This command
can be used to also test the RX line.

Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
2025-06-13 14:29:09 +02:00
Wajdi ELMuhtadi
ea6eade52b drivers: sensor: wsen_itds_2533020201601: fix unhandled returned values
The returned values from function calls should
be ignored since these function calls are dummy reads.
fixes #90480

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2025-06-13 11:13:25 +02:00
Bjarki Arge Andreasen
b41feb9abc drivers: serial: nrfx_uarte: assert clock control enabled
clock control is required for "fast instances" so assert clock
is enabled alongside PM DEVICE RUNTIME. Update UART tests to
reflect this requirenment.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-13 11:12:43 +02:00
Bjarki Arge Andreasen
020e99c147 drivers: serial: nrfx: remove deprecated config
The UART_NRFX_UARTE_USE_CLOCK_CONTROL is no longer used and
incorrectly selects CLOCK_CONTROL if UARTE120 exists. Remove
it.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-13 11:12:43 +02:00
Bjarki Arge Andreasen
8a27773247 drivers: clock_control: nrf2: split configs per driver
Currently the config CLOCK_CONTROL_NRF2 is used as a GLOB
style config which includes all "NRF2" drivers and related
configs.

With NRF2, clocks are treated as individidual devices
with individual device drivers. This commit split the
CLOCK_CONTROL_NRF2 config into device specific configs
and ifdefs. With this, drivers are selected individually
based on devicetree state as is common for most devices
drivers, and dependencies like NRFS and specific NRFS
services are selected by the specific driver which nees it.

Checks for CLOCK_CONTROL_NRF2 are updated to check for
existance of the clocks instead.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-13 11:12:43 +02:00
Bjarki Arge Andreasen
979a565289 drivers: clock_control: nrf2: align with hw binding names
Currently there is a mismatch between the naming of the hardware and
the drivers targetting the hardware. nrf2_ is used instead of
the actual bindings names, like nrf2_audiopll instead of
nrfs_audiopll. This makes it hard to map drivers to the hardware
they are targetting.

There is historical reason for some of this, namely the same binding
name was used for different hardware, which is why nrf2_ was used
on newer platforms. This is no longer the case though, so drivers
and configs can be named according to the hardware without conflict.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-13 11:12:43 +02:00
Aksel Skauge Mellbye
856341e175 drivers: debug: silabs_pti: Add driver for Packet Trace Interface
The Packet Trace Interface is a debug interface that emits TX and RX packet
data over a serial connection in real time.

Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
2025-06-13 11:12:20 +02:00
Aksel Skauge Mellbye
b66c720ed6 drivers: debug: Add debug driver class
Add a new driver class for drivers related to debugging, such as
trace hardware, performance counters etc.

Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
2025-06-13 11:12:20 +02:00
sudarsan N
cda6858d99 drivers: video: fix null deref in video_get_csi_link_freq()
Add null and bounds checks before accessing int_menu[ctrl.val].

CID: 525179
Fixes: #91244

Signed-off-by: sudarsan N <sudarsansamy2002@gmail.com>
2025-06-13 10:10:13 +02:00
Khanh Nguyen
c6de306949 drivers: pwm: Update Renesas RA PWM driver to integrate Renesas ELC
Update the Renesas RA PWM driver to integration
with the Renesas Event Link Controller.

Signed-off-by: Khanh Nguyen <khanh.nguyen.wz@bp.renesas.com>
2025-06-13 10:09:35 +02:00
Khanh Nguyen
ed757ca290 drivers: misc: add Renesas RA ELC driver
Add support for the Renesas RA Event Link Controller, including
driver sources, Kconfig, and Devicetree bindings.

Signed-off-by: Khanh Nguyen <khanh.nguyen.wz@bp.renesas.com>
Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2025-06-13 10:09:35 +02:00
Fin Maaß
242d348fca drivers: ethernet: stm32: stop hal before config
make sure the hal is stopped, before
configuring the link. The phy can change the
speed without notifying a link down in between.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-13 07:39:42 +02:00
Yuval Peress
c8415cd76b i2c: npcx: Verify msg is not null
When using target mode, we've found that some times the msg field can
be null through some of the code paths of the interrupt event handler.

Signed-off-by: Yuval Peress <peress@google.com>
2025-06-13 07:37:14 +02:00
Josuah Demangeon
a3728d71e9 drivers: video: common: avoid dead code in functions with retry
Avoid k_sleep() never being called when video_write_reg_retry() and
video_read_reg_retry() have a number of retry set to zero (default).
The default number of retries being controlled by
CONFIG_VIDEO_I2C_RETRY_NUM.

Signed-off-by: Josuah Demangeon <me@josuah.net>
2025-06-13 07:36:37 +02:00
Kevin Shaju
7e56d134c2 drivers: net: phy: Add tja11xx driver
Adds the c22 tja11xx driver.

Signed-off-by: Kevin Shaju <kevin.shaju@accenture.com>
2025-06-12 15:04:32 -07:00
Fabrice DJIATSA
26a43ca88e drivers: serial: stm32: prevent race condition
The async_user_callback could be triggered from
both the DMA transfer complete interrupt and
a k_work queue timeout. Since the timeout runs
outside of an ISR context, it could be interrupted
by the DMA ISR. This might leads to a race condition
where both paths access and modify shared
DMA buffer state (offset and length) simultaneously,
causing data corruption or out-of-sequence processing.

Introduces proper synchronization to prevent concurrent
access to shared DMA buffer variables,
ensuring consistent and reliable data handling.

Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
2025-06-12 09:41:45 -07:00
Cristian Bulacu
b3cc778c87 drivers: ieee802154: update mcxw ieee802154 driver
Updated driver based on changes done in SDK 25.06.00-pvw2.
Update hal_nxp to include BLE LL and IEEE 802.15.4 PHY NBU
combo firmware for MCXW72 boards.

Signed-off-by: Cristian Bulacu <cristian.bulacu@nxp.com>
2025-06-12 09:34:16 -07:00
Cristian Bulacu
5cf2d4585e drivers: ieee802154: Fix resolution in mcxw_get_time function.
Updated mcxw_get_time function to output its result in nanosecond
resolution and updated code accordingly.

Signed-off-by: Cristian Bulacu <cristian.bulacu@nxp.com>
2025-06-12 09:34:16 -07:00
Travis Lam
10f35d741f drivers: cache: nrf: Resolve NRF_CACHE_HAS_LINEADDR issue
Add new function called _cache_all_check that cache all if
NRF_CACHE has no LINEADDR.

Signed-off-by: Travis Lam <travis.lam@nordicsemi.no>
2025-06-12 09:33:48 -07:00
Ali Hozhabri
ecf795f0f1 drivers: bluetooth: hci: Use TRNG peripheral for BLE purpose on WB0x
Call entropy APIs to use TRNG peripheral on STM32WB0x devices for BLE
purposes.

Enable RNG node on Nucleo-WB0x boards.

Remove RNG initialization as it's done in the entropy driver.

Signed-off-by: Ali Hozhabri <ali.hozhabri@st.com>
2025-06-12 09:32:41 -07:00
Karsten Koenig
db3cd1a833 drivers: cache: Add barriers to nrf driver
On Cortex-M33 the access to peripheral registers doesn't act as a data
synchronization barrier for memory accesses to normal memory. So before
triggering any TASKS for cache operations we need to make sure the core
doesn't have any pending memory transactions.

Signed-off-by: Karsten Koenig <karsten.koenig@nordicsemi.no>
2025-06-12 09:29:58 -07:00
Krzysztof Chruściński
94d355a0bd drivers: serial: nrfx_uarte: Add workaround for FRAMETIMEOUT corner case
When reception is restarted (STARTRX after ENDRX but no STOPRX) it is
possible that FRAMETIMEOUT countdown counter will not be started by
the first received byte if byte was already being transmitted when
STARTRX was called. If that is the only byte then it is expected that
timeout will be triggered but since FRAMETIMEOUT counter is not started
there is no FRAMETIMEOUT event which has short to STOPRX. This
situation will happen in case short buffers are used (< 5 bytes)
because then short ENDRX_STARTRX is not used then.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-06-12 09:27:27 -07:00
Krzysztof Chruściński
6717a37421 drivers: timer: nrf_rtc_timer: Optimize z_nrf_rtc_timer_get_ticks
Converting absolute system ticks to RTC ticks is simple. It needs to be
multiplied by CYC_PER_TICK (which by default is 1). Complex algorithm
was used when driver was not tracking current 64 bit tick and function
was returning uint32_t.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-06-12 09:26:29 -07:00
Benjamin Cabé
c31b7898aa drivers: rtc: rpi_pico: fix tm_mon and tm_mday offsets
tm_mon is 0-11 and pico hw is 1-12
tm_mday is 1-31 and so is pico

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-06-12 13:40:59 +02:00
Andrzej Głąbek
77a7cb3e4f drivers: clock_control_nrf: Prevent break from becoming dead code
When both NRF_CLOCK_HAS_XO_TUNE and NRF_CLOCK_HAS_PLL evaluate to 0,
one break statement can end up not associated with any case and become
dead code. Refactor a bit the related switch to avoid such situation.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2025-06-12 11:45:56 +02:00
Andrzej Głąbek
2d9ede3852 drivers: flash: nrf_qspi_nor: Handle properly multiple XIP users
Add reference counting in nrf_qspi_nor_xip_enable() so that XIP is
kept enabled as long as there is at least one user that needs it
(boot time enabling done with CONFIG_NORDIC_QSPI_NOR_XIP also counts).

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2025-06-12 11:45:10 +02:00
Fin Maaß
dfb5a31b3e drivers: ethernet: phy: add dt prop for default speeds
add dt prop for default speeds, that the phy is
configured on init by default.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-12 11:44:46 +02:00
Jordan Yates
5dcaf077e7 regulator: npm1300: configure active discharge
Configure the active discharge feature for both the BUCK and LDO/LDSW
blocks through the appropriate registers.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2025-06-12 11:40:32 +02:00
Guillaume Gautier
9798606340 drivers: i2c: stm32: fix some macro name
Some macros haven't been properly renamed in previous commits.
Fixes the wrong names that caused compilation errors.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2025-06-12 11:33:48 +02:00
Adam Kondraciuk
a280fbf9fb drivers: timer: nrf_grtc_timer: Add frequency parameter for K32SRC
Add frequency value for LFCLK sources to be used when `lfxo` node
is not present.

Signed-off-by: Adam Kondraciuk <adam.kondraciuk@nordicsemi.no>
2025-06-12 11:32:59 +02:00
Adam Kondraciuk
cc86ce7cdb drivers: clock_control: nrf: Add frequency parameter for K32SRC
Add frequency parameter for 32k sources.

Signed-off-by: Adam Kondraciuk <adam.kondraciuk@nordicsemi.no>
2025-06-12 11:32:59 +02:00
Łukasz Stępnicki
a0777734de drivers: nrf_ironside dvfs service
Added handling of new IRONside DVFS service.
NRFS DVFS is now not enabled by default.

Signed-off-by: Łukasz Stępnicki <lukasz.stepnicki@nordicsemi.no>
2025-06-12 11:32:32 +02:00
Andrzej Głąbek
3ebae000e5 drivers: i2s_nrfx: Add missing <hal/nrf_clock.h> inclusion
This driver uses the NRF_CLOCK_HAS_HFCLKAUDIO symbol that is defined
in <hal/nrf_clock.h>, so it should explicitly include that header,
not count on this inclusion being done by some other header, like
<zephyr/drivers/clock_control/nrf_clock_control.h>.
Extend also the build assertion that checks if the audio clock can
be used so that now it ensures that the above symbol is defined
(to prevent the driver from silently discarding the audio clock
configured as the clock source).

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2025-06-12 11:31:11 +02:00
Neil Chen
ab3d2dc830 boards: frdm_mcxa153,frdm_mcxa156: add hwinfo support
1. enable hwinfo support
   - device_id_get
   - get_reset_cause
   - get_supported_reset_cause
   - clear_reset_cause
2. verified tests/drivers/hwinfo

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2025-06-12 10:24:40 +02:00
Jiafei Pan
47d6f0235a drivers: gpio: rgpio: only handle usable pin's interrupt
If gpio-reserved-ranges to reserve some pins which used by other CPU
Core's OS, we could only handle usable pins owned by current CPU
Core in interrupt handler.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
2025-06-11 18:31:10 -07:00
Jiafei Pan
a6af366eb5 drivers: gpio: rgpio: not support GPIO_DISCONNECTED
The hardware don't support GPIO_DISCONNECTED.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
2025-06-11 18:31:10 -07:00
Jiafei Pan
0971240b5e drivers: gpio: rgpio: use default pad config value for SCMI platform
If the platform uses SCMI pinctrl driver, pinctrl regitster can't accessed
by CPU Core directly, and currently SCMI pinctrl driver has no API to read
back the register value, so use default pad config value for GPIO pad
configuration, and in theory we could use a fixed pad config value in this
driver as each new GPIO configuration has no relation with previous
configuration.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
2025-06-11 18:31:10 -07:00
Benjamin Cabé
b33e28d233 drivers: serial: bouffalolab: UART_INT_CLEAR is write-only
Fix incorrect read being made to "write 1 to clear" register UART_INT_CLEAR

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-06-11 16:24:09 -07:00
Stanislav Poboril
34f9cd9490 drivers: ethernet: eth_nxp_enet_qos: increase default buffer descriptors
Increased the default number of TX and RX buffer descriptors from 4 to
16. Since the current default buffer size (CONFIG_NET_BUF_DATA_SIZE) is
128, increasing the number of RX buffers is needed to be able to receive
at least one frame of a maximum size split between multiple buffers.

The default number of TX buffers was increased to match the number of RX
buffers and to be able to transmit large frames with many fragments.

Added build-time configuration validation to ensure that the combined
size of all RX buffers is sufficient to receive a maximum-sized Ethernet
frame.

Signed-off-by: Stanislav Poboril <stanislav.poboril@nxp.com>
2025-06-11 16:23:37 -07:00
Stanislav Poboril
4b06f2306d drivers: ethernet: eth_nxp_enet_qos: reassemble split frames
DMA copies frames which cannot fit into a single buffer into
multiple receive buffers. Updated the receiving code to combine
these buffers into a net_pkt with multiple fragments.

This allows the driver to handle larger Ethernet frames that
span across multiple DMA buffers.

Signed-off-by: Stanislav Poboril <stanislav.poboril@nxp.com>
2025-06-11 16:23:37 -07:00
Stanislav Poboril
f2378172d5 drivers: ethernet: eth_nxp_enet_qos: fix rx buffer processing order
Always reading from descriptor with index 0 could cause processing
of the buffers in a different order than they were received. Fixed by
reading from the next unprocessed position in the ring of descriptors
instead.

Fixed unused variable warnings.

Signed-off-by: Stanislav Poboril <stanislav.poboril@nxp.com>
2025-06-11 16:23:37 -07:00