Commit graph

15409 commits

Author SHA1 Message Date
Etienne Carriere
af6d97dcf4 include: zephyr: dt-bindings: clock: fix missing STM32 header files
Add inclusion of stm32f4_clock.h header file that is missing
in stm32f410 and stm32f427 DT bindings clock header files.

Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
2025-02-14 13:40:52 +01:00
Tom Hughes
cc50765f8e toolchain: Add macros to disable compiler warnings
These macros allow disabling compiler warnings for all compilers or only
gcc or only clang.

Signed-off-by: Tom Hughes <tomhughes@chromium.org>
2025-02-14 13:40:42 +01:00
Dominik Kilian
84a215aff8 ipc_service: icmsg: Add "unbound" functionality
In some cases, CPUs that may need to reset or
temporary stop communication. This commit adds "unbound"
functionality that provides a callback to IPC service user
when connection was interrupted for some reason, e.g.
expected or unexpected CPU reset, closing the
endpoint. The "unbound" callback is optional to implement
by endpoints. This commit implements it in the ICMsg
backend.

Signed-off-by: Dominik Kilian <Dominik.Kilian@nordicsemi.no>
2025-02-14 13:34:49 +01:00
Wilfried Chauveau
c0139fad06 drivers: gpio: mmio32: update gpio_mmio32 to behave like other divers
The current implementation requires SoCs/Boards to manualy instantiate
the preripherals and initilize them.

The change lets Zephyr rely on the device tree setup to instantiate &
initialize the relevant gpio peripheral.

Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
2025-02-14 10:42:02 +01:00
Titouan Christophe
baa41f43af boards: stm32h7s78-dk: add support for OTGFS (USB port 2)
Add OTGFS peripheral to the stm32h7rs soc series, and enable it on the
Discovery board STM32H7S78-DK, where it is wired to USB Type-C port 2.

Signed-off-by: Titouan Christophe <moiandme@gmail.com>
2025-02-14 10:41:43 +01:00
Dmytro Firsov
63ea48cacc include: xen: add gnttab_query_size struct to public headers
Xen public headers were imported into Zephyr source tree and only used
structs were added (not copied as is). Mow, for refactoring and
improving gnttab driver we need to augment grant table public header
with one more struct. It will be used for reading actual number of
available Xen grant frames.

Signed-off-by: Dmytro Firsov <dmytro_firsov@epam.com>
2025-02-14 10:41:33 +01:00
Dmytro Firsov
3f92a8bbdd drivers: xen: gnttab: use correct struct for grant frames unmapping
Previously the driver's 'gnttab_unmap_refs()' signature used incorrect
struct - the same one that is used for mapping. Since 'host_addr'
membber, that is used to point to required frame is first in both
structures it somehow worked.

Fix mistake and use 'struct gnttab_unmap_grant_ref' for grant frames
unmapping hypercalls.

Signed-off-by: Dmytro Firsov <dmytro_firsov@epam.com>
2025-02-14 10:41:33 +01:00
Lubos Koudelka
099970e130 dt-bindings: clock: Add MCO register definition for STM32WBA
Added MCO register definition to support MCO functionality in the STM32WBA
series. This update also includes the addition of MCO_PRE_DIV and MCO_SEL
defines.

Signed-off-by: Lubos Koudelka <lubos.koudelka@st.com>
2025-02-14 10:41:18 +01:00
Utsav Munendra
10c6b34800 portability: cmsis: Support static CMSIS-RTOSv2 control blocks
Do not use memory slabs for the control blocks when
the application provides the memory for it. This
implements manual user-defined allocation memory
management support in CMSIS-RTOSv2 API.

Signed-off-by: Utsav Munendra <utsavm@meta.com>
2025-02-14 03:13:35 +01:00
Utsav Munendra
11eb0ce4db portability: cmsis: Rename cmsis wrapper types
Namespace this types with `cmsis_rtos` instead of `cv2`

Signed-off-by: Utsav Munendra <utsavm@meta.com>
2025-02-14 03:13:35 +01:00
Utsav Munendra
13ef44200e portability: cmsis: Move cmsis wrapper types to public header
This enables the cmsis wrapper types to be declared
statically and then passed along to CMSIS-RTOSv2 APIs,
enabling static allocation of RTOS control blocks
in the subsequent commits.

Signed-off-by: Utsav Munendra <utsavm@meta.com>
2025-02-14 03:13:35 +01:00
Camille BAUD
637686695c sensor: Introduce Phosense XBR818 Driver
This Introduces a driver for the i2c interface of Phosense XBR818.
XBR818 is a 10.525Ghz Radar chip with builtin detection algorithm.

