Commit graph

25,525 commits

Author SHA1 Message Date
Daniel Schultz
7f31129d70 driver: serial: uart_shell: read: Return correct return code
Always return exit code 0 when cmd_uart_read stopped reading
data from UART. Instead, return with a error code in case
reading from the UART interface failed.

Currently, this command might return with exit code -1 because
uart_poll_in didn't return data and the read duration expired.

Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
2025-06-27 12:23:14 +02:00
Fin Maaß
596cd64bb9 drivers: ethernet: use DT_INST_PROP_OR for local-mac-address
use DT_INST_PROP_OR for local-mac-address, so
that it is not required to be set in dt, as there are
other ways to se the mac address.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-27 12:22:49 +02:00
Fin Maaß
5f83aea9e4 drivers: ethernet: sensry: fix mac addr order
make sure, that zephyr,random-mac-address
has a higher prio, than local-mac-address, as
documented in ethernet-controller.yaml.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-27 12:22:49 +02:00
Fin Maaß
4b6ccbdd1f drivers: ethernet: xmc4xxx: random mac only on dt
only set a random mac if zephyr,random-mac-address
is set in dt.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-27 12:22:49 +02:00
Fin Maaß
5638d9fa47 drivers: ethernet: nxp: fix mac addr order
make sure, that zephyr,random-mac-address
has a higher prio, than local-mac-address, as
documented in ethernet-controller.yaml.

Also make sure, that no vaild mac address
doesn't lead to init fail, as it can still be
set later via set_config.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-06-27 12:22:49 +02:00
Chun-Chieh Li
7179ef51fe drivers: serial: numaker: support hw-flow-control
This honors dts config hw-flow-control to enable flow control cts/rts
at driver init stage.

Signed-off-by: Chun-Chieh Li <ccli8@nuvoton.com>
2025-06-27 12:22:12 +02:00
Gaetan Perrot
fae619a916 drivers: sensor: lsm6dsv16x: fix uninitialized struct in enable_wake_int
Zero-initialize lsm6dsv16x_pin_int_route_t to fix Coverity warning.

CID: 516227

Signed-off-by: Gaetan Perrot <gaetan.perrot@spacecubics.com>
2025-06-27 10:58:58 +02:00
Gaetan Perrot
5de04c61b6 drivers: video: fix uninitialized struct in ov2640_init()
Initialize fmt with default format and zero pitch to fix Coverity.

CID: 524780

Signed-off-by: Gaetan Perrot <gaetan.perrot@spacecubics.com>
2025-06-27 10:58:43 +02:00
Tomasz Moń
d29719e27e drivers: udc_dwc2: Disable endpoints asynchronously
Do not synchronously wait for endpoint interrupt bits when disarming
endpoints. Introduce ep_disabled k_event that makes it possible for
application to wait for the action to take effect which is necessary
when handling SetFeature(ENDPOINT_HALT) or SetInterface() requests.

This change improves incomplete iso IN and OUT handling performance,
especially when there are multiple isochronous endpoints that need
servicing.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-06-27 10:58:09 +02:00
Tomasz Moń
9aff5da68a drivers: udc_dwc2: Optimize incomplete iso handling
At High-Speed there is at most 25 us handling window for incomplete iso
IN/OUT and therefore determining which endpoints are isochronous is too
wasteful. Add lookup variable holding which isochronous endpoints are
enabled and limit the search to only enabled endpoints. For applications
with just one OUT and one IN isochronous endpoint this is optimal.

The lookup variable is updated only when mutex is held. Interrupt
handler accesses the variable read-only and in general there is no
problem is incomplete iso handling interrupt hits when the lookup
variable is updated, because:
  * when endpoint is just activated, it cannot be source of incomplete
    iso interrupt because the endpoint is not armed yet
  * when endpoint is just deactivated, it was first disabled

If there is more than one isochronous endpoint same direction then just
relying on endpoint enabled is not necessarily optimal. However, in
order to be able to limit the search to only armed endpoints, the lookup
variable would have to be updated on every transfer preparation and
completion which would require more time-expensive synchronization.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-06-27 10:58:09 +02:00
Tomasz Moń
70cd0ab567 drivers: udc_dwc2: Use spin lock for synchronization
Replace irq_lock() with spin lock which is proper synchronization
primitive that should be used. Because non-SMP implementations are
allowed to optimize spin lock to just locking interrupts the resulting
code is the same on all currently supported DWC2 targets.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-06-27 10:58:09 +02:00
David Jewsbury
c237253fe7 drivers: spi: Support spim01/spis01 instances for nordic devices
Extend SPI driver to support spims01 and spim01.

