Commit graph

23353 commits

Author SHA1 Message Date
Jiafei Pan
75301887e3 drivers: clock_control: mcux_ccm: add ii2c clock support
Add I2C clock support for imx8m platforms.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
2025-01-24 19:15:57 +01:00
Jiafei Pan
b97c1d7999 drivers: i2c: add NXP i2c driver used on imx8m platforms
This native i2c driver works together with ii2c drive in hal_nxp.

Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
2025-01-24 19:15:57 +01:00
Alain Volmat
5d6101ec4b driver: gpio: mfxstm32l152: add driver for STM32L152 based MFX
Initial commit for a STM32L152 based GPIO expansion chip.
The mfxstm32l152 driver offers GPIO controller fonctions.

Signed-off-by: Alain Volmat <alain.volmat@foss.st.com>
2025-01-24 19:15:46 +01:00
Fabio Baltieri
35abb31284 i2c_shell: add missing i3c include
This is necessary for the I3C device type check, tested with:

west build -p -b nucleo_h563zi samples/subsys/shell/shell_module
-DCONFIG_I2C=y -DCONFIG_I2C_SHELL=y -DCONFIG_I3C=y

and

west build -p -b nucleo_h563zi samples/subsys/shell/shell_module
-DCONFIG_I2C=y -DCONFIG_I2C_SHELL=y -DCONFIG_I3C=n

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-01-24 15:43:33 +01:00
Mayank Narang
cb608812cf drivers: sensor: lis2de12: add length check in spi write incr routine
Added a length check in the spi write incr routine to handle both
single and multi byte write operations properly.

Signed-off-by: Mayank Narang <narang.may77@gmail.com>
2025-01-24 15:42:21 +01:00
Mayank Narang
7b062f5b09 drivers: sensor: lis2de12: fix read accel via spi
The lis2de12 sensor driver spi interface was calling spi read api.
This leads to a single byte operation on reading acceleration data
which is a multi byte operation. Fix it by adding a call to spi read
incr api instead. Added a length check to handle both single and multi
byte read properly.

Signed-off-by: Mayank Narang <narang.may77@gmail.com>
2025-01-24 15:42:21 +01:00
Matthias Hauser
543864321c drivers: nrfx: Avoid unhandled event calling assert function
Avoid unhandled event calling assert function

Signed-off-by: Matthias Hauser <matthias.hauser@we-online.de>
2025-01-24 15:42:07 +01:00
Fredrik Gihl
904089ddc5 driver: sensor: tmp116: oversample attribute
Add oversample attribute

Signed-off-by: Fredrik Gihl <fgihl@hotmail.com>
2025-01-24 15:41:50 +01:00
Daniel Mangum
cfe7b44b80 nrf_wifi: fix CONFIG_NET_L2_ETHERNET endif comment
Fixes endif comment that erroneously pointed to CONFIG_NRF70_STA_MODE.

Signed-off-by: Daniel Mangum <georgedanielmangum@gmail.com>
2025-01-24 11:00:47 +01:00
Tahsin Mutlugun
4c41ec7bea drivers: spi: spi_max32: Stop DMA if transaction times out
If DMA-based transaction fails, usually due to a timeout, DMA channels
may need to be explicitly stopped otherwise further calls to transceive
function will immediately return due to DMA constantly being busy.

Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
2025-01-24 11:00:27 +01:00
Tahsin Mutlugun
2e6f250127 drivers: spi: spi_max32: Handle hardware chip selection
Hardware chip select is originally handled by the HAL driver. However, a
finer grained control is needed to keep CS asserted between requests and
deassert it after last request is completed. Workaround this problem by
handling hardware chip select in Zephyr driver.

Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
2025-01-24 11:00:27 +01:00
Jordan Yates
2e711aaf81 wifi: nrf_wifi: eliminate NRF70_SYSTEM_MODE_COMMON
This symbol now has the same meaning as `NRF70_SYSTEM_MODE`.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2025-01-24 03:22:47 +01:00
Jordan Yates
d95de82b94 wifi: nrf_wifi: extract NRF70_SYSTEM_WITH_RAW_MODES
`NRF70_SYSTEM_WITH_RAW_MODES` is more accurately described as an
additional option on top of `NRF70_SYSTEM_MODE`, not as a unique
choice of `NRF70_OPER_MODES`.