Signed-off-by: Camille BAUD <mail@massdriver.space>
2025-02-14 03:03:22 +01:00
Ryan McClelland
e9ea97e92d drivers: i3c: add synopsys designware i3c driver
Add synopsys designware i3c driver

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2025-02-14 03:02:43 +01:00
Steven Chang
7b3596faaa driver: gpio: ene_kb1200 gpio initial level
Change initial level from POST_KERNEL to PRE_LERNEL_1,
Config suport voltage and driving flags

Signed-off-by: Steven Chang <steven@ene.com.tw>
2025-02-14 00:44:57 +01:00
Tomi Fontanilles
0c368e85b1 secure_storage: add a global registry header file for PSA key IDs
We need to make sure that within Zephyr different users of the PSA APIs
don't interfere with each other because of using the same numerical IDs
for persistent assets.

This takes care of the PSA key IDs when using persistent keys through
the PSA Crypto API.
See the comments in `<zephyr/psa/key_ids.h>` for more information.

This removes the recently-introduced Kconfig options that allowed changing
the base IDs subsystems were using for their persistent keys.

Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
2025-02-13 20:22:09 +01:00
Luca Burelli
44c7a1401e llext: add ELF inspection APIs
Add APIs to inspect the contents of an ELF file loaded as an extension.
This is useful for applications that need to access the contents of the
extension in a more fine-grained way than the existing LLEXT APIs.

Use of these APIs requires the 'keep_elf_data' option to be provided via
struct llext_load_param to the 'llext_load()' call.

Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
2025-02-13 16:43:29 +01:00
Luca Burelli
325d6b7d7f llext: add option to keep section data after llext_load
This is required for the functions that inspect the ELF file to work
properly. The user must then call llext_free_inspection_data() before
calling llext_unload() to free the memory left allocated in the loader
and extension memory.

Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
2025-02-13 16:43:29 +01:00
Wilfried Chauveau
caafe23891 arch: arm: cortex_m: Apply clang-format on cortex_m related code
This commit updates cortex_m related code to align it with the rules from
.clang-format. This is done to simplify future changes in these files as
we are about to implement use_switch support.

Some rules conflict with checkpatch and therefore some small part of the
code locally disable clang-format.

Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
2025-02-13 16:42:48 +01:00
Jonny Gellhaar
4632cefc89 fs: api: Fix typo in API documentation
Typo in errno reference for mount flag.

Signed-off-by: Jonny Gellhaar <jonny.gellhaar@prevas.se>
2025-02-13 12:16:05 +01:00
Tien Nguyen
b9a4e30d3b drivers: clock control: Initial support for RZ/G3S
Add Clock Control driver support for Renesas RZ/G3S

Signed-off-by: Tien Nguyen <tien.nguyen.zg@renesas.com>
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
2025-02-13 09:11:19 +01:00
Michal Bukowski
83c360642d drivers: audio: intel: add support for microphone privacy
Implements driver for Intel microphone privacy feature.

Signed-off-by: Michal Bukowski <michal.bukowski@intel.com>
2025-02-13 01:13:31 +01:00
Florian Weber
093b29fdb5 lib: os: p4wq: add done handler
Add an optional handler to the p4wq to give the submitting code
(e.g. rtio workq) a possibility execute code after the work was
succesfully executed.

Signed-off-by: Florian Weber <Florian.Weber@live.de>
2025-02-12 16:03:17 +01:00
Jaro Van Landschoot
0085b34e02 drivers: gpio: gpio_stm32: add gpio speed
The driver already read the speed flags (cfr. ospeed) and called
LL_GPIO_SetPinSpeed, but these flags could not be set yet.

Signed-off-by: Jaro Van Landschoot <jaro.vanlandschoot@basalte.be>
2025-02-12 12:31:40 +01:00
Emil Gydesen
571f26cf1a Bluetooth: Rename BLE to Bluetooth (LE) where applicable
The BLE acronym is not an official description of Bluetooth
LE, and the Bluetooth SIG only ever refers to it as Bluetooth
Low Energy or Bluetooth LE, so Zephyr should as well.

