Commit Graph

99663 Commits

Author SHA1 Message Date
Gerard Marull-Paretas
0e93eb3ad1 dts: bindings: pinctrl: nrf: add nordic,clock-enable
On new SoCs, certain pins need to enable the clock setting on the pin
for it to work properly. For now, this has been handled internally in
the pinctrl driver, however, it appears to be an instance-specific
property (e.g. UARTE/SPIM instances in the fast domain do not require
such setting). Move the configuration of this settings to DT, the best
place where to have instance-specific hardware settings.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 14:32:40 +02:00
Gerard Marull-Paretas
65b45e5760 drivers: serial: nrfx_uarte: add support for arbitrary peripheral clock
Some UARTE instances may be clocked at higher speeds than 16MHz, so the
baudrate setting needs to be scaled accordingly. This patch parses the
`clocks` property and obtains the clock-frequency property of the
associated clock, assuming it is a fixed-clock. We should ideally have a
proper clock control subsystem where frequency can be queried using an
API, but we're far from there.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 14:32:40 +02:00
Gerard Marull-Paretas
7c011741fa dts: nordic: nrf54h20: set clocks for uart120 instance
UARTE120 is clocked by HFSFLL120 instance.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 14:32:40 +02:00
Gerard Marull-Paretas
2552978df3 dts: nordic: nrf54h20: define hsfll120 instance
HSFLL120 is a clock used by fast peripherals, and it is controlled by
the system controller. From an application perspective, it is a fixed
clock. Note that it has multiple outputs (clk_main @ 320MHz, and
clk_main2|4 which provide the main clock divided by 2 and 4,
respectivelu). Only the main frequency is represented for now.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 14:32:40 +02:00
Gerard Marull-Paretas
a41a22f3e1 dts: bindings: clock: fixed-clock: include base.yaml
Include base.yaml, so that properties like `clocks` can be optionally
set.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 14:32:40 +02:00
Gerard Marull-Paretas
c2cbbd7238 dts: nordic: nrf54h20: fix uarte120 IRQ
It's 230, not 229.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 14:32:40 +02:00
Damian Nikodem
ed31037d5f drivers: ssp: fix program of MLCS register
Programming of the MLCS register was performed on the incorrect bits.
Additionally, saving the new version did not erase the previously set
value, which could result in an incorrect register value.

Signed-off-by: Damian Nikodem <damian.nikodem@intel.com>
2024-08-06 10:28:16 +02:00
Chaitanya Tata
65bdf6564b samples: net: wifi: Fix stack sizes
Wi-Fi sample is stack heavy, so, by default increase the stack sizes to
work with any driver, esp. those use WPA supplicant like nRF Wi-Fi.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-08-06 10:27:21 +02:00
Chaitanya Tata
bf4f51a7c6 samples: net: wifi: Fix scan results dropping
Wi-Fi shell prints scan results to the console taking time and this puts
pressure on net_mgmt Queue, so, increase both timeout and Queue depth to
handle crowded Wi-Fi channel (~200 APs).

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-08-06 10:27:21 +02:00
Chaitanya Tata
051c63f6a9 boards: shields: Add nRF70 series EKs (Evaluation kits)
These shields in the Arduino form factor can be mounted on supported
boards and can provide Wi-Fi6 capability.

Base shield is nRF7002, with variants as nRF7001 (2.4GHz only) and
nRF7000 (dual band scan only).

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-08-06 10:27:21 +02:00
Chaitanya Tata
638ce2fbfd drivers: wifi: Add nRF70 Wi-Fi driver
Driver for Nordic nRF70 Wi-Fi6 companion chipset, depends on
hal_nordic/nrf_wifi for OS agnostic part of the driver.

This supports (Q)SPI interface to communicate from host to chip.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-08-06 10:27:21 +02:00
Chaitanya Tata
d1f2e7d6e7 manifest: hal_nordic: Pull nRF70 OSAL driver
This pulls in OS agnostic parts of the nRF70 Wi-Fi driver.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-08-06 10:27:21 +02:00
Chaitanya Tata
1d18144e64 dts: bindings: wifi: Add nRF70 Wi-Fi support
Add necessary bindings for the nRF70 Wi-Fi chips from Nordic
semiconductors ASA.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-08-06 10:27:21 +02:00
Fabio Baltieri
9036400ad0 west.yml: remove two redundant repo-path
The repo-path field is meant to override the repository name if it's
different than the module name, drop two cases where repo-path has no
effect.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-08-06 09:19:56 +01:00
Shang Xiangyao
fae0f5bb77 drivers: input: cst816s: add cst816d support
The CST816D touch chip is similar to the CST816S, with the primary
difference being the chip ID. This commit extends the existing
CST816S driver to support the CST816D by adding its chip ID. There
are no other modifications.

