Commit graph

85510 commits

Author SHA1 Message Date
Tom Burdick edfddd6a11 docs: releases: RTIO Release Notes for 3.5
Adds release notes for the RTIO subsystem for 3.5 with notable bug
fixes, changes, and feature additions.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2023-10-17 13:17:01 +03:00
Tom Burdick b272760f06 docs: releases: Adds I2C release notes for 3.5
Adds a subset (there was a lot!) of notable fixes, features, and driver
additions for I2C

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2023-10-16 22:32:55 +03:00
Tom Burdick cb9230ee30 docs: releases: Add DMA release notes for 3.5
Adds notable bug fixes, driver additions, and feature additions to the
DMA API and drivers in 3.5.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2023-10-16 22:26:44 +03:00
Jeppe Odgaard 24085d05e6 boards: doc: Add programming tabs for mimx8mq_evk
Improve documentation by putting programming methods into tabs.

Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
2023-10-16 15:35:00 +01:00
Christopher Friedt 137097f5c3 logging: log_core: correct timeout of -1 ms to K_FOREVER
Many releases ago, specifying to block indefinitely in the log
processing thread would do just that.

However, a subtle bug was introduced  such that specifying -1
for `CONFIG_LOG_BLOCK_IN_THREAD_TIMEOUT_MS` would have the
exact opposite effect than what was intended.

As per Kconfig, a value of -1 should translate to a timeout of
`K_FOREVER`. However, conversion via `K_MSEC(-1)` results in
a `k_timeout_t` that is equal to `K_NO_WAIT` rather than the
intent which is `K_FOREVER`.

Add a dedicated check to to ensure that a value of -1 is
correctly interpreted as `K_FOREVER` in `log_core.c`.

For reference, the blocking feature was described in #15196,
added in #16194, and it would appear that the regression
happened in c5f2cdef09.

Signed-off-by: Christopher Friedt <cfriedt@meta.com>
2023-10-16 12:06:42 +02:00
Flavio Ceolin 90b9809c6f doc: security: cve-2023-4257 left embargo
Disclose information about cve-2023-4257.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2023-10-14 18:43:49 +03:00
Flavio Ceolin 52cf7e6fdf doc: vuln: Add information about CVE-2023-4263
Information about CVE-2023-4263

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2023-10-14 18:43:27 +03:00
Flavio Ceolin bcd3882f88 doc: release: 3.5: Add info about CVE-2023-4263
Add CVE-2023-4263 info to release notes.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2023-10-14 18:43:27 +03:00
Benjamin Cabé 8ec1a27920 doc: ring_buffer: fix typos and incoherences
Fixed an incorrect mention of buffer size being expressed in 32-byte
words for data item mode when it's in fact 32-bit.
Fixed a few broken references to C functions and structs.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2023-10-14 18:42:34 +03:00
Benjamin Cabé 14c1ff25b1 doc: ring_buffer: Properly expose Doxygen doc for ring_buf struct
Move the ring_buf struct in the Doxygen group containing all other APIs.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2023-10-14 18:42:34 +03:00
Johan Hedberg bbf46b96ce release: Zephyr 3.5.0-rc3
Bump the version to 3.5.0-rc3.

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2023-10-14 11:59:13 +03:00
Emilio Benavente b9613389fb tests: drivers: spi: spi_loopback: Added mimxrt1170_evk_cm7
Added overlay inside the spi loopback test for the
mimxrt1170_evk_cm7, enabled DMA and Async by default.
Added testcase for async and dma.

Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
2023-10-14 10:55:02 +03:00
Emilio Benavente 17032a093d drivers: spi: spi_mcux_lpspi: Updated the Async api
Updated the Async API allowing the code path
for DMA while Async is enabled. Added common
DMA function that sets up both tx and rx dma
channels.

Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
2023-10-14 10:55:02 +03:00
Declan Snyder dde691bdd4 doc: migration-guide-3.5: LPC DMA dma-channels
Include in migration guide about how the meaning of dma-channels
to the LPC DMA driver has been changed/fixed, which will
affect downstream boards, and information about the new Kconfig
achieving the old functionality of dma-channels.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2023-10-14 10:52:35 +03:00
Evgeniy Paltsev 433a85e7bf test: posix: skip nanosleep testcase for ARC HSDK boards
The comparison of cycles we get with k_cycle_get_32 may be
incorrect if counter wrap happened. In case of ARC HSDK and
ARC HSDK4xD platforms we have high counter clock frequency
(500MHz or 1GHz) so counter wrap quite likely to happen if
we wait long enough. As in some test cases we wait more than
1 second, there are significant chances to get false-positive
assertion.