This commit does not change any board or vendor specific
documentation, and the term BLE may still be used in those.
It will be up to the vendors to update it if they want,
since many of them are using the term BLE in their
products.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-02-12 12:24:18 +01:00
Tom Burdick
2a046004b9 rtio: Correctly handle completion count wraps
Prior to this change a wrap of the completion count (without SUBMIT_SEM)
would result in looping indefinitely waiting for completions.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2025-02-12 12:23:06 +01:00
Emil Gydesen
49d9b4cb69 Bluetooth: PACS: Remove BAP infix for pacs_register_param
Since the PACS service is not part of the bt_bap API it should
not use the bt_bap prefix, and instead just be bt_pacs like the
rest of the PACS API.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-02-12 09:41:49 +01:00
Jukka Rissanen
ae05221762 net: Update IP address refcount properly when address already exists
If an IP address already exists when it is tried to be added to the
network interface, then just return it but update ref count if it was
not updated. This could happen if the address was added and then removed,
but for example an active connection was still using it and keeping the
ref count > 0. In this case we must update the ref count so that the IP
address is not removed if the connection is closed.

Fixes #85380

Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
2025-02-12 09:41:24 +01:00
Jukka Rissanen
9e79184f7e net: mdns_responder: Implement probing support
The mDNS probing is described in RFC 6762 chapter 8.1.
The code will send an unsolicited mDNS query to network and
will check if there are existing hosts with the same name.
If there are, then the mDNS responder will not respond to
queries it is configured to use.

Fixes #84333

Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
2025-02-12 09:40:15 +01:00
Tom Hughes
a887fe1607 drivers: sensor: Fix unused function warning
Building with clang warns:

drivers/sensor/st/lis2dw12/lis2dw12.c:194:23: error: unused
function 'sensor_ms2_to_mg' [-Werror,-Wunused-function]
static inline int32_t sensor_ms2_to_mg(const struct sensor_value *ms2)
                      ^

Move the function to include/zephyr/drivers/sensor.h with the other
sensor_ms2_to* functions.

Signed-off-by: Tom Hughes <tomhughes@chromium.org>
2025-02-12 07:52:36 +01:00
Jérôme Pouiller
d413936fb1 drivers: pinctrl: Introduce support for SiWx91x
This device is included on Silabs SiWx91x series. The current driver is
able to manage "High Power" and "Ultra Low Power" pins.

Co-authored-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-02-11 22:07:11 +01:00
Jérôme Pouiller
ffb1c0de61 drivers: clock: Add dumb clock driver for SiWx91x
This driver is mostly the initial seed for further implementation of a
real clock driver.

It doesn't allow the user to choose the clock source for the various
peripherals. The driver hardcodes some sane values.

Note that for now, the driver snps,designware-i2c does not support
"clocks" attribute. So this patch hardcode the clock configuration in
the init of the clock driver.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
2025-02-11 22:07:11 +01:00
Emil Gydesen
b67d291207 Bluetooth: Host: Add type check for bt_conn API
Added a new function, bt_conn_is_type, that returns whether
the provided conn object is of the provided type.

This check is then used to ensure that the conn objects
supplied to other bt_conn function are of the right type.
The right type has also been documented for these functions.

This is an initial commit for a larger change in the BT Host,
as similar checks should be added to the L2CAP, GATT, ISO,
Audio and possibly Mesh APIs.

The type check could have been implemented by using the
bt_conn_get_info function, but that requires additional
function calls as well as memory allocation and copy.
Since bt_conn_is_type is designed to be widely used, it
was suited for its own function.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-02-11 22:04:51 +01:00
Ryan McClelland
653589c558 drivers: i3c: add controller handoff support
Add controller handoff

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2025-02-11 22:03:32 +01:00
Ryan McClelland
88f5e16edc drivers: i3c: add controller handoff helper
This adds controller handoff according to section 5.1.7.1 of the
I3C specification.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2025-02-11 22:03:32 +01:00
Ryan McClelland
5f8c302306 drivers: i3c: add controller handoff parameters in to i3c desc
Add the parameters crcaps and crhdly1 in to the i3c device descriptor.
Also, retrieve the values if they are available.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2025-02-11 22:03:32 +01:00
Ryan McClelland
982c02d910 drivers: i3c: add ccc getacccr
Add a ccc helper for getacccr

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2025-02-11 22:03:32 +01:00
Lucien Zhao
0f29766b08 drivers: clock: mcux_lpc_syscon_clock.c: add ctimer5/6/7 support
add ctimer5/6/7 clock get support

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-02-11 18:55:53 +01:00
Robert Lubos
d6792494b7 net: coap_client: Fix build with cpp projects
The coap_client.h header won't build if included from c++ file:

error: expected primary-expression before ‘.’ token
  .value[0] = coap_bytes_to_block_size(CONFIG_COAP_CLIENT_BLOCK_SIZE),

