Commit graph

17,121 commits

Author SHA1 Message Date
Jukka Rissanen
7c62cd32cb net: pkt_filter: Reformat macro lines
Shorten long lines with \ chars in NPF_PRIORITY macro so that the output
looks good if user is using narrower window to view the code.
Reformat \ in NPF_RULE macro so that the code looks better.

Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
2025-12-12 15:38:18 -05:00
Jason He
24c510ec54 drivers: clock: mcux_ccm: add USB clock control support
Add USB_CLK and USB_PHY_CLK support for NXP EHCI controller on MIMX9352.

Signed-off-by: Jason He <jason.he_1@nxp.com>
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
Signed-off-by: Jony Zhang <jony.zhang@nxp.com>
2025-12-12 09:58:32 -05:00
Anuj Pathak
c4e857c9fd dts: i2s: add i2s node for max32655fthr
- add basic dma only i2s dts binding for max32-i2s
- add i2s node with default config to max32655.dtsi
- add i2s pin definition for max32655fthr board as per spec

Signed-off-by: Anuj Pathak <anuj@croxel.com>
2025-12-12 05:01:31 -05:00
Benjamin Cabé
bef6cdb127 sys: util: add sys_ prefix to SIGN, gcd, and lcm utils
As per our naming conventions for public symbols, these utility functions
and macros should be prefixed with "sys_".

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-12-12 04:58:14 -05:00
Benjamin Cabé
7389cbbd3e sys: util: hide internal gcd/lcm helpers
These should not show up as API in doxygen

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-12-12 04:58:14 -05:00
Jeppe Odgaard
d32e7de509 debug: coredump: add cpp header guards
Add header guards to support usage from C++.

Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
2025-12-12 04:55:58 -05:00
Chaitanya Tata
f24b902f5e net: l2: ethernet: Add new stats API
Add a new API that takes stat type, the networking stack only needs
NATIVE stats per-packet, it doesn't need to update vendor stats
per-packet. This saves unncessary exchanges in case driver needs to
query the firmware for the vendor stats.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2025-12-11 16:33:54 -05:00
Alberto Escolar Piedras
f81011ee6a net: ip: Rename namespaced type in comment
In d45cd6716b the mayority of the
Zephyr codebased was changed to use the Zephyr native net_ prefixed
types. This comment was fogotten.
Let's fix it.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2025-12-11 17:06:04 +01:00
Sylvio Alves
d3d2bd2f02 driver: clock: espressif: get frequency default to calibrated value
When clock get_rate() is called, return by default the calibrated
frequency instead of nominal one. This improves accuracy specially
when internal RC SLOW clock is used.

To guarantee that nominal values can be still be retrieved, add a
new type of clock subsys for such scenario.

west.yml is also updated to add fix into calibration sources.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2025-12-11 17:02:14 +01:00
Jilay Pandya
83956260f7 drivers: stepper: split stepper api
- split stepper api into stepper and stepper_drv api
- stepper api now comprises only of motion control apis
- stepper_drv api comprises of apis for configuring stepper
  drivers

- add documentation about stepper and stepper_drv api
- move stepper.rst in a dedicated stepper folder
- add information about stepper_drv api and relevant functions
  in stepper documentation.

- drop motion control functions from all the stepper_drv drivers
- create a common a library for controlling stepper motors by
  toggling gpios via h-bridge or step-dir stepper_drivers

- tmc5xxx devices are a combination of motion controller and
  stepper driver devices. tmc5xxx devices need to be modelled as
  mfds in order to address the split in stepper driver subsystem

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
2025-12-11 05:51:17 -05:00
Firas Sammoura
89ae7bb8e8 arch: riscv: pmp: Remove header guards and add kconfig deps
Remove the CONFIG_RISCV_PMP #ifdef guards from the function
declarations in pmp.h. This allows the header to be included
unconditionally, while the function definitions remain conditional
on the Kconfig option.

Add @kconfig_dep to the Doxygen comments for all functions
to clearly indicate the dependency on CONFIG_RISCV_PMP.

