Commit graph

106854 commits

Author SHA1 Message Date
Manuel Argüelles
bfe3760123 doc: migration-guide-4.1: add note about nxp,kinetis-dspi change
Add note about compatible change for nxp,kinetis-dspi.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-12-06 22:22:51 +01:00
Manuel Argüelles
0aa73c8685 dts: bindings: rename nxp,kinetis-dspi compatible
Rename "nxp,kinetis-dspi" compatible to "nxp,dspi" to remove the
device family from its name.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-12-06 22:22:51 +01:00
Jamie McCrae
d68b54752c mgmt: mcumgr: transport: smp_udp: Use k_thread_join
Replaces code that peeked directly into the thread by instead
calling k_thread_join() to check the state of threads

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-12-06 22:22:32 +01:00
Andrej Butok
2befe3a1f2 boards: nxp: frdm_mcxw71: Add LinkServer runner support
Adds the LinkServer runner support for the FRDM-MCXW71 board.

Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
2024-12-06 22:22:15 +01:00
Daniel DeGrasse
c12030acb9 drivers: flash: flash_mcux_flexspi_nor: check all 3 bytes of JEDEC ID
The FlexSPI NOR driver should verify all 3 bytes of the JEDEC ID match
the expected value before attempting to use a custom LUT table with a
flash chip. This reduces the odds that an incompatible LUT will be used
with a flash chip, as some flash chips may share the same first byte of
their device ID but not be compatible with the custom LUT table.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-12-06 22:22:06 +01:00
Neil Chen
c6700e8ec5 boards: nxp: frdm_mcxa156: Support lptmr for NXP frdm_mcxa156 board
Support lptmr for NXP frdm_mcxa156 board.
Test using tests/drivers/counter/counter_basic_api.

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2024-12-06 22:21:54 +01:00
Neil Chen
faba3cd42a dts: arm/nxp: Add lptmr nodes to NXP MCXA156 dtsi file
Add lptmr nodes to NXP MCXA156 dtsi file

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2024-12-06 22:21:54 +01:00
Neil Chen
dbf1d58691 soc: mcxa156: update systick clock frequency to 96MHz
MCXA156 max frequeny is 96MHz

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2024-12-06 22:21:54 +01:00
Neil Chen
caf466aa31 boards: nxp: frdm_mcxa156: update doc index
Update board overview and hardware configuration

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2024-12-06 22:21:54 +01:00
Jilay Pandya
030444822e drivers: stepper: api: rename stepper_set_target_pos to stepper_move_to
rename stepper_set_target_position to stepper_move_to in following files:
- doc/hardware/peripherals/stepper.rst
- doc/releases/migration-guide-4.1.rst
- drivers/stepper/adi_tmc/adi_tmc5041_stepper_controller.c
- drivers/stepper/fake_stepper_controller.c
- drivers/stepper/gpio_stepper_controller.c
- drivers/stepper/stepper_shell.c
- include/zephyr/drivers/stepper.h
- include/zephyr/drivers/stepper/stepper_fake.h
- tests/drivers/stepper/shell/src/main.c
- tests/drivers/stepper/stepper_api/src/main.c

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
2024-12-06 22:21:44 +01:00
Jilay Pandya
05e94ed234 drivers: stepper: api: rename stepper_move to stepper_move_by
rename stepper_move to stepper_move_by in following files:
- include/zephyr/drivers/stepper.h
- include/zephyr/drivers/stepper/stepper_fake.h
- doc/hardware/peripherals/stepper.rst
- doc/releases/migration-guide-4.1.rst
- drivers/stepper/adi_tmc/adi_tmc5041_stepper_controller.c
- drivers/stepper/fake_stepper_controller.c
- drivers/stepper/gpio_stepper_controller.c
- drivers/stepper/stepper_shell.c
- tests/drivers/stepper/shell/src/main.c

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
2024-12-06 22:21:44 +01:00
Rait Rääk
220c4fffd3 net: ethernet: arp: Fix incorrect adding to the pending queue
k_fifo_put is a macro that expands the call to net_pkt_ref(pending)
multiple times when CONFIG_TRACING is enabled thus causing extra
reference for the pending packet and a memory leak.
Fix by moving the referencing call to a separate line.
Signed-off-by: Rait Rääk <raitraak@gmail.com>
2024-12-06 22:21:31 +01:00
Johan Hedberg
c49881870f boards: silabs: Remove redundant enabling of BT_SEND_ECC_EMULATION
This option gets the default value "y" whenever HAS_BT_CTLR is enabled, and
since the EFR32 HCI driver now selects HAS_BT_CTLR the right thing happens
either way.

Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
2024-12-06 22:21:21 +01:00
Johan Hedberg
ef82d753f5 drivers: bluetooth: Enable HAS_BT_CTLR for Silabs EFR32 driver
The controller behind the EFR32 driver is a local link layer
implementation, so it makes sense to select HAS_BT_CTLR.

Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
2024-12-06 22:21:21 +01:00
Henrik Brix Andersen
71df1e8d0c boards: st: nucleo_h745zi_q: m7: add missing zephyr,canbus chosen
Add missing zephyr,canbus chosen property.