Therefore move the actual function implementation to the library C file
to prevent this.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2025-02-11 15:41:37 +01:00
Robert Lubos
4600a7f397 net: coap_client: Add missing cpp guard in the header
The coap_client.h header was missing c++ guard, fix this.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2025-02-11 15:41:37 +01:00
Qingling Wu
159332d591 net: wifi: hostap: add CA certificate used or skipped support
Added new parameter "A" in wifi connect command to support
CA certificate used or CA certificate skipped for
EAP-TTLS-MSCHAPV2 and EAP-PEAP-MSCHAPV2.

Signed-off-by: Qingling Wu <qingling.wu@nxp.com>
2025-02-11 15:38:58 +01:00
Kate Wang
19f1e0fb9b drivers: mipi_dsi: dsi_mcux_2l: Update driver to support ULPS
Add new item ulps_control in binding. If the MIPI DSI on the SoC support
ULPS, and user set the bus to enter ULPS after transfer in mipi_dsi_msg,
driver will set the bus to enter ULPS.

Signed-off-by: Kate Wang <yumeng.wang@nxp.com>
2025-02-11 15:38:47 +01:00
Khoa Nguyen
9c67002ef9 drivers: dac: Initial DAC driver support for Renesas RA
Initial DAC driver support for Renesas RA

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2025-02-11 11:44:40 +00:00
Tomasz Moń
23232e6bb2 drivers: udc: Do not allow lock/unlock to fail
USB stack does not check api->lock() and api->unlock() return value and
all UDC drivers block without timeout in its lock() and unlock() api
implementations. There is no realistic way to handle lock() and unlock()
errors without making USB device stack API unnecessarily complex.

Remove the return type from lock() and unlock() to make it clear that
the functions must not fail.

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2025-02-11 10:13:03 +01:00
Hoang Nguyen
ca75671c50 drivers: interrupt controller: Initial support for RZ/G3S
Add interrupt controller driver support for Renesas RZ/G3S

Signed-off-by: Hoang Nguyen <hoang.nguyen.jx@bp.renesas.com>
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
2025-02-11 10:11:15 +01:00
Phi Bang Nguyen
b341d9d6a4 video: Merge video_stream_start/stop driver APIs
The video_stream_start/stop() APIs are counter-symetric and have
the same function signature. Also, the implementation logic for
those driver APIs is generally the same. Merge them to save memory
and code lines.

For the sake of simplicity, still keep the user APIs to preserve
backward compatibility with downstream applications.

Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
2025-02-11 07:43:58 +01:00
Jonathon Penix
dad2d65cfa sw_isr_table: Force align _isr_list_sname instances
For some target and optimization level combinations (aarch64 and -O2, for
example), GCC will over align _isr_list_sname instances. The local isr
declaration parser doesn't expect the extra padding that may be introduced
and will produce unexpected errors about bad IRQs (`error: IRQ 1903323438
(offset=0) exceeds the maximum of 42`, for example). Prevent this issue by
forcing the expected alignment of _isr_list_sname.

Fixes #81254

Signed-off-by: Jonathon Penix <jpenix@quicinc.com>
2025-02-11 00:43:55 +01:00
Pavel Vasilyev
f82c0e85b0 bluetooth: mesh: access: cast to uint8_t to avoid potential overflow
Explicitly cast `BT_MESH_TRANSMIT` output to avoid potential overflow.

Fixes #84759
Fixes #84749
Fixes #84702
Coverity-CID: 487624
Coverity-CID: 487648
Coverity-CID: 487722

Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
2025-02-10 22:26:31 +01:00
Ryan McClelland
37e4af63a9 kernel: thread: fix warning of always false
K_KERNEL_STACK_RESERVED can be 0 which can give a warning with
-Wtype-limits. Only perform the check if ARCH_KERNEL_STACK_RESERVED
is set. Also remove the the unncessary sets in arch.h where it's
manually set to 0, it defaults to 0 anyways.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2025-02-10 22:25:32 +01:00
Jamie McCrae
0e8cc3e52d dfu: Add support for new MCUboot swap using offset mode
Allows using this newly introduced MCUboot algorithm

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2025-02-10 19:05:25 +01:00
Fengming Ye
54ef1b54d1 net: wifi: add SAE extended key security type support
Add WPA3 SAE extended key security type support in
L2 wifi mgmt and hostap.

Signed-off-by: Fengming Ye <frank.ye@nxp.com>
2025-02-10 14:32:38 +01:00