Signed-off-by: Shang Xiangyao <shxyke@gmail.com>
2024-08-06 09:19:49 +01:00
Tahsin Mutlugun
11dc47da24 tests: i2c: i2c_target_api: Remove unneeded properties in I2C nodes
For commonly-accessible I2C nodes, status and pinctrl are now set in
board dts. Remove these properties from test overlay files.

Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
2024-08-06 09:19:42 +01:00
Tahsin Mutlugun
771d8b51a3 boards: adi: Enable commonly used I2C nodes by default
Enable commonly-used I2C in ADI MAX32 boards by default to access I2C
functionality without having to create an additional overlay file.

Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
2024-08-06 09:19:42 +01:00
Georges Oates_Larsen
1c79445059 net: net_if: fix net_if_send_data for offloaded ifaces
Some offloaded ifaces have an L2, but lack support for
net_l2->send. This edge case is not handled by
net_if_send_data, resulting in a NULL dereference under
rare circumstances.

This patch expands the offloaded iface guard in
net_if_send_data to handle this edge case.

Signed-off-by: Georges Oates_Larsen <georges.larsen@nordicsemi.no>
2024-08-06 09:19:36 +01:00
Matt Rodgers
e4dff4ad14 samples: net: coap_download: Add sample application for coap_client API
Added a sample application demonstrating how to use the coap_client API
to download a resource via GET request.

Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
2024-08-06 09:19:15 +01:00
Gerard Marull-Paretas
3029bb1fbf boards: nrf5340dk: create shared files for LEDs/buttons/connector
It looks like both cpuapp/cpunet cores share the same definitions for
LEDs, buttons and Arduino connector. This patch puts these repeated
definitions into a single shared file.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:19:05 +01:00
Benjamin Cabé
43b948f9a8 net: ptp: Properly handle second overflow/underflow
Fixes issues with net_ptp_time arithmetic where second
overflow/underflow would not be handled properly.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
2024-08-06 09:17:26 +01:00
Benjamin Cabé
dff19c3ac6 net: ptp: Adjust clock using correct offset
Offset should be *subtracted* from current clock value, not added.
This was causing clock to accumulate error instead of actually
"converging".

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-08-06 09:17:26 +01:00
Katarzyna Giądła
8753534077 tests: subsys: storage: flash_map: Extend timeout storage.flash_map.mpu
The test `storage.flash_map.mpu` for `nrf52840dk/nrf52840` fails
althought the output is correct. Time to test execution is not enough.
This change extend test execution timeout.

Signed-off-by: Katarzyna Giądła <katarzyna.giadla@nordicsemi.no>
2024-08-06 09:17:20 +01:00
Gerard Marull-Paretas
a1fda68003 doc: releases: migration-guide: add nRF52/53 regulator changes
Inform users about Kconfig options deprecation and show what is the
alternative with some examples.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
d11db98d42 dts: bindings: regulator: add nordic,nrf91x-regulators
To describe nRF91X specific REGULATORS IP.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
9d72903840 drivers: usb: use DT regulator properties
Instead of CONFIG_SOC_DCDC_NRF52X[_HV], about to be deprecated.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
1eddb047f9 soc: nordic: nrf53: deprecate SOC_DCDC_NRF53X*
Regulators can now be configured using DT.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
4d56244faf boards: nrf53*: use DT to configure regulators
Instead of board level options selecting SOC_DCDC_NRF53X*.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
2c3270db43 soc: nordic: nrf53: allow configuring regulators using DT
Instead of Kconfig options which are about to be deprecated.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
7feacc62d1 dts: arm: nordic: nrf5340: instantiate regulators
Instantiate all available regulators: VREGMAIN, VREGRADIO and VREGH.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
e5e01a7f33 dts: bindings: regulator: add nordic,nrf53x-regulator-hv
nRF53X HV regulator differs from eg nRF52X as it offers a silent mode
option. For this reason, a new compatible is used, even if now such
capability is not exposed yet.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
8d6695030f dts: bindings: regulator: add nordic,nrf53x-regulators
nRF53X regulator IP is specific to that series, eg, not equal to nRF91X.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
aaacd682cc soc: nordic: nrf52: deprecate SOC_DCDC_NRF52X[_HV]
Main supply can now be configured using DT.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
9097d5dac5 boards: nrf52*: use DT to configure regulators
Instead of board level options selecting SOC_DCDC_NRF52X or
SOC_DCDC_NRF52X_HV.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
e189fb0720 soc: nordic: nrf52: add support for DT-based regulators config
In addition to Kconfig options (soon to be deprecated), allow
configuring the regulators using DT.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
af0353210c dts: arm: nordic: nrf52x: instantiate regulators
The SoC main supply is part of the POWER IP block. The POWER IP is a
kind of multi-purpose block, so each of its functions is described as a
child node in DT, like similar other MFD. This allows to have specific
properties, e.g. for DC/DC mode.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Gerard Marull-Paretas
02a30c1c2b dts: bindings: regulator: add nordic,nrf5[2]x-regulator[-hv]
Some Nordic SoCs, like nRF52 contain an internal regulator for the main
SoC supply. Depending on the SoC, the regulator can have multiple
configurations (e.g. single/double stage), which mainly depends on
supporting "high-voltage" mode or not (VDDH pin supply). This patch adds
bindings for nRF5X regulator and nRF52X HV regulator.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 09:17:10 +01:00
Jordan Yates
bdcd5d00d0 scripts: twister: twisterlib: cwd relative path
When presenting an example of how to run a failing test case with
`west build`, provide the source dir path relative to the current
working directory, not the zephyr root directory.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-08-05 18:41:14 -04:00
Fengming Ye
86b5b59928 net: wifi: shell: add DPP commands
DPP shell command handler will parse user args to params in enum
and send l2 mgmt DPP requests.