Signed-off-by: David Jewsbury <david.jewsbury@nordicsemi.no>
2025-06-27 10:58:02 +02:00
Bjarki Arge Andreasen
2609cfbf4a drivers: spi: nrfx spim: impl device deinit
Implement device deinit for nRF SPIM device driver.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-27 10:57:59 +02:00
Tomasz Moń
46b11f1fb2 drivers: udc_dwc2: Inline vendor quirks if possible
Constify vendor quirks structure to not keep it in RAM. Use constified
vendor quirks structure directly if there is only one snps,dwc2 instance
to allow compiler inlining quirk implementation.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
2025-06-27 10:57:47 +02:00
Steven Chang
03227c3520 drivers: watchdog: watchdog driver
Add watchdog driver for ENE KB106X

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-06-27 10:57:20 +02:00
Steven Chang
7ce78aa294 drivers: pwm: pwm driver
Add pwm driver for ENE KB106X

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-06-27 10:57:20 +02:00
Steven Chang
bffb1530ab drivers: adc: adc driver
Add adc driver for ENE KB106X

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-06-27 10:57:20 +02:00
Steven Chang
43f311bf61 drivers: uart: uart driver
Add uart driver for ENE KB1200

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-06-27 10:57:20 +02:00
Steven Chang
7d2be3bbff drivers: gpio: gpio driver
Add gpio driver for ENE KB106X

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-06-27 10:57:20 +02:00
Steven Chang
d9310b6648 drivers: pinctrl: pinctrl driver
Add pinctrl driver for ENE KB106X

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-06-27 10:57:20 +02:00
Saravanan Sekar
f7df5e84e3 drivers: pwm: Add a support for TI MSPM0 Timer PWM
TI MSPM0 SoC series has General Purpose Timer and Advanced control timers
with Compare block which is used to generate time expiry and output
waveform like PWM. Add driver support for MSPM0 PWM output.

Signed-off-by: Saravanan Sekar <saravanan@linumiz.com>
2025-06-27 10:57:05 +02:00
Saravanan Sekar
f672430b3b drivers: counter: Add vendor prefix ti to timer clock
Add vendor prefix ti to timer clock property prescale and divider.

Signed-off-by: Saravanan Sekar <saravanan@linumiz.com>
2025-06-27 10:57:05 +02:00
Julien Panis
5b728969ce drivers: spi: cc23x0: Add loopback mode option
When loopback mode is enabled, the output of transmit serial shifter
is connected to the input of receive serial shifter internally.

Signed-off-by: Julien Panis <jpanis@baylibre.com>
2025-06-27 10:56:54 +02:00
Julien Panis
11cbfeafe6 drivers: spi: cc23x0: Add support for DMA mode
Two DMA channels are assigned to TX and RX respectively:
- A TX DMA single request is asserted when there is space in the FIFO.
- A RX DMA single request is asserted when data is in the FIFO.

Signed-off-by: Julien Panis <jpanis@baylibre.com>
2025-06-27 10:56:54 +02:00
Tony Han
a8cf696748 drivers: clock_control: microchip: sckc: optimize get_rate, get_status
Optimize sckc_get_rate() to be called without configurations in
parameter, the selection of slow clock of the timing domain directly
comes from the register.
Optimize sckc_get_status() with return value "CLOCK_CONTROL_STATUS_ON",
slow clock is always on either driven by the RC oscillator or by the
32.768 kHz crystal oscillator.

Signed-off-by: Tony Han <tony.han@microchip.com>
2025-06-27 09:42:36 +02:00
The Nguyen
eb1b2e06e1 drivers: i3c: shell: enable i3c shell support for renesas,ra-i3c
This commit introduces support for i3c shell on Renesas RA devices

Signed-off-by: The Nguyen <the.nguyen.yf@renesas.com>
2025-06-27 09:42:22 +02:00
Ta Minh Nhat
096801f1a9 driver: i3c: initial i3c driver basic support for RA family
This commit introduces basic support for I3C master mode.

