Commit Graph

91153 Commits

Author SHA1 Message Date
Maureen Helm 3c25bfefab release: Zephyr v3.6.0-rc1
Sets the version to v3.6.0-rc1.

Signed-off-by: Maureen Helm <maureen.helm@analog.com>
2024-02-05 16:36:52 -06:00
Henrik Brix Andersen 14fa9f3e21 shell: modules: kernel: include EXTRAVERSION when printing version
Include the full version in the output of the "kernel version" shell
subcommand. Previously, EXTRAVERSION was not included, causing
e.g. "3.6.0-rc1" to be printed as "3.6.0".

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-02-05 23:06:19 +01:00
Jannis Ruellmann 1d9441c872 drivers: rpi_pico_pwm: Fix compilation warnings
return value of pwm_rpi_get_clkdiv contains implicit conversions
from 'float' to 'double', triggered by floating-point operations
involving mixed data types.

Signed-off-by: Jannis Ruellmann <j.ruellmann@kunbus.com>
2024-02-05 19:58:18 +00:00
Emil Gydesen b9056de5d1 Bluetooth: ISO: Fix duplicate log statements for PDU check
Modifies two log statements so that it is clear whether it
is failing to validate broadcast or unicast PDU sizes.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 19:52:21 +00:00
Jose Alberto Meza a0c64636e1 dts: arm: mec152x: Allow to use VCI pins as GPIOs
Allow to VCI pins to be used as GPIOS using zephyr user device
tree node entry.

Signed-off-by: Jose Alberto Meza <jose.a.meza.arellano@intel.com>
2024-02-05 14:51:44 -05:00
Nikolay Agishev 9338c47f4b ARC: logging: Print exception info independent of CONFIG_LOG
Some applications turn logging off. It makes impossible to get information
about exceptions if it occures.
This PR restores correct behavior of Error_Dump messages, and
exception dump is printed anyway independent on CONFIG_LOG.

ARC_EXCEPTION_DEBUG added to default boards configs in addition to nsim.

CONFIG_FAULT_DUMP removed from ARC branch as it has been unused
since v1.8.0

Signed-off-by: Nikolay Agishev <agishev@synopsys.com>
2024-02-05 14:44:57 -05:00
Wilfried Chauveau 10bce9ddba manifest: update cmsis-dsp
Update cmsis-dsp revision to contain the fixes for:
- Buffer overflow in certain implementation of arm_conv_q31, q15 and q7
- Name conflicts with Zephyr macros SQ and ROUND_UP

Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
2024-02-05 13:26:25 -06:00
Juliane Schulze 1683f1913b drivers: Add support for TI TMAG5273 3D Hall sensor
Product Homepage:
https://www.ti.com/product/TMAG5273

Datasheet:
https://www.ti.com/lit/ds/symlink/tmag5273.pdf

Tested on a custom hardware with nRF52840.

Signed-off-by: Juliane Schulze <juliane.schulze@deveritec.com>
2024-02-05 13:23:24 -06:00
Francois Ramu ba85dac6ff boards: arm: stm32 disco kit has ospi nor flash node
Define the reg and size property for the stm32 disco kits
which have an octospi instance
Refer to the dts/bindings/flash_controller/st,stm32-ospi-nor.yaml.
Also remove the <size> property for the stm362h750 disco kit.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-02-05 12:58:03 -06:00
Radoslaw Koppel 6aac89b683 doc: releases: Build system: Introduction of LTO
This commit adds documentation about added functionality
for now interrupt tables parser and Link Time Optimisation.

Signed-off-by: Radosław Koppel <radoslaw.koppel@nordicsemi.no>
2024-02-05 12:49:46 -06:00
Emil Gydesen 97f7cdac84 docs: Bluetooth: Additional broadcast assistant shell documentation
Improves the broadcast assistant shell documentation
which updates the existing documentation and adds
documentation to commands not yet documented.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 12:40:23 -06:00
Emil Gydesen 27abc1d944 Bluetooth: BAP: Broadcast assistant shell treat PA sync as bool
Modify the broadcast assistant commands that take the PA sync argument
so that it is treated as a bool. This allows users to use
"true", "on", "1" or "0x01" for true values and "false", "off", "0"
for false values.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 12:40:23 -06:00
Grant Ramsay 6865e2ab67 drivers: can: mcan: Fix off-by-one errors in asserts
Fix off-by-one errors in asserts.

Signed-off-by: Grant Ramsay <gramsay@enphaseenergy.com>
2024-02-05 12:37:27 -06:00
Armando Visconti 80676825e1 samples/sensor: lsm6dsl: fix -Wdouble-promotion warning
Fix -Wdouble-promotion warning just using sensor_value_to_double()
routine.

