Commit graph

73347 commits

Author SHA1 Message Date
Robert Lubos
812a1bc152 net: zperf: Define a public upload API for the library
This commit defines a public API for zperf upload functionality. The
UDP/TCP uploader modules are decoupled from shell, allowing to perform
uploads directly from the application code. The shell submodule makes
use of this new public API.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2022-12-22 11:05:11 +01:00
Daniel DeGrasse
71e95ae29d samples: drivers: adc: fixup ADC sample support for LPADC
Fixup ADC sample support for boards with LPADC present. This ADC only
supports an external reference voltage, which is a board-specific value.
Add reference voltage values for all supported boards.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-12-22 11:04:42 +01:00
Jamie McCrae
17e7ca70a9 samples: boards: nrf: mesh: onoff: Remove MCUmgr files
This application does not actually seem to use MCUmgr
functionality, therefore remove it.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2022-12-22 11:03:04 +01:00
Jamie McCrae
843f14167b doc: release: 3.3: Add note on MCUmgr handler update
Adds a note on MCUmgr Bluetooth and UDP transports now being
automatically registered without needing an application to
manually register them.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2022-12-22 11:03:04 +01:00
Jamie McCrae
b4b6346cdc mgmt: mcumgr: Make Bluetooth and UDP transport init automatic
This moves the UDP and Bluetooth initialisation for MCUmgr to be
performed automatically with the new hander registration feature.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2022-12-22 11:03:04 +01:00
Jamie McCrae
541fcb884d mgmt: mcumgr: Make handler registration functions static
Makes group registration functions for MCUmgr handlers static as
they are registered automatically at startup.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2022-12-22 11:03:04 +01:00
Jamie McCrae
fd81987da8 doc: release: 3.3: Add note on MCUmgr handler update
Adds a note on MCUmgr handlers now being automatically called
without needing an application to manually register them.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2022-12-22 11:03:04 +01:00
Jamie McCrae
d7557102c0 mgmt: mcumgr: Add iterable section to register MCUmgr handlers
This replaces the requirement for applications to manually
register MCUmgr handlers by having an iterable section which
then automatically registers the handlers at boot time.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2022-12-22 11:03:04 +01:00
Lukasz Mazur
f7ab9a8c52 pinctrl_stm32: GPIO output info in Z_PINCTRL_STM32_PINCFG_INIT
Added information about pin output direction into
Z_PINCTRL_STM32_PINCFG_INIT if output_low or output_high is provided.
GPIO output flag is set in configuration struct and this will end up
being loaded into MODE register. Because of that it is no longer
required for pinctrl_configure_pins() to set MODE register value for
GPIO input/output.
Fixes #53141.

Signed-off-by: Lukasz Mazur <lukasz.mazur@hidglobal.com>
2022-12-22 11:00:45 +01:00
Sylvio Alves
8a52f9a835 hal_espressif: remove base64 redefinition
WPA supplicant includes custom base64.c file with no need.

Fixes #53129

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2022-12-22 10:59:48 +01:00
Emil Gydesen
4e3205d238 Bluetooth: Audio: Add packing to unicast group create
Add the ISO packing field when creating a unicast group.

This refactors the structure of the unicast group create,
as it now takes both the packing as a group parameter, as well
as an array of stream-specific parameters.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2022-12-22 10:59:16 +01:00
Emil Gydesen
ba1949759d Bluetooth: Audio: Add packing field to broadcast source
Add support for setting the ISO packing field when
creating a broadcast source.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2022-12-22 10:59:16 +01:00
Erwan Gouriou
46378b7ff2 drivers: clock_control: stm32: Use zephyr functions for bit operations
Use builtin functions for bit operations to increase readability.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2022-12-22 10:58:27 +01:00
Guillaume Gautier
3d4232290f Kconfig.zephyr: Update UF2 ID for STM32F4 series
Update UF2 family ID for the entire STM32F4 series, except STM32F407xx
which have their own dedicated IDs.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2022-12-22 10:57:49 +01:00
Marc Herbert
3ec1bb2776 cmake: log ${CMAKE_VERSION}
Different CMake versions can have very subtle differences, for
instance CMake 3.21 links object files in a different order compared
to CMake 3.20; this produces different binaries.