So let's skip nanosleep testcase for ARC HSDK and ARC HSDK4xD
boards.

The proper fix is to use k_cycle_get_64 in this test case,
but we need to provide k_cycle_get_64 support for ARC HSDK and
ARC HSDK4xD platforms first.

Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
2023-10-13 21:59:40 -04:00
Maureen Helm e9a8497b0d doc: release: Add sensor release notes for v3.5.0
Added comments about new drivers, bug fixes, and enhancements made to
sensor drivers since the last release.

Signed-off-by: Maureen Helm <maureen.helm@analog.com>
2023-10-13 23:04:11 +03:00
Ladislav Podivin 390b6520b8 Logging: improve help message of LOG_PRINTK Kconfig option
Improve it so that:
- it mentions the important fact that it redirects `printk` messages
 to the logging subsystem
- it is consistent with the help messages of the other options in this
 file (i.e. it starts with "If enabled")

Signed-off-by: Ladislav Podivin <ladislav.podivin@tietoevry.com>
2023-10-13 22:36:47 +03:00
Andrzej Głąbek 5e38471e71 modules: hal_nordic: cmake: Fix checking if uicr DT node is accessible
According to cmake documentation, in the `if(<string>)` expression
the string evaluates to false unless its value is one of the true
constants. Thus, the commands under `if(${uicr_path})` are never
executed. Use `if(DEFINED uicr_path)` instead, since `uicr_path`
is returned by `dt_nodelabel()` and it will be undefined if such
node does not exist.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2023-10-13 21:23:17 +03:00
Artur Lipowski ded2c49e8a fs: nvs: Note about nvs_write with len equal to 0.
Add a note to explain what happens when entry with 0 data length is
written to NVS storage.

Signed-off-by: Artur Lipowski <artur.lipowski@hidglobal.com>
2023-10-13 19:10:57 +01:00
Flavio Ceolin a0db528837 maintainers: random: Add Flavio Ceolin as maintainer
Mark this subsystem as maintained and add myself
as maintainer.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2023-10-13 19:10:09 +01:00
Martin Calsyn 12c0204b60 drivers: fuel_gauge: max17048: Fix overflow when calculating voltage
Annotate the calculation with type casts to force
promotion to uint32_t and then cast back down
to uint16_t for the return. This solves the issue
with invalid voltage (mV) values being returned
due to overflow during the conversion from the
register value on the max17048 chip.

Signed-off-by: Martin Calsyn <martin.calsyn@outcomex.com.au>
2023-10-13 19:07:38 +01:00
Flavio Ceolin 49d4ad9315 doc: vuln: Add information about CVE-2023-5563
Information about CVE-2023-5563

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2023-10-13 20:19:51 +03:00
Flavio Ceolin 5e10b34a56 doc: release: 3.5: Add info about CVE-2023-5563
Add CVE-2023-5563 info to release notes.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2023-10-13 20:19:51 +03:00
Tom Burdick c678f25bc1 llext: Fix a bug in section linking
When relocating section symbol addresses the value where the
relocation is to be written is an offset into the section to load.

Simply rewriting it with the section address is not enough, we need
to write the address of the section with the offset into it.

Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
2023-10-13 16:47:02 +01:00
Christopher Friedt 7e8953ed7f posix: ensure that pooled ipc type is user-configurable
Previously it was not possible to n-select e.g.
CONFIG_PTHREAD_BARRIER because the Kconfig template for it
lacked a prompt. This made it impossible to disable some
unused POSIX features and unnecessarily increased code size
if unused code sections were not discarded by the linker.

Add a prompt so that each pooled IPC type is
user-configurable and can be disabled if unneeded.

Further, ensure that only the selected sources from lib/posix
are included in the cmake build.

Signed-off-by: Christopher Friedt <cfriedt@meta.com>
2023-10-13 11:13:07 -04:00
Andrei Emeltchenko d661c86e35 drivers: modem_cellular: Fix missing break
There is no fallthrough statement or comment so I assume break is
missing.

Fixes build time warning from some tools.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2023-10-13 17:42:40 +03:00
Wilfried Chauveau f6fe61e598 arch: arm: cortex_m: Fix constraint on inline assembly for armv8-m.baseline
`mov` on armv8-m.baseline, when used with an immediate value is limited to
registers `r0` to `r7`. `=r` tells the compiler any register can be used.
`=l` needs to be used instead.

Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
2023-10-13 13:56:42 +01:00
Andrei Emeltchenko bdd8edd67b dts: x86: Remove old atom.dtsi
Remove old unused atom.dtsi and intel,atom.yaml binding.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2023-10-13 11:37:17 +01:00
Jakub Rzeszutko 69d50db53a shell: fix a memory corruption coverity issue
Added a condition to check if the size of the copied
memory is a positive number.