This allows the elimination of multiple `NRF70_SYSTEM_MODE ||
NRF70_SYSTEM_WITH_RAW_MODES` dependencies.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2025-01-24 03:22:47 +01:00
Josuah Demangeon
21da345382 drivers: video: introduce video_bits_per_pixel(pixelformat) helper
This was present in the form of video_pix_fmt_bpp() inside ST and NXP
drivers, and was returning the number of bytes, which does not allow
support for 10-bits, 4-bits or non-byte aligned video formats.
The helper leverages the VIDEO_PIX_FMT_*_BITS macros.

Signed-off-by: Josuah Demangeon <me@josuah.net>
2025-01-24 03:22:31 +01:00
Pieter De Gendt
f1c4760304 drivers: Update APIs to use DEVICE_API macro
Some drivers APIs were not wrapped using the DEVICE_API macro.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-01-24 01:15:19 +01:00
Andrew Featherstone
48e179e5c9 drivers: counter: rpi_pico_timer: Correct support for RP2350
Changes introduced in 293b9a16ca didn't
verify correct behaviour when running `TIMER1` with `TIMER0` is paused,
and was reporting the wrong tick counter being incremented. Correct this
and extend the testing to verify correct behaviour.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2025-01-23 23:19:36 +01:00
Adrian Bieri
03fa6a0c33 mcux: drivers: xbara: drop HAS_MCUX_XBARA config
The HAS_MCUX_XBARA is replaced by the DT_HAS_NXP_MCUX_XBAR_ENABLED

Signed-off-by: Adrian Bieri <adrian.bieri@loepfe.com>
2025-01-23 19:25:54 +01:00
Mathias Landolt
96146d5740 mcux: drivers: xbarb: add XBARB config option
Add the possibility to activate the XBARB driver
Update NXP HAL revision to include support for xbarb

Signed-off-by: Mathias Landolt <mathias.landolt@loepfe.com>
Signed-off-by: Adrian Bieri <adrian.bieri@loepfe.com>
2025-01-23 19:25:54 +01:00
Vaishnav Achath
fca38adb7f drivers: mbox: Add support for TI OMAP mailbox
TI OMAP mailbox is the inter-processor mailbox IP found in TI
K3 devices (AM62X, AM64X, J721E .etc). The mailbox hardware uses
a queued mailbox interrupt mechanism that provides a communication
channel between processors through a set of registers and their
associated interrupt signals by sending and receiving messages.
The interrupt/bank associated with each processor entity is found
through the  usr_id property from device tree.

Signed-off-by: Vaishnav Achath <vaishnav.a@ti.com>
2025-01-23 16:34:39 +01:00
Kalle Kietäväinen
fa9126f5e8 drivers: bluetooth: hci: Increase default RX stack size
The `BT_DRV_RX_STACK_SIZE` config is used by HCI drivers to determine a
suitable stack size for their RX thread. These threads handle the HCI
transport and pass HCI messages to the Bluetooth host via `bt_hci_recv()`.
Previously, the default stack size was 256 bytes, but it seems to be too
small currently.

Measuring the peak stack usage of `bt_hci_recv()` in different scenarios
indicates that the function needs over 300 bytes of stack. Thus, an RX
thread stack size of 512 should cover that and leave some margin.

Signed-off-by: Kalle Kietäväinen <kalle.kietavainen@silabs.com>
2025-01-23 16:31:54 +01:00
Aksel Skauge Mellbye
14a00f259f drivers: spi: silabs: eusart: Always enable peripheral
The EUSART peripheral must always be enabled in configure(), as
its enable state gets cleared when the state machine is unretained
in deep sleep. The rest of the config registers are retained,
so they can continue to not be repainted on every configure() if
the context is the same as last time.

Remove unnecessary duplicated enable at the end of configure(),
the SPIInit HAL function already performs enable.

Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
2025-01-23 16:30:47 +01:00
Yishai Jaffe
12240a9058 shell: uart: add write command
Added a command to write to a uart device.

Signed-off-by: Yishai Jaffe <yishai1999@gmail.com>
2025-01-23 16:30:39 +01:00
Yishai Jaffe
1709731c5c shell: uart: fixed indentation
Fixed indentation to match line above.