CMAKE_VERSION is required information to track binary differences
between two build systems.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-12-22 10:55:28 +01:00
Carles Cufi
c22df526e0 manifest: hal_nxp: Replace PR with SHA
The previous PR had been merged mistakenly, and it contained a reference
to a PR. Point to a SHA instead now that
https://github.com/zephyrproject-rtos/hal_nxp/pull/213 has been merged.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2022-12-21 21:34:07 +01:00
Sebastian Bøe
02b83892d2 mcuboot: doc: Define MCUBOOT_EXTRA_IMGTOOL_ARGS more clearly
imgtool could be used for many things, but
CONFIG_MCUBOOT_EXTRA_IMGTOOL_ARGS, despite it's generic name, is only
applied when signing. Make it even more clear in the prompt and help
text that it's limited to signing.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2022-12-21 16:39:19 +01:00
Declan Snyder
f2e0ac5c58 drivers: uart_mcux_flexcomm: Add runtime configure
Add uart_configure and uart_config_get functionality to
MCUX flexcomm driver to be able to dynamically configure
flexcomm uart at runtime.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2022-12-21 09:38:33 -06:00
TOKITA Hiroshi
7317490703 boards: riscv: Add support for SparkFun RED-V Things Plus
Add support for SparkFun RED-V Things Plus board that is
a development board with a SiFive FE310-G002 RISC-V SoC.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
2022-12-21 16:27:55 +01:00
Jay Vasanth
6e25082db0 boards: arm: mec172xevb: add cpu-power-states property
Add cpu-power-states property in cpu0 node to describe the
two supported power states idle and suspend_to_ram

Signed-off-by: Jay Vasanth <jay.vasanth@microchip.com>
2022-12-21 16:24:51 +01:00
Ming Shao
632972459a cmake: fix a typo in zephyr_linker_arg_val_list() macro
The CMake list delimiter is ";" rather than ":".

Signed-off-by: Ming Shao <smrtos@163.com>
2022-12-21 16:24:37 +01:00
Declan Snyder
56f1b46268 include: fs: Remove conditional around MKFS
The MKFS function declaration is conditionally compiled
based on the MKFS kconfig, which prevents it from being documented.
Remove the conditional.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2022-12-21 16:23:08 +01:00
TOKITA Hiroshi
3273bea0a5 boards: riscv: hifive1: add openocd configuration
Add configurations flashing and debugging for openocd.
The change makes `west debug` and `west flash` use the setting defaultly.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
2022-12-21 16:21:44 +01:00
Emil Gydesen
2935cac9d6 Bluetooth: Audio: Fix handling properly deleting endpoints
When there is an ACL disconnect, or the unicast group is otherwise
deleted, the endpoints were not properly handled, causing
incorrect `dir` values and ASSERTs.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2022-12-21 16:19:35 +01:00
Emil Gydesen
21fd387cab Bluetooth: Audio: Fix unicast group add/free handling of endpoints
When adding or removing a stream from the group, the
endpoint may or may not have been allocated depending
on the state of the endpoint.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2022-12-21 16:19:35 +01:00
Emil Gydesen
f1bedd01c1 Bluetooth: ISO: Remove wrong requirement for cc_len
The hci_le_setup_iso_data_path function required that if
the path->cc was set, the length could not be 0.

There is no reason why it should not be allowed to be 0
in that case.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2022-12-21 16:19:35 +01:00
Emil Gydesen
a7e7d87912 Bluetooth: Audio: Fix issue with creating the CIG as unicast client
The unicast client could not create a CIG with a unidirectional
CIS, because it would not set the correct values as per the
HCI spec for the unused CIS direction.

Instead of implementating a work around, this commit modifies
it so that for unidirectional CIS, we copy the QoS values
to the unused direction, so that we always set valid values,
but it also allows us to actually use that CIS direction later,
assuming that the QoS settings does not change.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2022-12-21 16:19:35 +01:00
Emil Gydesen
f239df0ca7 Bluetooth: Audio: Fix audio_iso handling for unicast client
For the unicast client, the direction for the endpoint
is reversed in terms of RX/TX, i.e. a sink endpoint is
RX for the unicast server and broadcast sink, but TX
for the unicast client, and similar for the source endpoint.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2022-12-21 16:19:35 +01:00
Pawel Czarnecki
d45cd9afea drivers: eth: gecko: fix GPIO configuration
This fixes errors in samples/net/sockets/big_http_download for SiLabs
platforms.