Fixes: e68c7f2f73

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-12-06 22:21:10 +01:00
Andries Kruithof
6f180e49f9 Bluetooth: Audio: set correct project name in CMakeList.txt
Some of the unittests had an incorrect project name in the
CMakeList.txt file
This is corrected here

Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
2024-12-06 22:20:57 +01:00
Alexandru Lastur
9cebb3ff63 arm: mpu: Remove FLASH_0 mpu region when XIP=n
When not using CONFIG_XIP (CONFIG_XIP=n)
the FLASH_0 mpu region needs to be removed,
otherwise it will have the default base
address = 0, which means that MPU will try
to configure the region with address 0.
We don't want this as in some situations
address 0 can be a restricted memory region
such as ROM code.

Signed-off-by: Alexandru Lastur <alexandru.lastur@nxp.com>
2024-12-06 18:20:48 +01:00
Dmytro Firsov
da43d97627 Revert "arch: arm64: init xen in arch_kernel_init()"
This reverts commit 7c90f1bca1.

Xen initialization maps enlighten page to Zephyr memory and also
initializes Xen event channels. It is used for communication between
Xen domains and based on interrupt connected to domain virtual GIC.
Moving event channel initialization to arch_kernel_init() make it call
irq_enable() when GIC is not initialized. Since GIC is initialized
on PRE_KERNEL_1 stage, this lead to fatal error during boot.

Revert these changes to make xenvm operable again.