Signed-off-by: Firas Sammoura <fsammoura@google.com>
2025-12-11 09:18:28 +02:00
Deepika aerlync
c40d66d046 drivers: clock_control: add Infineon PSOC4 support
Add clock control driver support for Infineon PSoC4:
- Fixed clock driver (clock_control_ifx_fixed_clock.c)
- Fixed factor clock driver (clock_control_ifx_fixed_factor_clock.c)
- Peripheral clock driver (clock_control_ifx_peri_clock.c)
- CAT1 clock control header

Provides clock initialization and management based on
devicetree configuration.

Signed-off-by: Dharun krithik k <dharunkrithik@aerlync.com>
Signed-off-by: Sayooj K Karun <sayooj@aerlync.com>
Signed-off-by: Manojkumar Konisetty <manoj@aerlync.com>
Signed-off-by: Deepika aerlync <deepika@aerlync.com>
2025-12-10 15:46:35 +00:00
Dmitrii Sharshakov
0e04d8a802 settings: tfm_psa: add support for PS backend
Protected Storage is another type of secure (encrypted and
authenticated) storage available using PSA interfaces.

When targeting TF-M builds, allow making use of PS for storing settings

Fixes #94681

Signed-off-by: Dmitrii Sharshakov <d3dx12.xx@gmail.com>
2025-12-10 10:33:34 +00:00
Dmitrii Sharshakov
06eb1473d5 settings: tfm_psa: rename from its
Prepare for extending this backend to also allow storing settings in the
PS (Protected Storage).

Mostly file and kconfig renames, as well as updates
to comments and log messages.

Signed-off-by: Dmitrii Sharshakov <d3dx12.xx@gmail.com>
2025-12-10 10:33:34 +00:00
Peter Mitsis
653731d2e1 kernel: Adjust metairq preemption tracking bounds
Adjust the bounds for tracking metairq preemption to include the
case where the number of metairq threads matches the number of
cooperative threads. This is needed as a thread that is schedule
locked through k_sched_lock() is documented to be treated as a
cooperative thread. This implies that if such a thread is preempted
by a metairq thread that execution control must return to that
thread after the metairq thread finishes its work.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2025-12-10 10:32:50 +00:00
Kai Vehmanen
fa2c904266 drivers: dai: add get_properties_copy() method
Add a variant of get_properties() method that writes the properties
to a caller provided pointer. Unlike the old variant, this copy
variant can be exported to user-space in a safe way.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2025-12-10 10:32:14 +00:00
Kai Vehmanen
81e37ad4e8 drivers: dai: add ability to use dai.h from user threads
Add user-space support to the dai.h interface. No functional
impact to builds when CONFIG_USERSPACE is not set.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2025-12-10 10:32:14 +00:00
Vijay Sharma
432d9d2a6b tracing: trace timer calls
Add tracing support for timer expiry and stop function callbacks,
enabling measurement of callback execution duration and facilitating
debugging of cases where callbacks take longer than expected.

Signed-off-by: Vijay Sharma <vijshar@qti.qualcomm.com>
2025-12-09 22:40:13 -05:00
Yongxu Wang
cc069c0201 drivers: firmware: scmi: Introduce basic system power protocol
Add SCMI System Power Domain Protocol support with:

- System power state set operations
- Standard SCMI power states (shutdown, cold/warm reset, suspend)
- Graceful and forceful power transitions
- Optional NXP vendor-specific power states
- Device tree binding for "arm,scmi-system"

This enables system-wide power management through standardized
SCMI interfaces for reboot and power control operations.

Signed-off-by: Yongxu Wang <yongxu.wang@nxp.com>
2025-12-09 22:39:35 -05:00
Yongxu Wang
9d163c73fb drivers: firmware: scmi: add protocol version support
Add version field to struct scmi_protocol and update protocol macros
to accept version parameter.