Signed-off-by: Pawel Czarnecki <pczarnecki@antmicro.com>
2022-12-21 23:32:57 +09:00
Declan Snyder
0afa2608db tests: fat_fs_api: MKFS still causing build errors
The MKFS portion of the test is still was being included
in the build when it shouldn't because of a file glob

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2022-12-21 13:37:03 +01:00
Trent Piepho
2112844eea logging: backend_uart: Reword buffer size Kconfig text
As written, the title and description of the Kconfig option seem to
specify the logging sub-system will not flush until the buffer is full.
Someone reading this would expect that shorter log message will not be
flushed until the specified number of bytes accumulate.

This is not the case.  Each log message is flushed when finished.  The
size is only the maximum bytes of a single formatted message's contents
that will be accumated before the backend flushes.

What's more, it only applies in deferred mode.  In immediate mode there
is no buffering, not just of multiple log messages but also of the
message contents as they are formatted.

Signed-off-by: Trent Piepho <tpiepho@gmail.com>
2022-12-21 12:23:23 +01:00
Zachary J. Fields
ec0662734d boards: Swan DeviceTree Inheritence
The Swan was originally cloned from the Nucleo-L4R5ZI.

The Nucleo is a sister board, but not identical
and some artifacts of cloning are incorrect.

Signed-off-by: Zachary J. Fields <zachary_fields@yahoo.com>
2022-12-21 12:21:22 +01:00
Arkadiusz Balys
3afd564bba modules: openthread: platform: Added setting default tx power
There were some requests from users for adding the possibility
of setting default openthread tx output power using kConfig.
It is possible by adding the CONFIG_OPENTHREAD_DEFAULT_TX_POWER
kConfig and assigning it to the tx_power variable in the radio.c
file in the Openthread module.

Added the possibility to set default openthread power using
kConfig.

Signed-off-by: Arkadiusz Balys <arkadiusz.balys@nordicsemi.no>
2022-12-21 12:21:09 +01:00
Ryan McClelland
34cfba73b4 usb: device: hid: correct bcdHID to v1.11 spec
bcdHID is intended for the spec version of USB HID. It was pointing to the
v1.1 bcdUSB define which happens to be the same value for the v1.10 hid
spec version. This corrects it to use the v1.11 HID spec.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2022-12-21 12:20:55 +01:00
Sam Hurst
3369137b34 drivers: usb_c: Properly detect a disconnect while operating as a Source
While operating as a Source, a disconnect can be missed
if using an E-Marker cable that presents an Ra. This change
detects a disconnect as follows, while operating as a Source:

CC1     CC2
-----------
OPEN    OPEN ----> Nothing attached
OPEN    Ra   ----> Powered cable without Sink attached
Ra      OPEN ----> Powered cable without Sink attached

Signed-off-by: Sam Hurst <sbh1187@gmail.com>
2022-12-21 12:19:43 +01:00
TOKITA Hiroshi
bafbc75270 drivers: gpio: sifive: Reset iof_en and iof_sel on init
If the bootloader changes iof_en/iof_sel settings before zephyr launching,
GPIO does not behave correctly.
These values should be 0 initially, Initialize to 0 at GPIO initialize.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
2022-12-21 12:19:27 +01:00
Mulin Chao
271b306b2d driver: uart: npcx: add missing tx/rx interrupt enabled checks
When checking if any UART TX/RX IRQs are pending, the driver should also
consider whether these IRQs are enabled. Or we still get pending status
set even if the related interrupts are disabled.