Signed-off-by: Ta Minh Nhat <nhat-minh.ta.yn@bp.renesas.com>
2025-06-27 09:42:22 +02:00
Bjarki Arge Andreasen
3198db1b12 drivers: sensor: nxp: p3t1755: impl pm device runtime
Implement pm device runtime for p3t1755 sensor.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-26 18:51:26 -10:00
Ryan McClelland
ea8f69c6b1 drivers: i3c: create i3c bus helpers
Create bus helpers that will send ccc commands as well as update
items within the i3c descriptor. These are different than the
direct ccc functions as these can give a bit of convience to also
updating the descriptor.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2025-06-26 18:50:43 -10:00
Cong Nguyen Huu
003e391a8f drivers: introduce Single Edge Nibble Transmission (SENT) driver
This driver allows to communication (receive data) with SENT device

Signed-off-by: Cong Nguyen Huu <cong.nguyenhuu@nxp.com>
2025-06-26 18:50:07 -10:00
Tony Han
9f0ca750f8 drivers: i2c: sam: fix the exception when transferring without data
The issue is found when doing shell command "i2c scan" on sama7g54-ek.
In this case no data will be transferred besides START and STOP. Data
abort would occur on accessing "msg->buf[msg->idx++]" when MMU is
enabled and "msg->idx" is very large.

Signed-off-by: Tony Han <tony.han@microchip.com>
2025-06-26 22:19:09 -05:00
Bjarki Arge Andreasen
f22ffee5c3 drivers: i2c: nrfx_twis: impl device deinit
Implement device deinit hooks for nRF TWIS device driver.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-26 22:15:52 -05:00
Bjarki Arge Andreasen
bd73c739b4 drivers: i2c: nrfx_twim: impl device deinit
Implement device deinit for the nRF TWIM device drivers.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2025-06-26 22:15:52 -05:00
Raymond Lei
a93a80be82 drivers: nxp: flexspi: fix hyper flash hang issue
CS hold time parameter is not correct which may cause bus fault
randomly.
System hang during status register reading after flash progromming which
is caused by parameter accessing in XIP mode.
Add dummy delay for READ command according the flash datasheet which is
required for SDR mode.
Use FlexSPI internal divider for clock updating instead of register in
CCM to avoid potential risk caused by flash access during clock updating
procedure.

Signed-off-by: Raymond Lei <raymond.lei@nxp.com>
2025-06-26 22:14:38 -05:00
Qiang Zhao
2d06a90865 firmware: scmi: add set_rate api
add scmi_clock_set_rate function to set rate,
and assign it to set_rate api

Signed-off-by: Qiang Zhao <qiang.zhao@nxp.com>
2025-06-26 22:11:04 -05:00
Qiang Zhao
0337527e74 drivers: flash: flexspi: Add octal mode support for MT35 family
MT35 flashes could run in octal mode, Now the driver doesn't support
octal mode, add octal mode support for MT35 flashes.

Signed-off-by: Qiang Zhao <qiang.zhao@nxp.com>
2025-06-26 22:11:04 -05:00
Philipp Steiner
f7e723dad1 drivers: fuelgauge: Add Onsemi LC709203F driver
Add driver for the Onsemi LC709203F fuel gauge

Signed-off-by: Philipp Steiner <philipp.steiner1987@gmail.com>
2025-06-26 22:08:44 -05:00
Qiankun Li
d5a9a0fa87 drivers: wifi: nxp: Fix embedded supplicant stations link mode issue.
The link mode of legacy staions is specifically
divided into Wi-Fi_1, Wi-Fi_2 and Wi-Fi_3.

Signed-off-by: Qiankun Li <qiankun.li@nxp.com>
2025-06-26 22:07:09 -05:00
Qiankun Li
26f4d9b551 drivers: wifi: nxp: Fix getting error stations twt capability issue.
When external station connects to soft ap,
fill ap_sta_info.twt_capable with external
station HE capability.