Signed-off-by: Dmytro Firsov <dmytro_firsov@epam.com>
2024-12-06 18:20:40 +01:00
Dmytro Firsov
f01498ec4d boards: xenvm: return separate defconfig for xenvm with GICv3
During migration to HWMv2 separate specific defconfig file was removed
for GICv3 version of virtual xenvm boards. It worked fine before
commit 0be0d2175b ("cmake: modules: extensions: Revert using common
board files") significantly changed build behavior, but did not return
previously removed file. This led to build/runtime issues, when some of
the Kconfig options were not selected.

Return GICv3 specific defconfig to board directory to fix configuration
problems.

Signed-off-by: Dmytro Firsov <dmytro_firsov@epam.com>
2024-12-06 18:20:40 +01:00
Théo Battrel
d5d3ac7427 Tests: Bluetooth: Build Host with different configurations
The new `host_config_variants` goal is to be able to test specific set
of configurations when building the Host without the need of having a
specific application for it.

The first test check that the Host build correctly with
`CONFIG_BT_SMP_OOB_LEGACY_PAIR_ONLY` enabled.

Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
2024-12-06 18:20:21 +01:00
Théo Battrel
30928c21f0 Bluetooth: Host: Remove unnecessary #ifndef
The functions `le_sc_oob_config_set`, `generate_dhkey` and
`display_passkey` in `smp.c` were only defined when
`CONFIG_BT_SMP_OOB_LEGACY_PAIR_ONLY` was not defined. This created
issues at build time.

Remove the guard as the code calling those functions is not guarded
itself.

Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
2024-12-06 18:20:21 +01:00
Seppo Takalo
9fa82f0d8d mgmt: smp: Fix race condition by using same work queue
Fix possible race condition where SMP client might
release the network buffer before system worker queue
has processed it.

In smp_client uses shared resources like worker queue
linked list and network buffers without maintaining any
thread safety.

For unknown reasons, retry timeout handling is pushed
into system worker queue while the actual transmission
is handled from SMP work queue.

Fix the issue by using the same SMP work queue
for both delayable timeout handling as well as
transmission handling.

Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
2024-12-06 18:20:10 +01:00
Robert Lubos
3163325e01 net: sockets: tls: Fix connect timeout error code
In case TLS connect timed out during the handshake, errno was set to
EAGAIN which is unexpected and confusing. Fix this and set the errno
to ETIMEDOUT instead.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2024-12-06 18:19:54 +01:00
Declan Snyder
0e52ec34c3 MAINTAINERS: Remove danieldegrasse from NXP areas
Remove danieldegrasse from NXP maintainers areas.

Substitute myself for the hal_nxp west project area.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-12-06 18:19:42 +01:00
Declan Snyder
5f3ea4d4d6 MAINTAINERS: Add MCUX USB driver area
Add an area specifically for the MCUX shim USB drivers,
as this code is primarily maintained by a subset of the NXP Driver
maintainers. Move MarkWangChinese to this area.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-12-06 18:19:42 +01:00
Declan Snyder
7bef17577e MAINTAINERS: Add NXP WIFI Driver area
Add an area specifically for the NXP WIFI driver code,
since this code is maintained by a different set of people
than the generic NXP Driver maintainers.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-12-06 18:19:42 +01:00
Emil Gydesen
e12096ee4a tests: Bluetooth: Tester: Increase RTT_MESSAGE_SIZE
Sets CONFIG_LOG_BACKEND_RTT_MESSAGE_SIZE=256 as some log
messages are longer than 128 (default) and may be truncated
with the existing configuration and implementation.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:55 +01:00
Emil Gydesen
56e7b7708e Bluetooth: Host: Add adv == NULL checks in adv.c
Added null checks for adv pointer in the extended and
periodic advertising functions.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:41 +01:00
Francois Ramu
444e59e478 dts: arm: stm32h7 hsi clock requires hsi-div property
The compatible: "st,stm32h7-hsi-clock"  has HSI clock divider
required which is set to 1, by default, delevering 64MHz
in the stm32h7.dtsi and stm32h7rs.dtsi
(As done for stm32h5 and other series)

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-12-06 15:17:32 +01:00
Benjamin Cabé
661161cd89 boards: wch: make minichlink default runner
This makes minichlink the default runner for the ch32v003evt.
This way, `west flash` "just works", as advertised in the README, rather
than having to manually set the runner to `minichlink` for it to work.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2024-12-06 15:17:17 +01:00
Emil Gydesen
13c42bd8a3 samples: Bluetooth: Use broadcast sink cbs in broadcast sink sample
Use the broadcast sink callbacks to set the semaphores
rather than the stream callbacks, as the broadcast sink callbacks
are better for that as they are called when all streams are ready.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:06 +01:00
Emil Gydesen
6e86b67afb samples: Bluetooth: Use broadcast source cbs in broadcast source sample
Use the broadcast source callbacks to set the semaphores
rather than the stream callbacks, as the broadcast source callbacks
are better for that as they are called when all streams are ready.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:06 +01:00
Emil Gydesen
829519dd6f Bluetooth: BAP: Add broadcast sink callback structs
These callbacks are trigger for changes that affect the entire
broadcast sink, such as the BIG synced and terminated events.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:06 +01:00
Emil Gydesen
0ae976166f Bluetooth: CAP: Add broadcast source callback structs
These callbacks are trigger for changes that affect the entire
broadcast source, such as the BIG started and terminated events.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:06 +01:00
Emil Gydesen
ab9ee0817d Bluetooth: BAP: Add broadcast source callback structs
These callbacks are trigger for changes that affect the entire
broadcast source, such as the BIG started and terminated events.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:06 +01:00
Emil Gydesen
e8bcb29f3f Bluetooth: ISO: Add BIG callbacks
Add callbacks that is called for the entire BIG.
The BIG state is from an HCI perspective a single state change
that we previously only propagated as a state change for each
channel.

However it may be simpler for applications and higher layers
to use BIG changes to trigger their behavior.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-12-06 15:17:06 +01:00
Timothy Keys
b3ffaf4441 Bluetooth: Host: Cancel pending deferred work on disconnect
This fixes an issue that occurred if deferred_work is queued by another
procedure before we run bt_conn_set_state(BT_CONN_DISCONNECTED).
bt_conn_set_state yields to the system work queue in bt_conn_tx_notify,
and then deferred_work runs and handles the disconnected callbacks.
bt_conn_set_state then enqueues another deferred_work which calls the
disconnected callbacks again and causes an assert. k_work_cancel_delayable
will clear queued deferred work when we call
bt_conn_set_state(BT_CONN_DISCONNECTED), guaranteeing that the disconnect
callbacks will only be called once.

Signed-off-by: Timothy Keys <timothy.keys@nordicsemi.no>
2024-12-06 15:16:43 +01:00
Michał Stasiak
4c96cbb79b soc: nordic: nrf54l: remove redundant ELV code
Removed dead ELV code from nRF54L soc.

Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
2024-12-06 15:16:29 +01:00
Junho Lee
a5389df5b9 boards: raspberrypi: rpi_5: Add RP1 GPIO support
Enable GPIO pins on the Raspberry pi 5.

Signed-off-by: Junho Lee <junho@tsnlab.com>
2024-12-06 12:14:37 +01:00
Junho Lee
0088b90b25 dts: arm64: broadcom: bcm2712: Add node for RP1 GPIO
Add RP1 GPIO node in the devicetree for BCM2712.

Signed-off-by: Junho Lee <junho@tsnlab.com>
2024-12-06 12:14:37 +01:00
Junho Lee
f157d50afd drivers: gpio: add RP1 GPIO driver
Add GPIO driver for RP1 peripheral controller on Raspberry Pi 5.

Signed-off-by: Junho Lee <junho@tsnlab.com>
2024-12-06 12:14:37 +01:00
Lyle Zhu
2b27b1cdd7 Bluetooth: HFP_AG: Update SDP discovery
Add set the parameter `type` to value
`BT_SDP_DISCOVER_SERVICE_SEARCH_ATTR`.

Update the SDP discovery callback function by adding a third parameter
`const struct bt_sdp_discover_params *params`. Make it align with
`bt_sdp_discover_func_t`.

Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
2024-12-06 12:14:29 +01:00
Lyle Zhu
d37402f447 Bluetooth: Shell: BR: Update command sdp-find
Since the function `bt_sdp_discover` has been updated, the caller of
function needs to be updated to avoid the building and functionality
fault.

Add set the parameter `type` to value
`BT_SDP_DISCOVER_SERVICE_SEARCH_ATTR`.

Update the SDP discovery callback function. Make it align with
`bt_sdp_discover_func_t`.

Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
2024-12-06 12:14:29 +01:00
Lyle Zhu
a047113556 Bluetooth: Classic: SDP: Improve SDP discover
Extend the function `bt_sdp_discover` to support service search
transaction and service attribute transaction.

Improve the `session->rec_buf`. If the net buffer cannot be allocated
from the channel, disconnect the SDP session.

Set the `MaximumAttributeByteCount` of the request
`SDP_SERVICE_SEARCH_ATTR_REQ` with the tail room of `session->rec_buf`.

Set the `MaximumAttributeByteCount` of the request `SDP_SERVICE_ATTR_REQ`
with the tail room of `session->rec_buf`.

Set the `MaximumServiceRecordCount` of the request
`SDP_SERVICE_SEARCH_REQ` according to the tail room of
`session->rec_buf`.

Handle the response code `SDP_SERVICE_SEARCH_RSP`, and
`SDP_SERVICE_ATTR_RSP`.

Handle the error `SDP_ERROR_RSP`. Start the next SDP discovery if the
error received.

If there no more request, disconnect the session.

If the request cannot be sent, start the next SDP discovery.

Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
2024-12-06 12:14:29 +01:00
Jyri Sarha
ff5a4581b2 drivers: timer: Export sys_clock_cycle_get_64() implementations
Export sys_clock_cycle_get_64() implementations to enable k_cycle_get_64()
calls from llext libraries.

Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2024-12-06 12:14:19 +01:00
Lucien Zhao
42ad39b169 drivers: i2s: update i2s_mcux_sai.c
On RT1180/RT700, there is no gpr register on soc,
so change driver to get configuration register base
address from dts, instead of hard code.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-12-06 12:14:10 +01:00
Krzysztof Chruściński
384e940c66 drivers: serial: nrfx_uarte: Deprecate CONFIG_UART_x_NRF_HW_ASYNC
Deprecate mode which is using TIMER+(D)PPI for reliable byte counting.
Recently a new approach is added (CONFIG_UART_NRFX_UARTE_ENHANCED_RX)
which supports reliable byte counting without additional HW resource.
This mode is planned to be the only supported RX path mode.

Enhanced RX has slightly different behavior. There are no partial RX
packets (events with non-zero offset). There is UART_RX_BUF_RELEASED
after each UART_RX_RDY event.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-12-06 12:14:02 +01:00
Lucien Zhao
30c45057ae tests: drivers: pwm: pwm_api: support mimxrt1180_evk board
Set tpm5 status as ok
add pwm-0 as aliases

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-12-06 12:13:54 +01:00
Lucien Zhao
d2040d103a boards: nxp: mimxrt1180_evk: add TPM support
add TPM pin setting
Record TPM supported in yml and doc

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-12-06 12:13:54 +01:00
Lucien Zhao
beb1e7b3a5 drivers: clock_control: update clock_control_mcux_ccm_rev2.c driver
Due to clock designed on RT1180 has some different with other platforms,
so add macro and handle the clock difference in mcux_ccm_get_subsys_rate.
TPM1 use Bus_Aon as clock root.
TPM3 use Bus_Wakeup as clock root.
Other instances have independent clock root.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-12-06 12:13:54 +01:00