Commit graph

23353 commits

Author SHA1 Message Date
Henrik Brix Andersen
6fa13e20e3 drivers: can: shell: properly sort mode table entries
Properly sort the entries in the can_mode_t translation table.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-03-11 14:20:50 +01:00
Jamie McCrae
cba1e34ef0 drivers: clock_control: Fix npcx leakage
Fixes an issue with Kconfig for this leaking into all devices where
it should not be

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-03-11 07:57:49 -04:00
Alberto Escolar Piedras
ad7086a2df drivers counter nrfx RTC: Fix ISR prototype
The ISR prototype is not matching the
signature for interrupt handlers, which results in
build warnings.
Let's fix it.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-03-08 19:00:46 +01:00
Angelo Dureghello
06df4b5ae9 drivers: ethernet: adin2111: fix real rx frame size
Fix issue related to "generic SPI" mode only, when a packet of
1512 bytes is received, net_pkt_write() fails and thrwos the error:

"Still some length to go 2".

This is due to net_pkt_rx_alloc_with_buffer() allocating a maximum
mtu/size of 1514, and driver is not removing 4 bytes of crc32 from
rx buffer, that comes to be 1516 (2 bytes over buffer limit).

Fix generic SPI rx frame size removing crc32 bytes.

Signed-off-by: Angelo Dureghello <adureghello@baylibre.com>
2024-03-08 18:04:06 +01:00
Angelo Dureghello
0ca8b0756b drivers: ethernet: adin2111: add Open Alliance SPI support
Add Open Alliance spi protocol support.

Open Alliance is a chunk-based SPI protocol, based on sending
over SPI an ethernet frame divided in smaller chunks, using a
specific 32-bit header for each chunk transferred. All chunks
can be sent or received by a single dma transfer.

Default mode is set to Open Alliance SPI without protection,
since the adin2111 dev. board comes shipped this way.

Tested:
- Open Alliance SPI, no protection (default board shipped)
- Open Alliance SPI, protection
- Generic SPI, no crc
- Generic SPI, with crc8

Signed-off-by: Angelo Dureghello <adureghello@baylibre.com>
2024-03-08 18:04:06 +01:00
Angelo Dureghello
06c8460a9e drivers: ethernet: adin2111: remove unused header_len variable
Non functional change, removing unused variable producing
compilation warning in "Generic SPI without CRC8" mode.

Signed-off-by: Angelo Dureghello <adureghello@baylibre.com>
2024-03-08 18:04:06 +01:00
Angelo Dureghello
27f2cfb797 drivers: ethernet: adin2111: fix generic spi withotut crc8 mode
After some debugging related to non-working "Generic SPI without CRC"
mode in eval_adin2111_ebz (CONFIG_ETH_ADIN2111_SPI_CFG0=n), noticed
that even after proper STATUS0 RESETC bit detection, registers,
for a certain period (some msecs) still reads as zero.

This patch fixes adin2111_await_device and with it the
"Generic SPI without CRC" mode.

Signed-off-by: Angelo Dureghello <adureghello@baylibre.com>
2024-03-08 18:04:06 +01:00
Angelo Dureghello
5784a3a78f drivers: ethernet: adin2111: always append crc32 to the eth frame
Enable appending of a crc32 at the end of the frame by the MAC,
always. This is always needed since the driver is not adding it.

This field has nothing to do with Generic SPI protocol-related
8-bit CRC, so this patch removes the CONFIG_ETH_ADIN2111_SPI_CFG0
choice related to this setting.

Testing without this flag set, packets are not forwareded in the
network, since the driver is not appending any crc32 header
to the frame.

Signed-off-by: Angelo Dureghello <adureghello@baylibre.com>
2024-03-08 18:04:06 +01:00
Angelo Dureghello
a653d59b65 drivers: ethernet: adin2111: fix imask1 tx_ready_mask
Fix IAMSK1 TX_READY_MASK bitfield position.

Signed-off-by: Angelo Dureghello <adureghello@baylibre.com>
2024-03-08 18:04:06 +01:00
Elias Speinle
c9c98d07e7 drivers: eth: esp32: support setting mac address during runtime
Add support for setting the mac address of the esp32
during runtime.

