Commit graph

25,525 commits

Author SHA1 Message Date
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
Andrew Featherstone
1c50ba489f drivers: rtc: rpi_pico: Add alarm support to RPi Pico RTC driver
This adds support for the alarm functionality of the RPi Pico RTC.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-03-06 10:08:48 +00:00
Andrew Featherstone
df8c89b528 drivers: rtc: rpi_pico: Add support for the Raspberry Pi Pico RTC
This adds the minimal get_time/set_time support for the rp2040 and
enables support by default on the Pico boards. This doesn't support
configuring the clock source or alarm interrupts yet.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-03-06 10:08:48 +00:00
Andrew Featherstone
4c880f4b0a drivers: rtc: Create utility function for time validation
RTC drivers should validate the `struct rtc_time`'s contents against the
provided `mask`. Promote this common code to a new rtc_utils file and
modify existing drivers to use this functionality. Extend the test
coverage to include verifying this behaviour.

This is groundwork ahead of adding support for the RP2040's (as used in
the Raspberry Pi Pico) RTC and alarm.

Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
2024-03-06 10:08:48 +00:00
Krzysztof Chruściński
c975910f84 drivers: spi: nrf: Add new SPIS instances
Add support for upcomming SPIS instances.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-03-06 10:48:01 +01:00
Lukasz Madej
d97cebd3ca drivers: charger: charger_max20335: fix properties set
Charger hardware configuration registers are set to zero every time
external voltage is applied. Assure proper charger configuration by
buffering properties set by application and applying them at external
voltage connection event notified via interrupt.

Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
2024-03-05 18:23:12 +00:00
Lukasz Madej
e38729de63 drivers: charger: charger_max20335: support charger online
Add support for charger online property.

Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
2024-03-05 18:23:12 +00:00
Lukasz Madej
d43e627938 drivers: charger: charger_max20335: relocate charger state definition
An anonymous enum describing charger status is used only by one
function therefore reduce scope of this enum.

Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
2024-03-05 18:23:12 +00:00
Lukasz Madej
90c32e99d6 drivers: charger: charger_max20335: introduce int utilization
Utilization of chip interrupt line is mandatory to assure proper
charger state control. Handle interrupt to prepare the driver for
implementation of such functionality.
Modify charger status update so the current state is fetched in the
interrupt handler.

Use level based interrupts combined with interrupt disabling for a
period of time after interrupt handling to reduce number of interrupts
triggered by the charger. There may be a case where the charger
produces burst of interrupts for a several seconds and if the code
attempts to handle every single interrupt separatery then the system
might be significantly overloaded.

Co-authored-by: Bartosz Bilas <b.bilas@grinn-global.com>
Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
2024-03-05 18:23:12 +00:00
Lukasz Madej
e9eb1d841e drivers: charger: charger_max20335: fix argument name
Rename `current_uv` argument name to `voltage_uv` in function
max20335_get_constant_charge_voltage() to make the name aligned with
its usage.

Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
2024-03-05 18:23:12 +00:00
Lukasz Madej
d8ebe7b6c9 drivers: charger: charger_max20335: rename status get function
Current driver handles charger status only but the charger chip
provides plenty of different statuses. Change name of
max20335_get_status() function to max20335_get_charger_status()
to make further implementations easier.

Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
2024-03-05 18:23:12 +00:00
Gerard Marull-Paretas
0b38425f6d drivers: mbox: nrf_bellboard: add initial driver
Add a new driver for nRF BELLBOARD peripheral, in both local and remote
modes.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-05 16:50:36 +00:00
Gerard Marull-Paretas
78c40fe31b drivers: mbox: add initial driver for nRF VEVIF
Add a mailbox driver for VEVIF. The driver can be built in either
'local' or 'remote' configuration. This depends on the existence of the
'interrupts' property, which signals that the instance is managed
locally. VEVIF is, as expected, always managed by a VPR core.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-05 16:50:36 +00:00
Gerard Marull-Paretas
d23ea62be9 drivers: misc: nordic_vpr_launcher: initialize earlier
Set driver to initialize at early POST_KERNEL, so that we make sure
other future dependencies priorities (eg VEVIF) do not conflict.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-03-05 16:50:36 +00:00
TOKITA Hiroshi
ca520f8493 drivers: display: Add LED-Strip matrix display driver
Adds a driver for a display of LED strips arranged in a grid.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
2024-03-05 09:44:24 -05:00
Tom Burdick
0b980e1bae i2c: Add rtio support to mcux lpi2c driver
A seperate driver for NXP's LPI2C using RTIO and the I2C RTIO context
rather than semaphores, allowing for work to be done from any call
context at any time.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-03-05 09:43:38 -05:00
Tom Burdick
0dbc3d712c i2c: Use i2c_rtio context in sam twihs driver
Updates the sam twihs rtio driver to use a common i2c_rtio context
object and fixes a few logic issues currently in the driver in the
process.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-03-05 09:43:38 -05:00
Tom Burdick
bafac2c689 i2c: Add helpers and context for i2c rtio drivers
Implementing RTIO drivers, in theory, should be as simple as the normal
i2c drivers and generally be more consistent across implementations. To
do that some common code that calls driver specific code is needed much
like the venerable spi_context and its helpers.