Fixes #68284

Signed-off-by: Armando Visconti <armando.visconti@st.com>
2024-02-05 18:51:38 +01:00
Troels Nilsson 8acca664d2 Bluetooth: Controller: Fix periodic adv data truncation
Advertising data has to be truncated at a PDU boundary

Similar to earlier fix for extended advertising reports

Found in several EBQ tests, including LL/DDI/SCN/BV-25-C,
LL/DDI/SCN/BV-21-C and LL/DDI/SCN/BV-46-C

Signed-off-by: Troels Nilsson <trnn@demant.com>
2024-02-05 18:18:57 +01:00
Lyle Zhu 4e7be1ecaa Bluetooth: Host: set valid SCO packet type
The SCO cannot be created if the eSCO is unsupported.
It is caused by the packet type cannot be set
correctly.

Set valid bitmap for SCO and eSCO packet type in
command "Accept Synchronous Connection Request".

Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
2024-02-05 17:46:49 +01:00
Emil Gydesen 017f59cb66 Bluetooth: BAP: Broadcast sink: Fix bis_sync in update_recv_state_base
In the update_recv_state_base function, we should update the
BASE with any new metadata that we have received (as that may
change while streaming). However, this function did not properly
keep the existing bis_sync values for the
subgroups, causing the bis_sync for all subgroups to be 0.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 17:46:31 +01:00
Emil Gydesen 43bc3200fa Bluetooth: BAP: Stop broadcast sink from removing receive state
The receive state may be added by the broadcast sink if not added
by the application, but even in that case when the broadcast sink
is deleted, we should not remove the receive state, as the receive
state may still container information about the PA sync that has a
lifetime not coupled with the broadcast sink.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 17:46:11 +01:00
Emil Gydesen 7643526086 Bluetooth: BAP: Do not send PA term request on local remove
If the receive state is locally removed, then we should not
request permission from the application, as that is implicit
when removing the source locally.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 17:45:45 +01:00
Fabio Baltieri 069cdffbc3 tests: display: fix the test so it actually builds
The test is configured to replace the config rather than extending,
resulting in a build with CONFIG_DISPLAY=n and the driver not being
actually built.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2024-02-05 17:45:25 +01:00
Flavio Ceolin 5f4210e499 west: mbedtls: Bump to 3.5.2
Bump mbedTLS to 3.5.2

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-05 10:10:30 -06:00
Emil Gydesen 5bb8ffb517 doc: releases: Add migration of the LC3 macro renames
Add a short migration guide for the LC3 macro renames.
Only a few examples are mentioned, as there are far too
many changes to describe them all.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 09:14:44 -06:00
Emil Gydesen d6046b8b2f Bluetooth: Audio: Move assigned numbers from lc3.h to audio.h
The assigned numbers are not specific to LC3, so they should be
defined in the more general audio.h header file.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 09:14:44 -06:00
Emil Gydesen cbc81b2a0f Bluetooth: Audio: Remove LC3 from the assigned numbers defines
The defines from the Bluetooth Audio assigned numbers are not
specific for LC3. This commit removes the LC3 infix and
the reference to LC3 in the documentation for them.

It also cleans up some of the documentation and
names of the enums.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 09:14:44 -06:00
Emil Gydesen c2db67f997 Bluetooth: Audio: remove BT_HCI_CODING_FORMAT_LC3 from lc3.h
The BT_HCI_CODING_FORMAT_LC3 is defined in hci_types.h and
applications should use that value.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 09:14:44 -06:00
Christopher Friedt 4174ff119d posix: cmake: allow empty library
This change mitigates the following cmake warning

No SOURCES given to Zephyr library: lib__posix__options

without needing to have a separate interface library
(as we do not need private headers exposed).

Signed-off-by: Christopher Friedt <cfriedt@meta.com>
2024-02-05 15:35:09 +01:00
Dominik Ermel 5f31c15b1d tests/settings/file: increase main stack size
Increase ZTEST and MAIN stack to 4k.