Signed-off-by: Elias Speinle <e.speinle@vogl-electronic.com>
2024-03-08 15:19:22 +00:00
Emil Gydesen
a5c2781c04 drivers: Bluetooth: HCI: Reduce logging of No available ISO buffers
In the case that there are no more ISO buffers left,
"No available ISO buffers" is logged. However, given the
nature of ISO where we are (very) likely to get additional ISO
very soon after (typically every 7.5 or 10ms for audio),
this will get logged a lot, and the logging may in some
cases actually prevent the application from handling and
freeing existng buffers due to the immense logging,
which may make this (minor) issue into a blocking issue.

This is fixed by reducing the logging to the first
occurence, and then only every 100 afterwards, which has
shown to reduce the risk of this effectively blocking
the application.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-03-08 15:18:54 +00:00
Ioannis Karachalios
96677e402e drivers: display: smartbond: Add support for the display driver class.
Exhibit Renesas LCD controller's driver implementation. The driver
is intended to employ the controller in the continuous mode so
it can drive display panels in the parallel RGB mode.

Signed-off-by: Ioannis Karachalios <ioannis.karachalios.px@renesas.com>
2024-03-08 10:21:06 +00:00
Miika Karanki
004c4769e3 drivers: flash: stm32 ospi refactor stm32_ospi_mem_erased args
Change to use dev pointer, from where the other parameters were
available as well.

Signed-off-by: Miika Karanki <miika.karanki@vaisala.com>
2024-03-08 09:39:07 +01:00
Miika Karanki
5d9acf52a5 drivers: flash: stm32 ospi: implement non busy wait polling
HAL_OSPI_AutoPolling is checking is the status match
happened in a busy loop. That CPU intensive operation
can cause starvation of other tasks especially on flash
erase operations which can take seconds to complete.

So, replace the use of HAL_OSPI_AutoPolling with
HAL_OSPI_AutoPolling_IT. The match results
HAL_OSPI_StatusMatchCallback being called.

Signed-off-by: Miika Karanki <miika.karanki@vaisala.com>
2024-03-08 09:39:07 +01:00
Laurentiu Mihalcea
b803e06099 drivers: dai: sai: use "dmas" property for handshake encoding
Since a DMA cell now allows specifying a channel and a MUX value
there's no need to fetch these values from the HAL. This, in turn,
allows for more flexibility and reduces the coding effort for new
platforms that want to use the SAI driver.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-03-08 09:38:25 +01:00
Lukasz Madej
f14228744f drivers: charger: charger_max20335: handle charger notifications
Add support for status and online notification properties.
Fire these notifications from int_routine_handler work directly.
Such approach makes the code cleaner and does not affect overall
max20335 interrupt processing performance. However application code
processing these notifications cannot be blocking.

Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
2024-03-08 09:38:03 +01:00
Pieter De Gendt
d288452ce1 drivers: ethernet: eth_adin2111: Fix build warning on 64bit
An overflow compiler warning is generated when building for native_sim_64,
add an explicit cast to fix -Werror builds.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-03-08 09:37:15 +01:00
Grzegorz Swiderski
f91323ee5d drivers: flash: Add flash driver for MRAM
Basic driver utilizing the flash API for NVM operations on the nRF54H20.

Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
2024-03-08 09:36:04 +01:00
Tomi Fontanilles
fd5c76ddfd drivers: modem_cellular: allow leaving out the chat_filter parameter
Allow not specifying the chat_filter parameter in a device
definition, which is equivalent to setting it to "".

Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
2024-03-07 21:38:24 +00:00
Benedikt Schmidt
c08b66cfee drivers: adc: set name for acquisition thread of MCP320x
Set the name of the acquisition thread for the ADC MCP320x.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2024-03-07 21:37:54 +00:00
Robert Lubos
35502592a7 drivers: input: Fix uninitialized closest_mv variable warning
Building with GCC 9.4.0 gives the following warning/error:

  error: closest_mv may be used uninitialized in this function

