Commit graph

23353 commits

Author SHA1 Message Date
Naveen Gangadharan
27d5528174 drivers: i3c: cadence: fix tx_fifo width for target mode on REV_ID 1.7
Cadence I3C target FIFO width has been increased to 4 bytes in i3c
hardware REV_ID 1.7. Writing 1 byte to 4 byte FIFOs can cause
unintentional padding for bytes written from TX threshold interrupt
handler. Fixed the target callback to handle tx width of i3c target
writes to FIFO, by using run time rev_id check.

Signed-off-by: Naveen Gangadharan <naveeng1001@meta.com>
2024-09-23 10:02:01 +02:00
Chew Zeh Yang
62c0fc3e14 drivers: gpio_ambiq: Fixed uninitialized return variable
Fixed uninitialized return value variable issue, which would cause
functions to wrongly return non-zero value despite a successful
execution.

Signed-off-by: Chew Zeh Yang <zeon.chew@ambiq.com>
2024-09-23 10:01:40 +02:00
Quy Tran
c17a8d3e84 drivers: i2c: change to use IRQ_CONNECT in Renesas RA i2c driver
Change to use IRQ_CONNECT instead of IRQ_DIRECT_CONNECT

Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
2024-09-23 10:01:26 +02:00
TOKITA Hiroshi
923f47dd80 drivers: auxdisplay: Remove unused variables
Remove unused variables for suppress warnings

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-09-21 12:23:51 +01:00
TOKITA Hiroshi
945f9291c4 drivers: led_strip: tlc5971: Enable when the dt-node exists
The TLC5971_STRIP config enables if the "ti,tlc5971" node exists.
Also, removing the setting that explicitly enables in the
`tests/drivers/build_all/led_strip` test.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-09-21 12:23:45 +01:00
Fabian Blatz
c525dc0813 drivers: stepper: Add fake stepper driver
Add `zephyr,fake-stepper` compatible which can be used inside of unit
tests.

Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2024-09-21 12:23:19 +01:00
Fabian Blatz
c694858d06 drivers: stepper: add stepper shell
Add shell commands to enable/disable, move, set velocity, configure
micro-step resolution, and display stepper motor status. Includes an
`info` command to output all relevant data with graceful handling of
unsupported features.

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2024-09-21 12:23:19 +01:00
Chekhov Ma
c93a5de3ae drivers: mcux_igpio: improve pin-gaps handling
Improve handling of "pin-gaps" using "GPIO_DT_RESERVED_RANGES_NGPIOS"
series macro.

Signed-off-by: Chekhov Ma <chekhov.ma@nxp.com>
2024-09-20 15:18:49 -05:00
Chekhov Ma
a296705d37 drivers: mcux_rgpio: improve pin-gaps handling
Improve handling of "pin-gaps" using "GPIO_DT_RESERVED_RANGES_NGPIOS"
series macro.

Signed-off-by: Chekhov Ma <chekhov.ma@nxp.com>
2024-09-20 15:18:49 -05:00
Felipe Neves
591b7d380b drivers: video: gc2145: add resolution support
Add VGA and QVGA resolution support to enable
usage of gc2145 sensor by smaller ram capable devices.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
2024-09-20 15:18:13 -05:00
Tom Chang
9795dc2758 drivers: espi: npcx: add support to customize vw index
This CL adds support to revise vw index accroding to the
vw-index-extend-set.

Signed-off-by: Tom Chang <CHChang19@nuvoton.com>
2024-09-20 15:14:57 -05:00
Tom Chang
0e4ac766fb drivers: espi: npcx: add support for DnX VW
This CL adds support to handle DnX virtual wire signal.

Signed-off-by: Tom Chang <CHChang19@nuvoton.com>
2024-09-20 15:14:57 -05:00
Declan Snyder
448485a967 drivers: soc_mcux_flash: Add flash_k4 support
Add support for flash_k4 api from the mcux SDK.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-09-20 15:14:11 -05:00
Declan Snyder
2db9ea94de drivers: kinetis-pinctrl: Account for SCG K4
Add support for SCG K4 clock control in kinetis pinctrl.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-09-20 15:14:11 -05:00
Declan Snyder
a8b1ac26d8 drivers: clock_control: Add MCUX SCG K4 driver
Add driver for newer SCG clock control peripheral.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-09-20 15:14:11 -05:00
Stefan Gloor
2571ae8b19 drivers: mipi_dbi: add support for parallel 8080/6800 modes using GPIO
Introduce GPIO-based driver for MIPI DBI class that allows MIPI DBI
type A and B displays to be used on general platforms.

Since each data pin GPIO can be selected individually, the bus pins are
set in a loop, which has a significant negative impact on performance.
When using 8-bit mode and all the data GPIO pins are on the same port,
a look-up table is generated to set the whole port at once as a
performance optimization. This creates a ROM overhead of about 1 kiB.

Tested 8-bit 8080 mode with ILI9486 display on nRF52840-DK board.