Fixes #58700
Fixes #58703

Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@verkada.com>
2023-10-13 13:11:28 +03:00
Sylvio Alves 4b5331ba45 linker: esp32: move snippets-section within rom boundary
This will guarantee that application snippets will be placed
into ROM section properly.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2023-10-13 13:10:22 +03:00
Sylvio Alves ac67f245e7 west.yml: update esp32s3 to enable all flash ranges
Current hal only enable up to 16MB flash size in esp32s3 SoC.
This updates hal_espressif to include 32MB, 64MB and 128MB.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2023-10-13 10:13:56 +01:00
Declan Snyder 7d5d4ed907 drivers: eth_mcux: cache must be dcache
Currently the Kconfig for eth_mcux selects nocache if
HAS_MCUX_CACHE is set. But, for platforms that have a flexspi
cache but not a CPU cache, this is invalid, so clarify this
in the Kconfig definition.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2023-10-13 10:06:33 +01:00
Erwan Gouriou 179d435a30 Revert "drivers: serial: stm32: Make it compatible with runtime PM ....
This reverts commit 1c2d326579.
which was limited to CONFIG_UART_ASYNC_API=y case and causing regression
otherwise.

Fixes #63885

Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
2023-10-13 10:06:04 +01:00
Henrik Brix Andersen b9675b05d3 drivers: can: mcux: flexcan: override maximum HAL wait loop iterations
Add option for overriding the maximum number of wait loop iterations for
entering/leaving freeze mode. Set the default to 10000 (as opposed to a
default of 1000 used in the HAL).

Fixes: #56171

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:04:57 +01:00
Dawid Niedzwiecki f02c612c99 mgmt: ec_host_cmd: align buffers
Align the rx and tx buffers to prevent unaligned access.

Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
2023-10-13 11:59:33 +03:00
Christopher Friedt 254c6711ed tests: posix: common: init check for stdin, stdout, and stderr
Add a test to help ensure stdin, stdout, and stderr are
initialized statically.

Signed-off-by: Christopher Friedt <cfriedt@meta.com>
2023-10-13 04:48:47 -04:00
Christopher Friedt 12ea06cac2 posix: fdtable: ensure stdin, stdout, and stderr are initialized
Ensure that stdin, stdout, and stderr are initialized statically.

Previously, the mutex and condition variable were uninitialized.

Signed-off-by: Christopher Friedt <cfriedt@meta.com>
2023-10-13 04:48:47 -04:00
Dmytro Semenets d912be1c51 drivers/i2c: remove unnecessary includes
i2c_rcar.c includes soc.h header which doesn't need for this source
and exists not for all boards. soc.h header doesn't exist for rcar-gen3
soc based on arm64 core.
soc.h consists soc-depended defenitions and need to be included
by soc-depended sources.

Signed-off-by: Dmytro Semenets <dmytro_semenets@epam.com>
2023-10-13 09:46:34 +01:00
Alexander Stark d385d10130 mgmt: mcumgr: update bt smp initialization
Oneline fix to smp_bt.c smp transport register.
smp_client_transport_register() is a void function and
has no return value, so it should be ignored.

Signed-off-by: Alexander Stark <alexander.t.stark@gmail.com>
2023-10-13 09:40:21 +01:00
Henrik Brix Andersen e6197fed5f drivers: can: stm32: bxcan: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen cb207c4a11 drivers: can: sja1000: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen bb4a22fdbc drivers: can: rcar: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen 443847f0f6 drivers: can: nxp: s32: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen c986dcc027 drivers: can: mcux: flexcan: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data. The limitation of how much data to copy is currently handled in the
NXP HAL.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen 66daf05435 drivers: can: mcp251xfd: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen 4d321448ad drivers: can: mcp2515: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data. Limit the amount of data copied to the actual DLC.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen 27323a8af5 drivers: can: mcan: only copy frame data for non-RTR frames
Only copy frame data for non-RTR frames as RTR frames do not carry any
data.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen 912fc489b8 net: socketcan: only copy data payload for non-RTR frames
Only copy the data payload for non-RTR frames as RTR frames do not carry
any data.

Fixes: #57002

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen b603910214 tests: net: socket: can: split RTR flag from data contents test
Split the conversion of the RTR frame flags from the data contents test as
RTR frames do not carry any data.

Replace a couple of direct DLC assignments with proper use of
can_bytes_to_dlc().

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00
Henrik Brix Andersen 4d2251ad09 tests: drivers: can: api: only compare frame data for non-RTR frames
Only compare frame data contents for non-RTR frames as RTR frames do not
carry any data.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2023-10-13 10:08:45 +03:00