Protocol versions added:
  - Clock Control: v3.0.0 (SCMI v3.2 DEN0056E)
  - Pin Control: v1.0.0 (SCMI v3.2 DEN0056E)
  - Power Domain: v3.0.1 (SCMI v3.2 DEN0056E)
  - NXP CPU: v1.0.0 (vendor extension)

Updated macros:
  - DT_SCMI_PROTOCOL_DATA_DEFINE
  - DT_SCMI_PROTOCOL_DEFINE
  - DT_SCMI_PROTOCOL_DEFINE_NODEV
  - DT_INST_SCMI_PROTOCOL_DEFINE

Signed-off-by: Yongxu Wang <yongxu.wang@nxp.com>
2025-12-09 22:39:35 -05:00
Yongxu Wang
d0e9d950fb drivers: firmware: scmi: add common protocol interface functions
Add standardized SCMI protocol common interface functions that can be
reused across different SCMI protocol implementations:

- scmi_protocol_get_version(): Query protocol version
- scmi_protocol_attributes_get(): Get protocol-specific attributes
- scmi_protocol_message_attributes_get(): Query message capabilities
- scmi_protocol_version_negotiate(): Negotiate protocol version support

Signed-off-by: Yongxu Wang <yongxu.wang@nxp.com>
2025-12-09 22:39:35 -05:00
Zhaoxiang Jin
bc93570584 drivers: clock_control_mcux_syscon: add HSCMP clock support
add HSCMP clock support.

Signed-off-by: Zhaoxiang Jin <Zhaoxiang.Jin_1@nxp.com>
2025-12-09 22:37:32 -05:00
Mathieu Choplain
63081242b9 linker: remove STM32 CCM sections
Remove section names and symbols relating to the STM32 CCM region,
`/chosen/zephyr,ccm`, which is replaced by the standard DTCM region
`/chosen/zephyr,dtcm`.

For backwards compatibility, the old `__ccm_<...>_section` attribute
macros are aliased to `__dtcm_<...>_section` (until release 4.5).

Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
2025-12-09 14:54:36 -05:00
Henrik Brix Andersen
8b52241c06 drivers: can: sja1000: use proper namespace for Kconfig symbols
Use proper namespace for the CAN sja1000 Kconfig symbols, renaming
CONFIG_CAN_MAX_FILTER to CONFIG_CAN_SJA1000_MAX_FILTERS.

This prevents Kconfig symbol clashes between different CAN controller
drivers.

Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
2025-12-09 14:54:02 -05:00
Julien Vermillard
eef720ff3f net: lwm2m: add send scheduler helper objects
Introduce the optional OMA 10523/10524 send scheduler extension to manage
cached resources, including control and sampling rule objects, cache
filter with gt/lt/st and pmin/pmax handling, max-age/max-sample limits,
and registration flush helper.
Add an overlay to the LWM2M client sample.
Add a fake humidity sensor.

Signed-off-by: Julien Vermillard <julien@clunkymachines.com>
2025-12-09 09:52:11 -05:00
Tomasz Chyrowicz
88495301d3 flash_map: Add a macro to fetch controller ID
Add a macro that allows to get the node identifier of the flash
controller the area/partition resides on.

Signed-off-by: Tomasz Chyrowicz <tomasz.chyrowicz@nordicsemi.no>
2025-12-09 09:51:07 -05:00
Peter Wang
a249d79afe boards: frdm_mcxa577: add frdm_mcxa577 board
1. add soc mcxa577
2. add board frdm_mcxa577

Signed-off-by: Peter Wang <chaoyi.wang@nxp.com>
2025-12-09 11:12:03 +01:00
Daniel Leung
3e33978078 cache: deprecate CONFIG_DOUBLEMAP
Use CONFIG_CACHE_HAS_MIRRORED_MEMORY_REGIONS instead.
The new kconfig reflects more correctly on what is going on
in hardware. Also, this is not enabled by default if CPU
cache is not coherent. CPU cache can be incoherent and yet
there are no mirrored memory regions. Those relying on this
deprecated default behavior has their config adding
CONFIG_CACHE_HAS_MIRRORED_MEMORY_REGIONS separately.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-12-09 09:25:33 +01:00
Daniel Leung
0540d274c0 xtensa: remove CONFIG_XTENSA_RPO_CACHE
This removes the following kconfigs:

() CONFIG_XTENSA_RPO_CACHE
() CONFIG_XTENSA_CACHED_REGION
() CONFIG_XTENSA_UNCACHED_REGION

The associated feature is actually SoC specific and not general
architecture feature. Since the only user of these have its own
implementation, we can now safely remove these.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-12-09 09:25:33 +01:00
Daniel Leung
5fefc8b8b8 xtensa: cache: guard kconfig CONFIG_XTENSA_{UN,}CACHED_REGION
Make sure code using these kconfigs are only compiled if they
are defined. They will be removed later. But for now, we need
these #ifdef to avoid breaking the build when we move these
caching functions to SoC layer.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-12-09 09:25:33 +01:00
Daniel Leung
a8c1df6b80 cache: adds CONFIG_SOC_CACHE
This allows SoC to define their custom cache related functions
and are used by sys_cache_*() functions.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-12-09 09:25:33 +01:00
Daniel Leung
169304813a cache: move arch_mem_coherent() into cache subsys
arch_mem_coherent() is cache related so it is better to move it
under cache subsys. It is renamed to sys_cache_is_mem_coherent()
to reflect this change.

The only user of arch_mem_coherent() is Xtensa. However, it is
not an architecture feature. That's why it is moved to the cache
subsys.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-12-09 09:25:33 +01:00
Daniel Leung
a0a529aecc soc: intel_adsp: move ARCH_XTENSA_SET_RPO_TLB inside
The macro ARCH_XTENSA_SET_RPO_TLB is only used for Intel Audio
DSP. The specific memory mapping requiring this is SoC specific
feature and not a feature on Xtensa in general. It should not be
declared in the architecture layer. So move it.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2025-12-09 09:25:33 +01:00
Laurentiu Mihalcea
e8d8979386 firmware: scmi: nxp: add "nxp" to the CPU protocol definitions
The SCMI CPU protocol is in fact a vendor extension from NXP. The current
naming used for the CPU protocol definitions (i.e. functions, structures,
macros) follows that of the SCMI standard protocols, which might be
misleading.

Include "nxp" in the name of all of the CPU protocol definitions.

This change was performed mechanically using "git grep" and "sed -i"
with some manual intervention.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2025-12-08 22:27:38 -05:00
Dennis Grijalva
61938e7460 mgmt: mcumgr: make mcumgr handler variable const
Ensure mcumgr handler variables are consts in order to make ld happy and
not emit the "LOAD segment with RWX permissions" warning

Signed-off-by: Dennis Grijalva <dennisgrijalva@meta.com>
2025-12-08 22:27:04 -05:00
Dmitrii Sharshakov
8f4f1fa5fa ipc: icmsg: fix unbound for POSIX
Make sure unbound works on nrf5340bsim.

Signed-off-by: Dmitrii Sharshakov <d3dx12.xx@gmail.com>
2025-12-08 15:02:29 -05:00
Phi Bang Nguyen
646f255373 sys: util: Add gcd and lcm utilities
Add helpers to compute Greates Common Divisor (GCD) and Least Common
Multiple (LCM).

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Signed-off-by: Trung Hieu Le <trunghieu.le@nxp.com>
2025-12-08 15:01:46 -05:00
Phi Bang Nguyen
1f31da3398 sys: util: Add SIGN macro
Add a macro to determine the sign of a value.

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Signed-off-by: Trung Hieu Le <trunghieu.le@nxp.com>
2025-12-08 15:01:46 -05:00
Firas Sammoura
7dc9e87f6c riscv: pmp: Add API to change region permissions at runtime
The new function 'z_riscv_pmp_change_permissions' provides a mechanism
to modify the Read, Write, and Execute (R/W/X) permissions of an
existing PMP region based on its memory attribute index.