This adds struct i2c_rtio as well as helpers to perform blocking i2c
transfers, i2c bus recovery, and similar such tasks.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-03-05 09:43:38 -05:00
Tom Burdick
e8b528321a i2c: Select rtio when I2C_RTIO is selected
Rather than a depends on, which leaves it up to every single usage
of I2C_RTIO to then go and select RTIO, by selecting I2C_RTIO Kconfig
inherently selects RTIO now.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-03-05 09:43:38 -05:00
Tom Burdick
4c8b1e2d1e rtio: Add I2C configure operation
In order to serialize all of the i2c functionality an added op code for
configuring the i2c controller was needed. Thankfully very simple.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-03-05 09:43:38 -05:00
Tom Burdick
c3a0ea02a7 i2c: Add a new API test using (f/s/nv)ram
RAM allows for very fast reads and writes and lets us explore most of
the I2C controller APIs including RTIO. Theoretically supports any form
of i2c connected RAM but requires some tweaking to work with specific
parts potentially. Tested with Fujitsu's MB85 FeRAM part using an
arduino breakout.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2024-03-05 09:43:38 -05:00
Andy Sinclair
b46e2f3d8a drivers: regulator: fake: Added is_enabled property
Added is_enabled devicetree property to fake regulator.
Allows testing of init behaviour when regulator is enabled
in hardware.

Signed-off-by: Andy Sinclair <andy.sinclair@nordicsemi.no>
2024-03-05 09:43:17 -05:00
Andy Sinclair
977fc0c2ad drivers: regulator: common: Added regulator-boot-off
Added regulator-boot-off option to common regulator driver.

Signed-off-by: Andy Sinclair <andy.sinclair@nordicsemi.no>
2024-03-05 09:43:17 -05:00
Laurentiu Mihalcea
a1188a96ff drivers: dai: sai: use TDR/RDR for fifo base address computation
Using the address of RDR/TDR for fifo base address computation
has the same effect as using the FSL_FEATURE_SAI_{TX/RX}_FIFO_BASEn
macro from NXP HAL. The only difference between the two is that
the macro is not defined for all SoCs so whenever we introduce
a new SoC that uses the SAI module we have to also introduce
the macro for said SoC. Using TDR/RDR has the advantage that
it doesn't require any additional changes to the NXP HAL.

Since we only support one data line per direction, it's fine
to just use RDR[0] and TDR[0] for the address computation.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-03-05 14:34:19 +01:00
Andrzej Kuros
8e8d4af6c1 drivers: ieee802154_nrf5: Use Radio IRQ number from DT
Used RADIO_IRQ number is based on information provided by DT rather
than direct use of RADIO_IRQn.

Signed-off-by: Andrzej Kuroś <andrzej.kuros@nordicsemi.no>
2024-03-05 12:22:08 +01:00
Laurentiu Mihalcea
705d579685 drivers: dma: dma_nxp_edma: allow channel re-configuration
Currently, the state transition function doesn't allow
the re-configuration of an already configured channel
(i.e: CHAN_CONFIGURED -> CHAN_CONFIGURED transition). This
causes problems when using `pulseaudio` and `SOF` because
the same channel ends up being configured multiple times
in the beginning due to how pulse seems to work. Logically
speaking, re-configuring an already configured channel is
not wrong so this commit solves the issue by allowing
the CHAN_CONFIGURED -> CHAN_CONFIGURED transition.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-03-05 10:57:07 +01:00
Cong Nguyen Huu
46d6e2e099 nxp_s32_canxl: use RTD API instead the current can_nxp_s32_abort_msg() API
On HAL RTD version 1.0.0, there is available Canexcel_Ip_DeactivateMD()
API that have similar capabilities as can_nxp_s32_abort_msg() API,
can use to instead.
Remove the reg grp_ctrl and reg base_dsc_ctrl that unused
after implementation this.

Signed-off-by: Cong Nguyen Huu <cong.nguyenhuu@nxp.com>
2024-03-05 10:54:50 +01:00
Tomi Fontanilles
62d84fb322 drivers: modem_cellular: fine tune nRF91's shutdown_time
A shutdown lasting more than 5 seconds was experienced.

Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
2024-03-04 22:13:14 +01:00
Fabio Baltieri
7d676c2331 input: pat912x: add a bunch of settings
Add devicetree based settings for resolution, axis inversion and sleep
mode enable. Keep the resolution setting in its own function so it can
be called by the application again in runtime if needed.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-03-04 22:10:58 +01:00