Signed-off-by: Mulin Chao <mlchao@nuvoton.com>
2022-12-21 12:19:13 +01:00
Fabio Baltieri
7a9b019f46 doc: contribute: add a note about the GitHub "Update branch" feature
Add a note about the "branch out of date" and "Update branch" GitHub
feature. That message is confusing for new users and we often see people
losing approvals and introducing merge commits with it. Adding a note
in the contribution guidelines would hopefully help some.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2022-12-21 12:18:22 +01:00
Fabio Baltieri
f781788ece doc: contribute: drop the point about subsystem branches
There hasn't been any topic branch in widespread use. This point is
still relevant for backports or some advanced usage, but since this list
is meant to help contributor approaching the project it may be a good
idea to drop the point and make the list a tiny bit shorter and less
intimidating.

Instead, mention that main should be used "if unsure" in the previous
point.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2022-12-21 12:18:22 +01:00
Guillaume Gautier
2f4c790a51 drivers: i2c: Use dts to determine i2c clock source for STM32
Add the possibility to use the clock parameter in dts to set the clock
source of I2C devices for all STM32 MCUs.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2022-12-21 12:17:38 +01:00
Guillaume Gautier
951b0a6e17 dts: arm: st: Add default I2C clock source for STM32F0 & F3
Define SYSCLK as the default I2C source clock for I2C1 on STM32F0x
and all I2Cx on STM32F3x.

On most series, the default I2C clock source (when it exists) is PCLK.
This clock does not exist as I2C clock source on FO & F3 and the default
one is HSI. Since HSI is not necessarily enabled we explicitly set it
to SYSCLK instead.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2022-12-21 12:17:38 +01:00
Guillaume Gautier
8f4b89df3c dts: arm: st: f7: Use new dedicated clock file for STM32F7
Include the new clock file dedicated for STM32F7 instead of the F4 one
previously used.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2022-12-21 12:17:38 +01:00
Guillaume Gautier
aca570ecb3 include: zephyr: dt-bindings: clock: Add separate clock file for STM32F7
Add a new dedicated clock control header file for the STM32F7 series.
It is copied from the STM32F4 file with added clock defines and helpers
to select peripheral clock sources that are specific to F7 series.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>

dt-bindings f7
2022-12-21 12:17:38 +01:00
Andrzej Głąbek
c984a343af drivers: uart_nrfx_uarte: Prevent re-enabling RX until UART_RX_DISABLED
Fix the driver so that after a call to uart_rx_disable() it does not
allow re-enabling RX until the UART_RX_DISABLED is generated (what
means that the disabling procedure is complete). Otherwise, it is
possible that the RXTO event from the previous RX is handled right
after a new RX is started, and the RX buffer pointer gets corrupted
in the `rx_flush()` function.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2022-12-21 11:47:34 +01:00
Tomasz Leman
73feb35e99 ace: dts: gpdma: add third controller
Meteorlake has three GPDMA controllers.

Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
2022-12-21 10:11:41 +01:00
Piotr Kosycarz
b8815ddc36 tests: kernel: timer: starve: Adjust timeout value
The test in its default configuration needs 3600 seconds to complete,
adjust timeout for twister to meet that.

Signed-off-by: Piotr Kosycarz <piotr.kosycarz@nordicsemi.no>
2022-12-21 10:11:23 +01:00
Jamie McCrae
0f7114fd6a boards: arm: thingy53: Enable USB-CDC for console
This enables the USB-CDC port for console output by default when
configuring for the thingy53_nrf5340_cpuapp board. This is needed
as the UART on this board is not connected.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2022-12-21 10:10:41 +01:00
Jun Lin
885695f425 drivers: crypto: SHA: npcx: add support for SHA hardware accelerator
NPCX9 series chips include a SHA hardware accelerator, which supports
SHA256/SHA384/SHA512 hashing and a library (APIs) in the on-chip ROM.
This commit adds the driver support by wrapping the on-chip ROM APIs.

Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
2022-12-21 10:10:10 +01:00
Jun Lin
bd766d0489 dts: SHA: npcx: add the SHA DTS node and binding
- Add SHA DTS node to npcx9.dtsi.
- Add yaml binding for npcx SHA.

Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
2022-12-21 10:10:10 +01:00
Gerard Marull-Paretas
b67c78bfbe tests: drivers: regulator: refactor fixed regulator test
Refactor the test following latest changes on the regulator API. The
test has now a single case that tests all the features of the driver at
once.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2022-12-21 10:09:55 +01:00