Signed-off-by: Stefan Gloor <code@stefan-gloor.ch>
2024-09-20 11:56:22 -05:00
Stefan Gloor
ac8816068d drivers: display: ili9xxx: read mipi-mode, only use SPI mode as fallback
Instead of always using the SPI MIPI DBI mode (type C), look up the
mipi-mode from the device tree and only set the mode to
MIPI_DBI_MODE_SPI_4WIRE as a fallback in case the property is not given.

Signed-off-by: Stefan Gloor <code@stefan-gloor.ch>
2024-09-20 11:56:22 -05:00
Filip Kokosinski
0abc9fb8be boards: remove CONFIG_PINCTRL from defconfig files of FE310-based boards
This commit removes the y-selection of the `CONFIG_PINCTRL` Kconfig option
in FE310-based boards defconfig files.

It also makes drivers used in FE310 y-select `CONFIG_PINCTRL` if pinmuxing
is needed.

Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
2024-09-20 13:14:41 +02:00
Laurentiu Mihalcea
b26d21fcfd drivers: dma: dma_nxp_edma: support 64-bit TCD
On some EDMA versions, some TCD registers (e.g: SADDR, DADDR,
SLAST, DLAST, etc...) are extended to 64 bits via adding a new
HIGH register holding the value of bits [63:32]. Since, for now,
the driver doesn't support 64-bit addresses, this scenario is
supported by sign-extending the 32-bit value written to SLAST/DLAST.
SADDR and DADDR are taken care of on HAL side.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-09-19 18:02:42 -04:00
Laurentiu Mihalcea
7eb07479eb drivers: dma: dma_nxp_edma: support MUX register in MP space
Some EDMA versions may have the channel MUX register in the MP
region. To support this scenario, use the `EDMA_HAS_MP_MUX_FLAG`
flag to figure out which channel MUX register to use (TCD or MP).

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-09-19 18:02:42 -04:00
Yong Cong Sin
f6d5c2e4b4 drivers: intc: shared_irq: change init and isr function to static
Device init & ISR functions should be made static.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2024-09-19 18:28:58 +01:00
Bjarki Arge Andreasen
3ed1b40688 drivers: wifi: nrfwifi: determine shared iovdd and bucken from dt
Currently a user, or a shield definition, must select a Kconfig to
signal that the iovdd_ctrl and bucken GPIOs are connected to the same
pin. We can instead check this in the driver by simply checking if
the iovdd_ctrl_spec and bucken_spec are the same pin.

Update the nrfwifi driver and remove the redundant
NRF_WIFI_COMBINED_BUCKEN_IOVDD_GPIO config.

Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
2024-09-19 18:27:36 +01:00
Lucien Zhao
23f58fd3a4 dts: arm: nxp: rt1180: add lpadc modules
Register all the lpi2c instances.

Add no-power-level property and update driver
to adapt no-power-level property.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-09-19 18:16:04 +01:00
TOKITA Hiroshi
a88ee692b9 drivers: ieee802154: mcr20a: Specify the dependency on HAL_MCUX
The mcr20a driver referencing `MCR20Overwrites.h` which is under
`hal/nxp/mcux`.

So, put `depends HAS_MCUX` for clarify the dependency.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-09-19 15:14:06 +02:00
TOKITA Hiroshi
cbec7c8569 drivers: counter: Specify _POSIX_C_SOURCE when native_sim
When building with native_sim, We need to specify

```
 #define _POSIX_C_SOURCE 200809L
```

to make `gmtime_r` available.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-09-19 15:13:57 +02:00
Felipe Neves
4713707e92 drivers: mbox: mbox_esp32: fix mbox callback call
Fixes the mailbox notification callback that was not
being called from the ISR when the other side sends
something.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
2024-09-19 03:25:57 -04:00
Tim Lin
fd5ecef59e drivers/i2c: it8xxx2: Add a property for maximum time allowed I2C transfer
Add a property of the maximum time allowed for an I2C transfer.

Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
2024-09-18 19:56:43 +01:00
Alexandre Bailon
3341298c0c drivers: ieee802154: cc13xx_cc26xx: Enable support of OpenThread L2
This updates the driver to enable support of OpenThread L2.

Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
2024-09-18 15:32:09 +02:00
Alexandre Bailon
f44072c299 drivers: ieee802154: cc13xx_cc26xx: Fixup a bus error
Sometime, the radio causes a bus error.
This happens because we cast a struct and access to a member
that doesn't exists in the original struct.
This updates the driver to use the right struct to make the cast safe.

Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
2024-09-18 15:32:09 +02:00
Alexandre Bailon
2cef27865f drivers: flash: cc13xx_cc26xx: Add support of write to flash from flash
Currently, if we try to write data from a memory mapped flash address
to the flash then we get a -EINVAL error.
This could break the settings subsystem when we use NVS backend.

In order to make it work, add a buffer and use it when we want to
write data that is located in flash address space.