Signed-off-by: Firas Sammoura <fsammoura@google.com>
2025-12-08 15:01:37 -05:00
Dennis Grijalva
9dbe4bed29 kernel: make static thread data variable const
Ensure static thread data variables are consts in order to make ld happy
and not emit the "LOAD segment with RWX permissions" warning

Signed-off-by: Dennis Grijalva <dennisgrijalva@meta.com>
2025-12-08 15:01:01 -05:00
Pieter De Gendt
73ab6b6ffb include: zephyr: drivers: adc: Replace FOREACH with CHILD_BY_UNIT_ADDR_INT
The macro to initialise a struct adc_dt_spec instance uses a FOREACH macro,
which can be problematic when nesting in other FOREACH macros, for example
in driver implementations.

Replace it with DT_CHILD_BY_UNIT_ADDR_INT.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-12-08 13:09:24 -05:00
Pieter De Gendt
91278bdddf devicetree: Add DT_CHILD_BY_UNIT_ADDR_INT
Allow fetching child node identifiers by integer unit address.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-12-08 13:09:24 -05:00
Ayush Singh
4f98eede4b mcumgr: client: Allow specifying server address
- Currently, it is not possible to use mcumgr client with smp server
  since there is no way to specify smp server address for requests.
- This patch series adds support for creating smp_client_object
  containing information regarding the host server. This design allows
  multiple smp_client_object to exist for the same underlying smp_udp
  transport, making it much easier to use the same udp socket for multiple
  OTAs.

Signed-off-by: Ayush Singh <ayush@beagleboard.org>
2025-12-08 11:41:30 -05:00
Pieter De Gendt
3695b2c0ca shell: Add user data argument to shell_set_bypass
Allow passing some context to the shell bypass callback function by
providing a void pointer user data argument.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-12-08 09:39:05 -05:00
Mark Wang
3b23c76a24 bluetooth: a2dp: Fix function name in documentation comments
Update documentation comments to reference the correct function name
'bt_a2dp_register_ep' instead of the outdated
'bt_a2dp_register_endpoint' in SBC endpoint macro descriptions.

Signed-off-by: Mark Wang <yichang.wang@nxp.com>
2025-12-08 06:15:20 -05:00
Mario Paja
6795a795c8 dt-bindings: dma: stm32 introduce 32bit transfer macro
This change introduces 32bit DMA tranfer macro

Signed-off-by: Mario Paja <mariopaja@hotmail.com>
2025-12-07 21:20:06 -05:00
Scott Worley
cd6d7c9515 drivers: gpio: microchip: mec: One common driver for all MEC parts
Microchip MEC parts have a similar GPIO peripheral block. We
create a unified driver for all parts. NOTE: MEC GPIO interrupt
detection sets active status when changed from interrupt detect
disabled to any enabled mode. Driver ISR and interrupt configuration
implementation includes work-arounds for this issue.

Signed-off-by: Scott Worley <scott.worley@microchip.com>
2025-12-06 11:38:34 -05:00
Simon Maurer
ca71da8a85 arch: arm, arm64: linker: place .ARM.{extab, exidx} sections in rodata
The .ARM.extab and .ARM.exidx sections are now mapped under the
zephyr_rodata MMU region, ensuring they remain accessible at runtime.
These sections contain unwind information required for C++ exception
handling, so they must reside in readable memory.

Fixes #96070

Signed-off-by: Simon Maurer <mail@maurer.systems>
2025-12-06 11:38:18 -05:00
Hake Huang
00e5a399cc drivers: clock_control: kinetis scg support
add driver and dts-binding for kinetis_scg driver
used on ke1xz

Signed-off-by: Hake Huang <hake.huang@nxp.com>
Signed-off-by: Michael Galda <michael.galda@nxp.com>
2025-12-06 07:12:52 -05:00
Pieter De Gendt
35c8301278 include: zephyr: Replace nested COND_CODE_1 with COND_CASE_1
Update some header files with nested COND_CODE_1 macros to use a single
COND_CASE_1 macro instead.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2025-12-05 14:53:57 -05:00