Signed-off-by: Yishai Jaffe <yishai1999@gmail.com>
2025-01-23 16:30:39 +01:00
Xudong Zheng
020cb79d27 drivers: serial: nrfx_uarte: move DEPRECATED_UART_NRFX_UARTE_LEGACY_SHIM
The Kconfig option should be defined alongside
UART_NRFX_UARTE_LEGACY_SHIM for clarity.

Signed-off-by: Xudong Zheng <7pkvm5aw@slicealias.com>
2025-01-23 08:26:33 +01:00
Fabio Baltieri
9d34d5c104 i2c_shell: only include i3c if I3C=y
Only lookup for i3c devices if I3C=y, fixes a build error:

zephyr/drivers/i2c/i2c_shell.c:
In function 'device_is_i2c':
zephyr/drivers/i2c/i2c_shell.c:341:43:
error: array type has incomplete element type 'struct i3c_driver_api'
341 |         return DEVICE_API_IS(i2c, dev) || DEVICE_API_IS(i3c, dev);

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-01-23 08:26:21 +01:00
Sylvio Alves
3d3217ea6a hci: esp32: remove deprecated symbol
Make sure HAS_BT_CTLR is used instead
of deprecated BT_CTLR symbol.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2025-01-23 00:13:17 +01:00
Alberto Escolar Piedras
b151cd6bc7 drivers: entropy: Add new driver based on nrf54l cracen driver
Add a new entropy driver based on the nrf HAL CRACEN CTR DRBG driver

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2025-01-22 18:32:35 +01:00
Martin Hoff
576e475558 driver: serial: silabs: Change PM Device definition order
Change the definition order of the PM Device to fix the build error.

Signed-off-by: Martin Hoff <martin.hoff@silabs.com>
2025-01-22 15:50:14 +01:00
Eve Redero
f683b188b3 drivers: display: ssd1306: add power pin support
Add a power pin toggling feature in ssd1306 driver

Signed-off-by: Eve Redero <eve.redero@gmail.com>
2025-01-22 15:50:02 +01:00
Tomislav Milkovic
fb98387f4d drivers: can: can_tcan4x5x: fix compiler build warning/error
Fix compiler warning when optional property reset-gpios
is not supplied in the ti,tcan4x5x-compatible device tree
node

Signed-off-by: Tomislav Milkovic <tomislav.milkovic95@gmail.com>
2025-01-22 08:08:24 +01:00
Mathieu Choplain
8397d640d2 drivers: entropy: stm32: add support for STM32WB09 TRNG
Add support for the STM32WB09-specific TRNG IP in STM32 entropy driver.

Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
2025-01-22 08:07:40 +01:00
Mathieu Choplain
2347932431 drivers: entropy: stm32: add support for TRNG without interrupt line
Add support for TRNG peripherals that lack interrupt lines in the STM32
entropy driver.

This enables usage of the TRNG of STM32WB05/06/07 SoCs with the driver.

Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
2025-01-22 08:07:40 +01:00
Bas van Loon
e1ba85e9a2 drivers: ethernet: Fix DSA tag size for KSZ8863.
Allow DSA_TAG_SIZE to be set based on the size determined by Kconfig
and the enabled switch hardware.

This fixes support for the KSZ8863 which also has a tail tag of
one byte.

Signed-off-by: Bas van Loon <s.r.vanloon@ziggo.nl>
2025-01-22 05:40:58 +01:00
Fabio Baltieri
0bc123da11 drivers: drop few redundant device_is_ready
Drop few redundant device_is_ready for functions that are only used as
argument to shell_device_filter, as shell_device_filter checks for that
alrady.

Suggested-by: Yishai Jaffe <yishai1999@gmail.com>
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-01-22 05:40:11 +01:00
Fabio Baltieri
11b5e1f8f5 dac_shell: add device filtering
Add shell device name filtering using DEVICE_API_IS.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-01-22 05:40:11 +01:00
Fabio Baltieri
f3dac37f8a regulator_shell: add device filtering
Add shell device name filtering using DEVICE_API_IS.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-01-22 05:40:11 +01:00
Fabio Baltieri
0b2648ff40 i2c_shell: add device filtering
Add shell device name filtering using DEVICE_API_IS.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-01-22 05:40:11 +01:00
Camille BAUD
14fa2873b5 drivers: timer: run clang-format on RISC-V machine timer file
Clang-Format changes whitespacing and longer lines are now allowed