Signed-off-by: Qiankun Li <qiankun.li@nxp.com>
2025-06-26 22:07:09 -05:00
Qiankun Li
f1b781577e drivers: wifi: nxp: Fix embedded supplicant link mode issue.
1. When external stations connect to soft ap,
   Wi-Fi driver will send UAP_CLIENT_ASSOC event with data.
   nxp_wifi_wlan_event_callback will be called to process this event.
2. The data should include some basic station information
   but not only mac address of station.
3. Fill ap_sta_info with information of
   connected station but not soft ap self.
4. Fix: Wi-Fi driver send UAP_CLIENT_ASSOC event
   with basic station information.
5. Fix: ap_sta_info with information of connected station.

Signed-off-by: Qiankun Li <qiankun.li@nxp.com>
2025-06-26 22:07:09 -05:00
Raymond Lei
0d2935218c drivers: spi: nxp: fix PCS broken issue and PCS_HOLD_ON support
Different LPSPI IPs are used for RT11xx and MCXN. On a older version of
LPSPI, a transmit command or a TX data need to be issued to end a frame.
On a new version, no such requirement.

Based on above information, we have to make DMA transfers "cascade" in
the DMA ISR to keep CS asserted during the whole SPI transfer.

PCS_HOLD_ON is a feature to keep CS asserted during multi SPI transfers.
It is implemented and supported on new LPSPI IP but it is impossible to
be supported on an older version like RT11xx.

Signed-off-by: Raymond Lei <raymond.lei@nxp.com>
2025-06-26 22:06:04 -05:00
Declan Snyder
ab9b9bfab3 spi_nxp_lpspi: Add slave mode support
Add rudimentary slave mode support to the interrupt based LPSPI driver.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2025-06-26 11:07:55 -10:00
Sylvio Alves
9952180987 soc: espressif: sync hal to latest updates
1) Bring latest hal_espressif updates/sync to latest v5.1 branch.
2) Update RF libraries for bug fixes and improvements
3) Add necessary BLE Kconfig entries to support latest changes.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2025-06-26 10:51:45 -10:00
Tony Han
95454914bf drivers: rtc: sam: update for supporting RTC of sama7g5 devices
The basic characteristics of "atmel,sam-rtc" is the same as the ones
of sama7g5.

Differences between the RTCs listed bellow:
                    | atmel,sam-rtc | rtc in sama7g5
--------------------|---------------|----------------------
Persian calendar    |      Y        |         N
UTC Mode support    |      N        |         Y
Tamper Timestamping |      N        |         Y

Signed-off-by: Tony Han <tony.han@microchip.com>
2025-06-26 10:42:39 -10:00
Jérôme Pouiller
ffebf73079 drivers: wifi: siwx91x: Assign variable on declaration
When a variable is assigned once, we try to assign it during the
declaration.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-06-26 11:03:08 -05:00
Jérôme Pouiller
8d1d8d2b86 drivers: wifi: siwx91x: Prefer WIFI_MAC_ADDR_LEN
The preferred way to reference the size of the MAC address is
WIFI_MAC_ADDR_LEN.

For consistency, replace ARRAY_SIZE(mac.octet) with WIFI_MAC_ADDR_LEN.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-06-26 11:03:08 -05:00
Jérôme Pouiller
2ae23f7c58 drivers: wifi: siwx91x: Do not set unused values
We avoid to assign unused values during declaration. Hence, the reader
knows that every value assigned are meaningful. It also allow compile to
raise true warning if a value is used uninitialized.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-06-26 11:03:08 -05:00
Jérôme Pouiller
0b8f7d85bc drivers: wifi: siwx91x: Uniformize error management
Usually, the exception are treated in a condition before the nominal
case:

    ret = f();
    if (ret) {
        return -EXXX;
    }
    ... nominal case ...

siwx91x_on_join_ipv4() and siwx91x_on_join_ipv6() didn't follow this
pattern.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-06-26 11:03:08 -05:00
Jérôme Pouiller
a89dc21a2b drivers: wifi: siwx91x: Uniformize declaration of 'interface'
sl_wifi_interface_t interface is always initialized with
sl_wifi_get_default_interface().

Let's assign the value during the declaration everywhere.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-06-26 11:03:08 -05:00
Jérôme Pouiller
56fb22fba8 drivers: wifi: siwx91x: Group ARG_UNUSED() after declarations
We want to avoid declarations after statements.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-06-26 11:03:08 -05:00