This commit fixes it.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2024-03-07 21:37:40 +00:00
Emilio Benavente
9815296500 dts: arm: Enabling pit for imx devices
Enabled the PIT and Multi channel support
for some of the rtXXXX devices.
- rt1010
- rt1060
- rt1160
- rt1170

Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
2024-03-07 13:23:58 -06:00
Emilio Benavente
8bb95d33be drivers: counter: Adding Mutli Channel PIT Support
Updating the nxp,pit driver to support mutliple
channels. Updating the dts and board overlays
to account for the changes.

Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
2024-03-07 13:23:58 -06:00
Emilio Benavente
9cb330e1ed drivers: counter: update nxp_pit api names
Update the api named for the new nxp pit
driver.

Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
2024-03-07 13:23:58 -06:00
Emilio Benavente
04b240c830 dts: bindings: renamed binding used for pit
Renamed pit binding from nxp,kinetis-pit
to nxp,pit

Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
2024-03-07 13:23:58 -06:00
Gerard Marull-Paretas
80cc7d1ee5 drivers: mbox: update MBOX consumers to the new API
Update all usages of the MBOX API to the latest API changes (to be
squashed for bisectability).

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-07 14:32:57 +00:00
Gerard Marull-Paretas
8be65b6608 drivers: mbox: refactor API
This patch refactors the MBOX API, so that it aligns with some common
Zephyr principles, main changes include:

- There is now a non-DT specific API that takes a regular struct device
  and a channel identifier, instead of a struct that contains both. This
  API should be used for cases where DT is not an option.
- There is a "dt-spec" variant of the API, meant to be used from
  devicetree specifications.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-07 14:32:57 +00:00
Gerard Marull-Paretas
e43ffcb5cd drivers: mbox: nxp_mailbox: add missing include
Add irq.h for IRQ_CONNECT.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-07 14:32:57 +00:00
Gerard Marull-Paretas
79490b9dc1 drivers: mbox: nxp_imx_mu: add missing include
Was causing build failures with IRQ_CONNECT missing.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-07 14:32:57 +00:00
Gerard Marull-Paretas
66b8a15899 drivers: mbox: andes_plic_sw: add missing include
Driver used spinlocks without including the necessary headers.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-07 14:32:57 +00:00
Reto Schneider
d5c3323e81 drivers: crypto: stm32: Allow immutable key
The passed key does not have to be modifiable. Adapting the signature to
reflect this.

This allows the following commit to change cipher_ctx:🔑:bit_stream
to be pointing to an immutable key.

Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
2024-03-07 10:58:23 +00:00
Phi Bang Nguyen
080f26f4d4 drivers: display: elcdif: Implement set_format API
Implement the set_format API so that applications can change format
at runtime instead of using the predefined one in the device tree.

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
2024-03-07 10:57:57 +00:00
Phi Bang Nguyen
f5e970de3f drivers: display: elcdif: Add support for ARGB8888 format
Add support for ARGB8888 pixel format as the camera pipeline on i.MX
RT11xx could output images in this format

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
2024-03-07 10:57:57 +00:00
Phi Bang Nguyen
ebf963590f drivers: display: elcdif: Run clang-format
Run clang-format before making changes

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
2024-03-07 10:57:57 +00:00
Phi Bang Nguyen
8b191103d7 drivers: dma: pxp: Add support for ARGB8888 format
Add support for ARGB8888 pixel format as the camera pipeline on i.MX
RT11xx could output images in this format

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
2024-03-07 10:57:57 +00:00
Phi Bang Nguyen
94afc4ee3d drivers: dma: pxp: Run clang-format
Run clang-format before making changes

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
2024-03-07 10:57:57 +00:00
Lyle Zhu
40cf23daff Bluetooth: Rename BT_BREDR to BT_CLASSIC
Rename BT_BREDR to BT_CLASSIC
Rename CONFIG_BT_BREDR to CONFIG_BT_CLASSIC

Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
2024-03-07 11:26:45 +02:00
Henrik Brix Andersen
49653d39dd drivers: can: extend support for automatic sample point location
Extend support for automatic sample point location to also cover
can_calc_timing() and can_calc_timing_data().