Signed-off-by: Camille BAUD <mail@massdriver.space>
2025-01-22 05:39:59 +01:00
Camille BAUD
f11f68eade drivers: timer: Harmonize mtime-based RISC-V timers
This commit replaces a bunch of ifdefs and bindings with a single
extensible binding, and makes all standard mtime system timers consistent.

Signed-off-by: Camille BAUD <mail@massdriver.space>
2025-01-22 05:39:59 +01:00
Camille BAUD
bf45c496bb drivers: timer: Remove unused divider setter in RISC-V machine timer
This removes a unused function for a unused binding,
and is prelude to a refactoring

Signed-off-by: Camille BAUD <mail@massdriver.space>
2025-01-22 05:39:59 +01:00
Marcio Ribeiro
4551f3410d drivers: display: ssd1306: add support to ssd1309
SSD1309 support added to SSD1306 display driver

Signed-off-by: Marcio Ribeiro <wmrsouza@hotmail.com>
2025-01-22 05:39:10 +01:00
Paul Wedeck
fda64760ba drivers: uart_wch: Fix compiler warning
This commit removes an unused variable.

Signed-off-by: Paul Wedeck <paulwedeck@gmail.com>
2025-01-21 19:30:53 +01:00
Carlo Kirchmeier
6d35071227 drivers: disk: sdmmc_subsys: stm32_sdmmc driver custom disk name support
In order to allow a custom disk name same as with the standard
sdmmc driver an additional device-tree property was introduced.

Signed-off-by: Carlo Kirchmeier <carlo.kirchmeier@zuehlke.com>
2025-01-21 19:29:36 +01:00
Martin Hoff
1318f1543c driver: serial: split silabs series 2 and series 0/1 boards usart driver
Split the USART driver into separate implementations for Silabs Series 2
and Series 0/1 boards. This change improves maintainability (especially
with the support of pin-ctrl and clock-ctrl on series 2 boards).

Signed-off-by: Martin Hoff <martin.hoff@silabs.com>
2025-01-21 19:29:25 +01:00
Sven Ginka
a89b81b110 drivers: serial: sy1xx add support for pinctrl
Add pin ctrl to the serial driver.

Signed-off-by: Sven Ginka <s.ginka@sensry.de>
2025-01-21 19:29:14 +01:00
Fabrice DJIATSA
7b379f47fa drivers: dma: add linked list in dmau5 driver
- Init linked list node and structure
- configure source and destination address
- Setting gpdma request mode
- Configure linked list node and structure for
continous transfer, enable half transfert irq.

Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
co-authored-by: Lubos Koudelka <lubos.koudelka@st.com>
2025-01-21 19:29:03 +01:00
Fabrice DJIATSA
ed92eeb3c8 drivers: dma: cyclic dma handling
keeping the stream busy when cyclic DMA is used.

Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
2025-01-21 19:29:03 +01:00
Tomasz Moń
45ee2a0b0d drivers: udc_dwc2: Fix multipart DMA OUT transfers
DMA transfers are supposed to write to buffer tail. Use the proper
pointer to make multipart DMA transfers actually write the data to the
intended location.

The issue was observed on control write transfers where the OUT Data
Stage was at least 128 bytes (because endpoint 0 transfer width is
limited to 7 bits).

The issue is unlikely to happen on non-control transfers because the
transfer size width is at least 11 bits (at most 19 bits) and packet
size counter is at least 4 bits (at most: 10 bits) which means that
at least 2048 byte transfer spanning at least 15 packets (or at least
524288 byte spanning 1023 packets for 19 bits transfer size counter
and 10 bits packet counter) is required to necessitate multipart DMA.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-01-21 19:28:13 +01:00
Tomasz Moń
883b77fe3b drivers: udc_dwc2: Recover after STALLed OUT Data Stage
Prepare buffer to receive SETUP data on OUT endpoint 0 after endpoint
halt. This solves the issue where the device would no longer process any
control transfers after the first failed transfer with too large OUT
Data Stage (when processing failed due to data stage buffer allocation
failure).

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-01-21 19:28:13 +01:00
Tomasz Moń
18be1d0768 drivers: udc_dwc2: Fix large control write transfers
The DOEPTSIZ0 XferSize field is 7 bits long, meaning that maximum single
transfer can be 127 bytes long. Configure the control write (OUT)
transfers considering the XferSize field size to support transfers with
data stage larger than 127 bytes.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-01-21 19:28:13 +01:00