Fixes #57324

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-02-05 14:50:52 +01:00
Kai Vehmanen 00d4661273 drivers: dma: intel-adsp-hda: modify stop dma logic
Commit b2eaa6448076 ("drivers: dma: intel-adsp-hda: add delay to stop
host dma") added a wait on GBUSY state to host DMA stop.

This is problematic as in some case (like SOF chain-DMA usage),
the host DMA side RUN bit is not cleared when intel_adsp_hda_dma_stop()
is called. It is not possible to wait on GBUSY bit as there are
valid cases where it can remain set.

Address the original problem described in SOF bug #8686 and add a
polling check for intel_adsp_hda_is_enabled(). As per the bug
description, in some cases the GEN/FIFORDY bits are not cleared
immediately and if a new call to intel_adsp_hda_dma_stop() is made, the
PM refcounting will go haywire.

Link: https://github.com/thesofproject/sof/issues/8686
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2024-02-05 14:50:14 +01:00
Joel Guittet 415cb65e3f drivers: input: cst816s: add alternative chip id
The CST816S chip ID have an alternative value. It seems that this
field represents in fact a version number of controller. Fix by adding
the new chip ID.

Signed-off-by: Joel Guittet <joelguittet@gmail.com>
2024-02-05 14:49:33 +01:00
Grzegorz Swiderski e5d14c6821 riscv: linker: Fallback to Kconfig when defining ROM region
With `CONFIG_XIP=y`, this linker script would derive the ROM region from
the chosen `zephyr,flash` DT node with "soc-nv-flash" or "jedec,spi-nor"
as its compatible. If the node was absent or had a different compatible,
then linking would fail with:

    undefined symbol `ROM_BASE' referenced in expression

Fix this by using `CONFIG_FLASH_BASE_ADDRESS` and `CONFIG_FLASH_SIZE`
for ROM base and size respectively. The existing DT logic is preserved
for compatibility with out-of-tree boards, so the flash Kconfigs serve
as a mere fallback.

In addition, use `CONFIG_FLASH_LOAD_OFFSET` and `CONFIG_FLASH_LOAD_SIZE`
if defined, to align with some other architectures' linker scripts. For
the existing in-tree RISC-V boards, this should not make a difference.

The alternative would've been making sure that all boards and SoCs have
the relevant Kconfigs set, and only using those in the linker script.
The downside is that `CONFIG_FLASH_SIZE` is given in units of 1 KiB,
while some existing boards - hifive1_revb, sparkfun_red_v_things_plus -
have more granular flash sizes, which would've been rounded down.

Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
2024-02-05 14:05:57 +01:00
Gerson Fernando Budke 5903c7a669 drivers: watchdog: sam0: initialize GCLK2 in wdt_sam0_init
Initialize GCLK2 to output 1.024kHz required by watchdog timer.

Co-authored-by: Vlad Laba7 <vlad@laba7.com>
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2024-02-05 13:27:54 +01:00
Armando Visconti 277d649bda drivers: sensor: tmp108: fix coverity integer handling issue
Fix coverity integer handling issue (CWE-188).
Modifying a variable through a pointer of an incompatible type (other
than unsigned char) can lead to unpredictable results.

Fix: #67965
Coverity-CID: 248434

Signed-off-by: Armando Visconti <armando.visconti@st.com>
2024-02-05 13:13:51 +01:00
Emil Gydesen 68ed2e019f Bluetooth: VCP: Fix missing guards for AICS and VOCS
Some places VCP accessed AICS and VOCS when it was not supported.
Also modify existing guards to be consistent with new guards.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 13:13:00 +01:00
Emil Gydesen adb74f0f16 Bluetooth: MICP: Fix missing guards for AICS
Some places MICP accessed AICS when it was not supported.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 13:13:00 +01:00
Emil Gydesen ab1b43ee1a Bluetooth: VCP/MICP: Fix VOCS and AICS instance counts
The VCP and MICP instances should use their respective
AICS and VOCS Kconfig options, rather than the overall
Kconfig options.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-05 13:13:00 +01:00
Radoslaw Koppel 08070fbf1f arch: arm, arm64: Remove zephyr prefix from linker includes
This fix removes the zephyr/ prefix from linker included files.
With this prefix the build works only for Ninja and not for
other build tools.

Linking in Zephyr / CMake:
 - Ninja invokes linking directly from <build>.
 - Make invokes linking form <build>/zephyr.

The linker default uses cwd for looking up INCLUDE directives if not found
in list of includes.
Zephyr always adds <build>/zephyr as link include using CMake,
and this is passed to ld as -L<build>/zephyr therefore using
INCLUDE isr_tables_swi.ld ensures it will be correctly found in all cases.

Signed-off-by: Radosław Koppel <radoslaw.koppel@nordicsemi.no>
2024-02-05 12:32:46 +01:00
Radoslaw Koppel adaacefc20 arch: arm, arm64: Disable swi_tables.ld file when not required
This commit removes the need of swi_tables.ld file if the
ISR table generator is not configured to use it.

Signed-off-by: Radosław Koppel <radoslaw.koppel@nordicsemi.no>
2024-02-05 12:32:46 +01:00
Joel Guittet e90613efb2 drivers: display: gc9x01x: fix bindings include
The GC9X01X driver relies on panel.h instead of gc9x01x.h (doesn't
exist).

Signed-off-by: Joel Guittet <joelguittet@gmail.com>
2024-02-05 09:38:57 +00:00
Joel Guittet 8f267065f2 dts: bindings: fix gc9x01x display documentation
The bindings documentation contains a deprecated pixel-format.

Signed-off-by: Joel Guittet <joelguittet@gmail.com>
2024-02-05 09:38:57 +00:00
Ian Morris 826d67af91 drivers: serial: ra: reduce uart baud rate error
Using the 8 base clock cycles per bit period setting (instead of 16)
reduces the uart baud rate error when using a 12MHz crystal (found on
many RA Microcontroller development kits boards). This setting also
slightly reduces the error when using the internal 48MHz oscillator,
used by the Arduino UNO R4 Minima board currently support by Zephyr.

Signed-off-by: Ian Morris <ian.d.morris@outlook.com>
2024-02-04 19:55:45 -06:00
Daniel Leung caacc27d37 kernel: smp: CPU start may result in null pointer access
It is observed that starting up CPU may result in other CPUs
crashing due to de-referencing NULL pointers. Note that this
happened on the up_squared board, but there was no way to
attach debugger to verify. It started working again after
moving z_dummy_thread_init() before smp_timer_init(), which
was the old behavior before commit
eefaeee061 where the issue
first appeared. So mimic the old behavior to workaround
the issue.

Fixes #68115

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-02-04 19:55:14 -06:00
Emil Gydesen 065253c173 Bluetooth: CAP: Make unicast stop more similar to unicast start
Modify the parameters for bt_cap_initiator_unicast_audio_stop
so that they are more similar to
bt_cap_initiator_unicast_audio_start.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-04 19:54:18 -06:00
Emil Gydesen ec549cebd5 Bluetooth: CAP: Make unicast update more similar to unicast start
Modify the parameters for bt_cap_initiator_unicast_audio_update
so that they are more similar to
bt_cap_initiator_unicast_audio_start.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-04 19:54:18 -06:00
Emil Gydesen f35e9871d5 Bluetooth: CAP: Remove unicast group param from unicast_audio_start
Since we can always lookup the group from the streams, the
group parameter had no purpose.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-04 19:54:18 -06:00
Andy Ross 840db7858e kernel/thread: Detect in-kernel "reserved" stack overflow
Traditionally, k_thread_create() has required that the application
size the stack correctly.  Zephyr doesn't detect or return errors and
treats stack overflow as an application bug (though obviously some
architectures have runtime features to trap on overflows).

At this one spot though, it's possible for the kernel to adjust the
stack for K_THREAD_STACK_RESERVED in such a way that the arch layer's
own stack initialization overflows.  That failure can be seen by
static analysis, so we can't just sweep it under the rug as an
application failure.

Unfortunately there aren't any good options for handling it here (no
way to return failure, can't be a build assert as the size is a
runtime argument).  A panic will have to do.

Fixes: #67106
Fixes: #65584

Signed-off-by: Andy Ross <andyross@google.com>
2024-02-04 10:23:25 -05:00
Anas Nashif f6adaf55aa manifest: update sof sha in manifest
point to d40682678b7378fb930ca5535ccd2ce667ed5c27.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-02-03 13:42:33 -05:00
Anas Nashif d7678f1694 xtensa: move to use system cache API support for coherency
Remove custom implementation and use system cache interface instead.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-02-03 13:42:33 -05:00
Anas Nashif 9183ceaf91 cache: introduce incoherent cache interface
Introduce a set of cache APIs used on architectures with cache incoherency.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-02-03 13:42:33 -05:00
Grant Ramsay 211ddf1c7e soc: arm: xilinx_zynqmp: Add "Execute Never" MPU flag to non-code RAM
Executing from RAM sections other than rom/code should cause a fault.
This is tested as part of the kernel mem_protect tests.

Signed-off-by: Grant Ramsay <gramsay@enphaseenergy.com>
2024-02-02 17:05:01 -06:00
Grant Ramsay c81eaff1d9 tests: kernel: mem_protect: Handle thumb instructions for Cortex-R
Check for COMPILER_ISA_THUMB2 rather than CPU_CORTEX_M when determining
if special handling is required for thumb instructions.

This prevents false negative results on Cortex-R devices that may
generate a fault (test pass) even if the MMU/MPU is not configured
correctly.

Signed-off-by: Grant Ramsay <gramsay@enphaseenergy.com>
2024-02-02 17:05:01 -06:00