Previously, automatic sample point location was only supported by
can_set_bitrate() and can_set_bitrate_data().

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-03-06 15:23:13 -06:00
Henrik Brix Andersen
68f4f12c1b drivers: can: respect minimum supported prescaler value
Respect the minimum supported prescaler value when calculating CAN timing.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-03-06 14:18:08 +01:00
Henrik Brix Andersen
5e1ce7e0f7 drivers: can: minor improvements to internal timing calculation code
Improve the internal CAN timing calculation code readability by unifying
variable and function naming, avoiding unnecessary casting, and rewording
comments.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-03-06 14:18:08 +01:00
TOKITA Hiroshi
0f458c9564 drivers: led_strip: ws2812_rpi_pico_pio: Change output-pin to gpios
For sharing pin definition property with `worldsemi,ws2812-gpio`,
rename `output-pin` to `gpios`.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-03-06 14:17:27 +01:00
TOKITA Hiroshi
0702f0eb45 drivers: led_strip: ws2812_gpio: Rename in-gpios property to gpios
ws2812-gpio's `in-gpios` property is not used as an input pin.
Renaming it to `gpios` to reflect the actual situation.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-03-06 14:17:27 +01:00
Fabio Baltieri
8b9464089c input: add a pmw3610 driver
Add a driver for the Pixart PMW3610 mouse sensor device.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-03-06 13:34:16 +01:00
Martin Kiepfer
0addb90ff7 drivers: mfd: axp192: add possibility to disable N_VBUSEN functionality
By default N_VBUSEN signal is used by the host to define if VBUS
signal should be used for power supply (VBUS-IPSOUT).

This feature enables the possbibility to change this behaviour.
When N_VBUSEN detection is disabled, axp192 will automatically
decide to use VBUS (REG10H[7] = 1).
Please refer to datasheet for details.

Signed-off-by: Martin Kiepfer <mrmarteng@teleschirm.org>
2024-03-06 10:23:31 +00:00
Martin Kiepfer
2a83c58023 drivers: gpio: axp192: Add support to control EXTEN pin
AXP192 features an EXTEN pin that is on output only.

This commit appends control of EXTEN pin to gpio functionality
of AXP192.
Port-Mapping is as follows:
- [0..4]: GPIO0..4
- [5]: EXTEN

Signed-off-by: Martin Kiepfer <mrmarteng@teleschirm.org>
2024-03-06 10:23:31 +00:00
Martin Kiepfer
1a94b0ab24 drivers: regulator: axp192: Bugfix to control DCDC2 output
Fix wrong definition of DCDC2 register values.

Signed-off-by: Martin Kiepfer <mrmarteng@teleschirm.org>
2024-03-06 10:23:31 +00:00
Ioannis Karachalios
f011ad5bb1 drivers: mipi_dbi: smartbond: Add support for MIPI DBI driver class.
Add support for the MIPI DBI host controller.

Signed-off-by: Ioannis Karachalios <ioannis.karachalios.px@renesas.com>
2024-03-06 10:17:13 +00:00
Susan Su
a56c8cfa69 drivers: mipi_dsi: dsi_mcux: Remove DSI_DPHY_PLL_VCO definition
- The DSI_DPHY_PLL_VCO_MAX and DSI_DPHY_PLL_VCO_MIN macro value is
   different when changing to different SoC, so the definition is moved
   to soc level driver header.
 - Remove the definition in this c file to fix the duplicate definition
   issue.

Signed-off-by: Susan Su <susan.su@nxp.com>
2024-03-06 10:16:37 +00:00
Mykola Kvach
0af5376b90 drivers: pinctrl: move renesas pincontrol drivers to separate directory
Moved r8a77951/r8a77961 pfc tables and funcs from soc to drivers/pfc dir.

Move all Renesas pinctrl driver source and header files to a separate
directory "renesas" and every SoC series to a separate subdirectory.

Update the MAINTAINERS file to align with the changes in the
pinctrl directory.

Signed-off-by: Mykola Kvach <mykola_kvach@epam.com>
2024-03-06 10:09:11 +00:00
Mykola Kvach
dcce9f5ba0 drivers: pinctrl: r8a779f0: move pfc file from soc to driver dir
Move pfc_r8a779f0.c from the 'soc' directory to the 'drivers'
directory to avoid code duplication for the ARM64 Spider board.

Signed-off-by: Mykola Kvach <mykola_kvach@epam.com>
2024-03-06 10:09:11 +00:00