Signed-off-by: Fengming Ye <frank.ye@nxp.com>
2024-08-05 18:40:17 -04:00
Fengming Ye
1640826fc5 net: wifi_mgmt: add hostap DPP support
Add wifi l2 mgmt dpp handlers.
Add wifi subcommand dpp to call l2 mgmt dpp handlers.

DPP l2 handlers will parse params to hostap wpa_cli format args
and send wpa_cli commands to hostap.

Signed-off-by: Fengming Ye <frank.ye@nxp.com>
2024-08-05 18:40:17 -04:00
Ravi Dondaputi
37491cb0f7 wifi: utils: Get correct channel count
For 2.4GHz and 6GHz bands, while counting the channels in configured
range, start of the range is being counted twice. Correct this
by advancing the index by 1 while counting channels in range.

Signed-off-by: Ravi Dondaputi <ravi.dondaputi@nordicsemi.no>
2024-08-05 18:39:58 -04:00
Pavlo Yadvychuk
76de42f707 boards: WeAct: Add STM32F405 Core board
The WeAct STM32F405 Core Board is an extremely low cost and bare-bones
development board featuring the STM32F405RG, 64-pin variant of
the STM32F405x series.

Signed-off-by: Pavlo Yadvychuk <pyadvichuk@gmail.com>
2024-08-05 18:39:46 -04:00
Flavio Ceolin
1fe98407ce espi: ite: Use proper flexible array
Use proper flexible array instead of a GNU extension.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-08-05 18:38:42 -04:00
Flavio Ceolin
15ac8407a6 i2c: ite: Use proper flexible array
Use proper flexible array instead of a GNU extension.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-08-05 18:38:42 -04:00
Flavio Ceolin
90870eb9b1 entropy: Use proper flexible array
Use proper flexible array instead of a GNU extension.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-08-05 18:38:42 -04:00
Flavio Ceolin
cbb9613d83 dai: intel/ssp: Use proper flexible array
Use proper flexible array instead of a GNU extension.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-08-05 18:38:42 -04:00
Flavio Ceolin
4eb3db13bc sys: util: Add macro to declare flexible arrays
Flexible arrays are arrays declared without a specific size, e.g:
uint8_t my_array[];

They are widely used as as last member in structs that are dynamically
allocated.

Since C99 they are part of the C standard, but for historical reasons
many places still use an older GNU extension that is declare zero
length arrays.

Although zero length arrays are flexible arrays, we can't blindly
replace [0] with [] because of some syntax limitations. This macro
workaround these limitations while get rid of this non standard
extension.

Using true flexible arrays allows the compiler to calculate the size
of the array better and improve potential issue checking.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-08-05 18:38:42 -04:00
Tomasz Chyrowicz
4c541eb216 scripts: nrf_common: Use cfg for SUIT paths
It is safer to base the SUIT artifacts path on the path of the
configuration file than the HEX file that is being flashed.
The latter may be overriden by several scripts that merge/transform the
final firmware image.

Signed-off-by: Tomasz Chyrowicz <tomasz.chyrowicz@nordicsemi.no>
2024-08-05 18:38:23 -04:00
David van Rijn
f65fe18273 net: lwm2m: Fix c++ cupport for lwm2m.h
lwm2m.h was missing the extern "C" block
and it used a forward declaration to an enum,
which is illegal in c++.

Signed-off-by: David van Rijn <david@refractor.dev>
2024-08-05 18:37:59 -04:00
Declan Snyder
d4d56de4d4 drivers: bt_nxp: Use DT code partition if needed
Remove the logic from the board level about overriding the
flash load size and instead just select to use the DT code
partition if app is not expected to be able to occupy the
whole flash space because of the firmware image being
loaded separately.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-08-05 18:37:35 -04:00