This has been tested using sample/subsys/settings/

Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
2024-09-18 15:32:09 +02:00
Tomasz Moń
6582529d1f drivers: usb: udc_dwc2: Restrict TxFIFO to SPRAM size
Do not allocate TxFIFO in a way that could corrupt Endpoint Information
Controller data (stored at DFIFO Depth address) or access locations
outside the SPRAM.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2024-09-18 15:30:45 +02:00
Yong Cong Sin
7ebd3decd8 drivers: counter: shell: device name autocompletion
Add timer device name autocompletion to the commands.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2024-09-18 15:30:35 +02:00
Yong Cong Sin
a3d9ede341 drivers: counter: shell: change callback functions to static
These callback functions are not used outside of the file, make
them `static`

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2024-09-18 15:30:35 +02:00
Guennadi Liakhovetski
531bbbdf65 Revert "ace: mm: tlb: Check tlb translation enabled before flushing cache"
This reverts commit 311ddf90e2. That
commit breaks firmware boot on both MTL and LNL.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
2024-09-18 15:30:03 +02:00
Pisit Sawangvonganan
a9800e2ea7 style: drivers: adjust return usage in void functions
For code clarity, this commit adjusts the use of `return` statements
in functions with a void return type as follows:
- Transform `return foo();` into separate statements:
  `foo();`
  `return;`
- Remove unnecessary `return` statements when
  they don't affect control flow.

Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
2024-09-18 09:56:16 +02:00
Luis Ubieda
53f547b737 serial: bluetooth: Maximize notification payload size based on ATT MTU
By keeping track of run-time ATT MTU of all connected peers, it's
possible to increase the notification payload size; thus increasing
data-throughput sent over Bluetooth.

Note that this assumes the Bluetooth connection is properly configured
(with the corresponding connection parameters) to optimize performance.
This is application-specific and shall be examined on each scenario for
optimal performance.

Signed-off-by: Luis Ubieda <luisf@croxel.com>
2024-09-17 20:12:55 -04:00
Quy Tran
3ccd52b657 drivers: spi: update casting for MSTP register
Update casting for MSTP register in SPI driver

Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
2024-09-17 20:10:46 -04:00
Felipe Neves
c24e8a3820 drivers: video: gc2145: fixes the prefix
of the compatible driver, use galaxycore
instead of gc.

Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
2024-09-17 20:10:31 -04:00
Ryan McClelland
b0442e24f1 drivers: i3c: shell: record getcaps in to desc from shell
Record the getcaps values in to the i3c desc from the shell command.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-09-17 20:06:13 -04:00
Ryan McClelland
d2b0f70ddc drivers: i3c: add helper for if target is controller capable
Add the function, i3c_device_is_controller_capable, to determine if
a target is controller capable.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-09-17 20:06:13 -04:00
Ryan McClelland
93dc6113bc drivers: i3c: fix static addr for deftgts AC
The Active Controller data struct for static addr is to always be
0x7E. This is so the active controller can be identified according
to section 5.1.9.3.7 of the I3C v1.1.1 Specification.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-09-17 20:06:13 -04:00
Ryan McClelland
a338f7c710 drivers: i3c: shell: add hdr ddr shell commands
Add read and write hdr ddr shell commands.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-09-17 20:06:13 -04:00
Ryan McClelland
d6bff46d99 drivers: i3c: shell: add ibi shell commands
This adds ibi commands for hot-join, controller request, and target
interrupt request.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-09-17 20:06:13 -04:00
Ryan McClelland
86f7ccf10a drivers: i3c: shell: add i3c speed command
Add a shell command to set the i3c scl speed.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-09-17 20:06:13 -04:00
Ryan McClelland
1036310e8b drivers: i3c: set vendor ccc command target arg to const
The target argument was not const. Set it to be const.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-09-17 20:06:13 -04:00
Keith Short
9d999149e3 drivers: gpio: stm32: Fix compiler warning
The local function ll_gpio_get_pin_pull() is not always referenced.  Add
the __maybe_unused attribute to avoid compiler warnings (which may be
promoted to errors by downstream users).

Signed-off-by: Keith Short <keithshort@google.com>
2024-09-17 14:58:57 -04:00
Andrea Merello
cc61e96860 drivers: sensors: fix compile error due to conflicting types.
Since b249535 (sensors: Add channel specifier) the signature of
sensor_reconfigure_read_iodev() changed, but sensor_handlers.c
apparently hasn't been updated.

Fix compile time error by updating sensor_reconfigure_read_iodev()
signature in sensor_handlers.c

Signed-off-by: Andrea Merello <andrea.merello@iit.it>
2024-09-17 14:57:32 -04:00
Fabio Baltieri
f7c0a643df kscan: mark the kscan driver class as deprecated
All kscan drivers have been moved over to input, Mark the kscan driver
class as deprecated so it can be removed in the 4.2 release.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-09-17 14:52:50 -04:00
Armin Kessler
2ba893e0cb drivers: video: esp32s3
Add the missing calls to the sensors`video_stream_start()`
and `video_stream_stop()` functions.

Signed-off-by: Armin Kessler <ake@espros.com>
2024-09-17 17:45:27 +01:00
Marcio Ribeiro
de53fb471a drivers: i2s: esp32: remove unused code
Removed unused code in I2S driver.

Signed-off-by: Marcio Ribeiro <marcio.ribeiro@espressif.com>
2024-09-17 09:10:51 -05:00