Commit graph

91032 commits

Author SHA1 Message Date
Ben Marsh 2419274073 subsys/dfu/boot: Fix image confirm for Direct XIP
Previously the boot_write_img_confirmed() function used the MCUboot
public API function boot_set_confirmed(), but this function is hardcoded
to set the confirmed flag of slot 0. This works for MCUboot swap modes
but not for Direct XIP, where applications can execute out of secondary
slots.

This commit changes boot_write_img_confirmed() to instead use
boot_set_next() which sets the confirmed flag for a given flash area
and works with Direct XIP.

DT_CHOSEN(zephyr_code_partition) is used to get the current partition.
The zephyr,code-partition chosen node must be defined.

This commit also adds the zephyr,code-partition chosen node to the
native_sim devicetree to allow the tests under tests/subsys/dfu to
build for this target.

Signed-off-by: Ben Marsh <ben.marsh@helvar.com>
2024-02-06 21:00:36 +01:00
Hou Zhiqiang b985442829 dts: mimx93_evk_a55: avoid conflict with Ethos-U NPU reserved memory
The DRAM range 0xc0000000~0xcfffffff is reserved for the Ethos-U NPU,
so change the RAM base to 0xd0000000.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
2024-02-06 19:36:03 +01:00
Abderrahmane Jarmouni 92a24ba4b4 shell: backends: fix for async shell selection
This patch modifies the way SHELL_BACKEND_SERIAL_API_ASYNC is selected.
The current logic causes conflicts (no console output) when the user tries
to use one of the UARTs in async mode, by setting CONFIG_SHELL_ASYNC_API,
while using Shell with a different UART (typically the Console's one).

Signed-off-by: Abderrahmane Jarmouni <abderrahmane.jarmouni-ext@st.com>
2024-02-06 19:34:15 +01:00
Gerard Marull-Paretas b548a73e79 drivers: console: uart_mux: fix incorrect usage of configuration API
First, the API ops are available only if
CONFIG_UART_USE_RUNTIME_CONFIGURE=y, but the driver was not guarding the
code. Also, according to the API specs, these functions are optional,
and the interface already returns -ENOSYS if they are not implemented.
To solve both problems, just drop the dummy implementation.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-02-06 19:33:42 +01:00
Wajdi ELMuhtadi b8eceac77b doc: _scripts: redirects: fix redirect for google iot mqtt
fix incorrect redirect for google iot mqtt missing README

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-02-06 18:57:45 +01:00
Wajdi ELMuhtadi e5351b0d10 samples: sensor: wsen_hids: remove example for wsen_hids
Remove example for wsen_hids to switch to
generic sensor driver examples.

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-02-06 18:57:45 +01:00
Wajdi ELMuhtadi 56b70bddcc samples: sensor: wsen_itds: remove example for wsen_itds
Remove example for wsen_itds to switch to
generic sensor driver examples.

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2024-02-06 18:57:45 +01:00
Jose Alberto Meza b5a39b896b dts: arm: microchip: mec1501: mec172xnsz: Remove pinctrl from SoC dts
Remove pinctrl from device tree since it is not required
when internal oscillator is used.

Signed-off-by: Jose Alberto Meza <jose.a.meza.arellano@intel.com>
2024-02-06 18:56:27 +01:00
Jose Alberto Meza c909915cda dts: bindings: clock: pinctrl is not required for all clock options
Pinctrl is not required when internal oscillator is used

Signed-off-by: Jose Alberto Meza <jose.a.meza.arellano@intel.com>
2024-02-06 18:56:27 +01:00
Karthikeyan Krishnasamy 730e08405c samples: cellular_modem: add device specific config
enable uart async api for rak5010_nrf52840

Signed-off-by: Karthikeyan Krishnasamy <karthikeyan@linumiz.com>
2024-02-06 18:55:19 +01:00
Karthikeyan Krishnasamy b7799c1a2f boards: arm: rak5010_nrf52840: update modem dts changes
remove legacy modem properties and add modem node
compatible to modem subsystem, rak5010_nrf52840
has two variant, one with BG95-M3 and other is
BG96 modem, both are pin to pin compatible.

Signed-off-by: Karthikeyan Krishnasamy <karthikeyan@linumiz.com>
2024-02-06 18:55:19 +01:00
Emil Gydesen 8fa312f015 doc: Bluetooth: Add broadcast assistant sample to audio stack status table
Mark the broadcast assistant as having a sample application
since that was recently implemented.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-06 18:06:54 +01:00
Guillaume Gautier c1327db630 drivers: serial: stm32: always enable clock when exiting low power
Systematically enable the UART clock again when exiting a low power mode
before reading the UART register.
Even though the previous code worked on STM32WBA, for most series, it is
necessary to enable the clock to access the registers, otherwise they read
as 0.

Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
2024-02-06 08:48:05 -06:00
Jonathan Rico f24a01e6d1 ipc: Drain pending work items before deregistering endpoint
The work item will attempt to dereference pointers that have been nulled
by the backend.

To avoid that, wait until all items currently on the queue have been
processed.

The symptom is a busfault on ARM, and is "fixed" by adding a
`k_msleep(1)` right before `ipc_service_deregister_endpoint()`. This
will in effect do the same thing as this patch, and allow the scheduler
to run the work item on the ipc workqueue.

Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
2024-02-06 14:22:36 +01:00
Carles Cufi 35022839f1 doc: releases: Clarify what belongs in relnotes vs migration
The intention of this commit is to clarify what belongs where, given
that recent contributions have made it unclear.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2024-02-06 14:20:36 +01:00
Parthiban Nallathambi fd85021718 modem: change log level of events prints to debug
info level is printed always to console and it's noisy.
Change to debug level, which can be enabled with
CONFIG_MODEM_MODULES_LOG_LEVEL_DBG

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
2024-02-06 13:00:05 +01:00
Flavio Ceolin 5b9f7b7b32 intel_adsp: ace: Remove dead code
ace/boot.c is ace specific file and RESET_MEMORY_HOLE symbol is never
defined for this target.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-06 12:59:42 +01:00
Konrad Derda e46fbd9de8 docs: migration-guide-3.6: add note about changes in net buffer pools
Add point about moving maximum allocation size from fixed buffer pool's
internal structure to a common one.

Signed-off-by: Konrad Derda <konrad.derda@nordicsemi.no>
2024-02-06 12:56:37 +01:00
Konrad Derda 28f37e07b6 tests: net: buf: additional verification of fixed buffer pool
This commit introduces two changes:
- veryfing fixed buffer's size and length after allocation to existing
  test case
- new test veryfing appending bytes to a network buffer from a fixed
  size pool

Signed-off-by: Konrad Derda <konrad.derda@nordicsemi.no>
2024-02-06 12:56:37 +01:00
Konrad Derda b324e1e4d8 net: buf: add max allocation size to allocation info
Previously, there was no way to determine maximum number of bytes
that can be allocated using only net_buf structure. This commit
introduces such field.

Moreover, this commit fixes an issue where allocation of less than
maximum number of bytes from a fixed buffer pool would set buffer's
size to this number instead of the whole buffer size.

Signed-off-by: Konrad Derda <konrad.derda@nordicsemi.no>
2024-02-06 12:56:37 +01:00
Konrad Derda 57cd012476 test: net: net_pkt: use var buffer pool for testing
From change 47eb592c28b9e7dfbdd25fedbf07a528ad240084 net_buf structures
allocated from pools defined with NET_BUF_POOL_FIXED_DEFINE() will keep
their `size` member set to the actual fixed size and not requested
size like before.

For this set of tests NET_BUF_POOL_FIXED_DEFINE() for several test
cases. These tests check the several values based on a fact that the
network buffer's size was set to the requested size.

This commit changes definition of the buffer pool to
NET_BUF_POOL_FIXED_DEFINE() in order to satisfy these expectations.
This change does not impact the tests themselves.

Signed-off-by: Konrad Derda <konrad.derda@nordicsemi.no>
2024-02-06 12:56:37 +01:00
Krzysztof Chruściński f6ecad20a1 drivers: serial: Fix async to interrupt driven adaptation layer
Whenever UART_RX_DISABLED event is received module attempts to
re-enable receiver since in interrupt driven API receiver is
always on. However, it is possible that there is no free buffers
and in that case attempt to enable the receiver will fail with
-EBUSY. That scenario shall be accepted since the receiver will
be re-enabled when at least one buffer will be freed.

Given that, -EBUSY return shall be accepted (no assert) and
number of pending RX buffer requests shall be reset only on
successful enabling.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-02-06 09:54:34 +01:00
Daniel Leung 627d3b2cb6 lib: cbprintf: do not blindly skip tags
When CONFIG_LOG_USE_TAGGED_ARGUMENTS is enabled, and
CONFIG_CBPRINTF_COMPLETE is also enabled, we should not be
blindly skipping tags when processing the tagged package
for output.  The issue is that if there is a "%%" in
the format string, the specifier is considered invalid but
the code blindly skips ahead in the argument list as if
it is a valid specifier (think "%s"), which resulting in
the next valid specifier using incorrect argument in
the list. So fix it by skipping ahead if and only if
the specifier is not invalid.

Fixes #68271

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-02-06 09:53:15 +01:00
Flavio Ceolin 7812e54e8a pm: device_runtime: Simplify runtime_enable
Move the check of PM_DEVICE_FLAG_RUNTIME_ENABLED to the beginning of
the function. With this we avoid taking/release the semaphore and also
we no longer need check it in runtime_enable_sync(), because it was
already checked in pm_device_runtime_enable().

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-06 09:52:38 +01:00
Flavio Ceolin 75fd75c227 pm: device_runtime: Fix tracing in runtime_enable
Move around SYS_PORT_FUNC_ENTER and change a early return
in a way that when this function is called it will generate
tracing for entering / leaving this function.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-06 09:52:38 +01:00
Flavio Ceolin 597024449c pm: device_runtime: Simplify runtime_disable
Move the check of PM_DEVICE_FLAG_RUNTIME_ENABLED to the beginning of
the function. With this we avoid taking/release the semaphore and also
we no longer need check it in runtime_disable_sync(), because it was
already checked in pm_device_runtime_disable().

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-06 09:52:38 +01:00
Flavio Ceolin 2261fae9d7 pm: device_runtime: Fix tracing in runtime_disable
Move around SYS_PORT_FUNC_ENTER and change a early return
in a way that when this function is called it will generate
tracing for entering / leaving this function.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-06 09:52:38 +01:00
Emil Gydesen 590d3e1114 Bluetooth: BAP: Broadcast source enabling state transition fix
Since we may go from enabling to qos-configured state if the
call to bt_iso_big_create fails, that is a valid transition.
If bt_iso_big_create currently fails, then the source ends in a
state where it cannot be recovered.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-06 09:51:16 +01:00
Emil Gydesen f4b83415d6 Bluetooth: CAP: Fix uninitialized values in broadcast start
When CONFIG_BT_ISO_TEST_PARAMS is enabled then the
bt_bap_broadcast_source_param in
bt_cap_initiator_broadcast_audio_create had uninitialized values.

A general and future proof solution for this is to simply initialize
the entire struct to 0.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-06 09:50:53 +01:00
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