Commit graph

99,250 commits

Author SHA1 Message Date
Marc Herbert
f91d4731af pm: use braces for .pm_base inside anonymous union initializer
Fixes commit 25173f71cd ("pm: device_runtime: Extend with synchronous
runtime PM")

Fixes compilation with gcc 4.2-based toolchain used by SOF for TGL
generation products. As seen in the error message below, that gcc
version requires braces for initialization of anonymous unions:

```
zephyr/soc/xtensa/intel_adsp/common/mem_window.c:62:
   error: unknown field ‘pm_base’ specified in initializer
   warning: missing braces around initializer
   warning: (near initialization for ‘__device_dts_ord_66.<anonymous>’)
```

This is a well-known and recurring issue, see past example(s) in #68118

As the Zephyr build is deterministic, I could easily verify that this
commit makes zero .obj difference (when using the Zephyr SDK).

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2024-02-21 16:57:56 +01:00
Flavio Ceolin
18c96b64c7 doc: security: cve-2023-6881 left embargo
Disclose information about cve-2023-6881.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-21 16:12:26 +01:00
Flavio Ceolin
53f527cc2d doc: release-notes-3.6: Security related changes
Security release notes for 3.6

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-21 00:04:39 +01:00
Andrej Butok
19dfdb9a72 doc: mcumgr: fix double "the"
Fix double "the" in the mcumgr example.

Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
2024-02-20 15:09:13 -06:00
Johann Fischer
6321af9593 doc: release-notes-3.6: add release notes for USB
Add release notes for USB support.

Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
2024-02-20 15:08:26 -06:00
Flavio Ceolin
3fb795a27f doc: security: cve-2024-1638 left embargo
Disclose information about cve-2024-1638.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-20 15:07:07 -06:00
Henrik Brix Andersen
7498cd262f docs: release: migration-guide: 3.6.0: reorder entries a bit
Reorder a few entries in the v3.6.0 migration guide in order to list the
ones likely to affect most people more prominently.

Group related entries together and get rid of a couple of empty headlines.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-02-20 15:03:49 -06:00
Maureen Helm
c33743ef95 release: Zephyr v3.6.0-rc3 v3.6.0-rc3
Sets the version to v3.6.0-rc3.

Signed-off-by: Maureen Helm <maureen.helm@analog.com>
2024-02-19 17:01:40 -06:00
Alberto Escolar Piedras
a3ad40b1ee docs: BT tools: Fix description around native BT user chan use
With native_sim one uses the BT user channel driver (which connects
directly to the user channel linux socket), not a serial port.
Let's fix the description, and provide a nicer link.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-02-19 21:15:19 +01:00
Alberto Escolar Piedras
cf315e77dd doc: Bluetooth dev: Fix mention of nrf52 not supporting split builds
Since #67318 we support split builds in the simulated nRF52
over the UART, and we actually have this configuration
tested in CI.
This documentation paragraph was still mentioning this is not
supported. So let's fix it.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-02-19 21:15:08 +01:00
Emil Gydesen
686a8c9e54 tests: bsim: Bluetooth: Add GATT encrypt tests
Add tests for the GATT permissions to read and write for
characteristics that require encryption and LESC encryption.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-19 20:46:28 +01:00
Emil Gydesen
fa4a6f3c68 tests: bsim: Bluetooth: Fix GATT long read test
The test where it was supposed to read the long characteristic,
only read the "small" characteristic, due to setting the wrong handle.

With the right handle, the test failed and the test had to be
updated to store the data across multiple reads, and then do
the proper comparison.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-19 20:46:28 +01:00
Emil Gydesen
d9ff7eb0ed Bluetooth: GATT: Add missing LESC_MASK for encrypt check
The LE Secure connection (LESC) mask also require encryption,
and some users have been using e.g. BT_GATT_PERM_READ_LESC
without BT_GATT_PERM_READ_ENCRYPT, and then the encryption
check in bt_gatt_check_perm was never properly applied.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-19 20:46:28 +01:00
Ryan McClelland
073871bdeb doc: release-notes-3.6: add release note about -Wdouble-promotion
This adds a release note about -Wdouble-promotion now being a default
warning flag.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2024-02-19 20:35:05 +01:00
Tim Lin
77244aae1d ITE: drivers/gpio: Fix untrusted loop bound
The pin in the loop start counting from 0, so the condition of the
for loop should not be equal to num_pins.

Fixes #69118

Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
2024-02-19 19:59:27 +01:00
Venkataramana Kotakonda
ca371d6890 drivers: espi: Clear virtual wire interrupt before calling handler
Clearing virtual wire interrupt after calling handler may cause next
interrupt miss if the same virtual wire changes due to action in handler.
As the interrupt source is read from register, it can be cleared before
calling handler to avoid next interrupt miss due to action/delay in the
callback handler.

Signed-off-by: Venkataramana Kotakonda <venkataramana.kotakonda@intel.com>
2024-02-19 19:58:28 +01:00
Henrik Brix Andersen
79d5857e9f drivers: adc: max1125x: use K_KERNEL_STACK_SIZEOF()
Use K_KERNEL_STACK_SIZEOF() for calculating thread stack size, as this
takes K_KERNEL_STACK_RESERVED into account.

Fixes: #69129

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-02-19 12:52:52 -06:00
Henrik Brix Andersen
ad85283906 drivers: adc: ad5592: use K_KERNEL_STACK_SIZEOF()
Use K_KERNEL_STACK_SIZEOF() for calculating thread stack size, as this
takes K_KERNEL_STACK_RESERVED into account.

Fixes: #69133

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-02-19 12:52:52 -06:00
Henrik Brix Andersen
4274d1b365 drivers: adc: ads7052: use K_KERNEL_STACK_SIZEOF()
Use K_KERNEL_STACK_SIZEOF() for calculating thread stack size, as this
takes K_KERNEL_STACK_RESERVED into account.

Fixes: #69132

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-02-19 12:52:52 -06:00
Henrik Brix Andersen
0e321ecc90 drivers: adc: lmp90xxx: use K_KERNEL_STACK_SIZEOF()
Use K_KERNEL_STACK_SIZEOF() for calculating thread stack size, as this
takes K_KERNEL_STACK_RESERVED into account.

Fixes: #69131

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-02-19 12:52:52 -06:00
Henrik Brix Andersen
ae81429a81 drivers: adc: mcp320x: use K_KERNEL_STACK_SIZEOF()
Use K_KERNEL_STACK_SIZEOF() for calculating thread stack size, as this
takes K_KERNEL_STACK_RESERVED into account.

Fixes: #69130

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2024-02-19 12:52:52 -06:00
Alberto Escolar Piedras
32939fa86f doc: native_sim: Native logger backend is always enabled by default
Since bd9836be8c
the native logger is enabled always (even if a UART is present)
as it was though more conveniant for users.
But the documentation was not updated to reflect this.
Let's fix it.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-02-19 12:46:15 -06:00
Alberto Escolar Piedras
72d425ba1d docs/develop/test/bsim: Two trivial fixes
Fix a typo and let a file be a link instead of just
its name.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-02-19 12:43:20 -06:00
Andrej Butok
dc3a245772 doc: release-notes-3.6: Update MCUboot change log.
Added new Zephyr MCUBoot supported platforms and
new CONFIG_MCUBOOT_IMGTOOL_OVERWRITE_ONLY parameter.

Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
2024-02-19 19:07:38 +01:00
Robert Lubos
bc2858ad2d net: lib: coap: Add error check when waking server thread
There's not much to be done in case waking up the server thread with
socketpair send() fails, but at least we can log an error on such event
(to please coverity).

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2024-02-19 19:07:03 +01:00
Gustavo Silva
b2b4016963 drivers: charger: bq25180: fix return value check
Fix missing check of the return value of `bq25180_set_charge_current`
function, resulting in logically dead code, as indicated by Coverity
CID 347197.

Signed-off-by: Gustavo Silva <gustavograzs@gmail.com>
2024-02-19 09:38:50 -06:00
Kevin Townsend
d18a7b7427 doc: release: Add Arm arch to 3.6 release notes
Adds highlights for the Arm architecture to the 3.6 release notes.

Signed-off-by: Kevin Townsend <kevin.townsend@analog.com>
2024-02-19 09:08:54 -06:00
Andy Sinclair
4f64d61f7a doc: release: 3.6: Release notes for mfd and regulators
Added release notes for mfd and regulators

Signed-off-by: Andy Sinclair <andy.sinclair@nordicsemi.no>
2024-02-19 09:08:14 -06:00
Sylvio Alves
5b4c927c50 samples: esp32: do not search for all regions
Current SPIRAM sample code tries to search for any available
heap, causing this test to fail. Make sure the sample code
only malloc data from external ram.

Fixes #65997

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2024-02-19 11:05:09 +01:00
Maureen Helm
28555ae9f4 arch: Fix bounds checking for dynamic shared interrupts
Fixes z_isr_install() and z_isr_uninstall() routines to check the isr
table index against the correct number of isr table entries. This
prevents out-of-bounds isr table accesses when
CONFIG_GEN_IRQ_START_VECTOR is greater than zero, such as on the ARC
architecture.

Coverity-CID: 347187
Coverity-CID: 347189
Coverity-CID: 347097
Coverity-CID: 347203
Coverity-CID: 347210

Signed-off-by: Maureen Helm <maureen.helm@analog.com>
2024-02-19 09:32:38 +01:00
Flavio Ceolin
a6e9f12ca8 doc: security: cve-2023-5779 left embargo
Disclose information about cve-2023-5779.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-18 18:05:51 +01:00
Flavio Ceolin
194bc9b176 doc: security: cve-2023-6249 left embargo
Disclose information about cve-2023-6249.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-18 18:05:51 +01:00
Flavio Ceolin
a8690fd862 doc: security: cve-2023-6749 left embargo
Disclose information about cve-2023-6749.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-18 18:05:51 +01:00
Ayush Singh
7c9dbde659 ieee802154: ieee802154_cc13xx_cc26xx_subg: Fix 6lowpan for cc1352p7
- Fix using custom setup function
- Enable pRegOverrideTxStd and pRegOverrideTx20 in
  ieee802154_cc13xx_subg_radio_div_setup struct

Signed-off-by: Ayush Singh <ayushdevel1325@gmail.com>
2024-02-17 21:14:30 +01:00
Mahesh Mahadevan
13686158fd doc: release-notes-3.6: Update release notes for NXP additions
NXP additions for 3.6 release

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2024-02-17 19:40:36 +01:00
Alberto Escolar Piedras
545d68a5a3 native_simulator: Get latest from upstream
Align with native_simulator's upstream main
f02906708cf1668fe54ef2c2f1e159ed947573aa

Which includes:
* f029067 CPU ctrl: Fix two malformed error/warning messages
* 114f78b Host trampolines: Fix typos in comment

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-02-17 17:30:33 +01:00
Daniel DeGrasse
39ea8ac87a samples: drivers: mbox: remove mimxrt595_evk_cm33
Remove mimxrt595_evk_cm33 from the MBOX sample. Although this SOC has
support for both cores, there is no support in tree for booting the
secondary core from the primary one, so this sample cannot run on
hardware.

Fixes #69092

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-02-17 14:19:06 +01:00
Daniel DeGrasse
9a96a0c50d soc: arm: nxp_imx: fix flexspi frequency setting for iMXRT11xx SOC
Commit a10fee2d5e (drivers: clock_control: ccm_rev2: add support for
reclocking FlexSPI) introduced the ability to set the FlexSPI
clock frequency at runtime on RT11xx series SOCs. However, this
implementation resulted in the clock frequency being rounded up, not
down. This can result in flash clock frequency violations on some
flash parts, causing the system to crash when running in XIP mode.

Fixes #69088

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-02-17 14:18:43 +01:00
Declan Snyder
5a3c77e746 doc: release-notes-3.6: MDIO changes
Add changes to 3.6 release notes for MDIO drivers

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-02-17 14:17:55 +01:00
Daniel DeGrasse
5dad8d72ee doc: release-notes-3.6: remove section for disk drivers
No changes have been made to disk drivers since 3.5, so remove the
section for this release.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-02-17 00:16:09 +01:00
Daniel DeGrasse
27cd3232e6 doc: release-notes-3.6: add SD and SDHC changes
Add SD and SDHC release notes, including the addition of the SDIO
subsystem

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-02-17 00:16:09 +01:00
Flavio Ceolin
17c5753b55 doc: release-notes-3.6: PM related changes
Power management release notes for 3.6

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-02-16 15:48:59 -06:00
Ali Hozhabri
ee13e0d271 doc: releases: Changes to SPI properties
Update release-notes version 3.6.0 with the SPI properties changes.

Signed-off-by: Ali Hozhabri <ali.hozhabri@st.com>
2024-02-16 13:34:18 -06:00
Ali Hozhabri
3ad3fd2950 doc: releases: ST BlueNRG changes
Update release-notes and migration-guide version 3.6.0 with the changes
related to BlueNRG devices.

Signed-off-by: Ali Hozhabri <ali.hozhabri@st.com>
2024-02-16 13:34:18 -06:00
Alberto Escolar Piedras
2f8c58120e samples/modules/lvgl/demos: Increase heap for native 64 targets
For this targets, the widgets demo run out of heap and crashes.
Let's just increase the heap size.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-02-16 19:26:03 +01:00
Emil Gydesen
b374a423c4 Samples: Bluetooth: Fix PAST support for broadcast sink
Fix missing support for PAST in the broadcast audio sink
sample, where it previously failed to request PAST from
the broadcast assistant by not setting the PA state to
BT_BAP_PA_STATE_INFO_REQ.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-16 19:15:39 +01:00
Johann Fischer
66fee0a528 doc: usb: explain interface number and endpoint address assignment
This also applies to the new experimental device stack, but
documentation for it has not yet begun.

Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
2024-02-16 19:14:45 +01:00
Emil Gydesen
baaa149f10 Bluetooth: BAP: Fix bad bcast assistant bis sync shift
The shift is currently necessary due to a mismatch of the
specs and the API, but the shift should not be done when
the value is BT_BAP_BIS_SYNC_NO_PREF as that is a special value.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-16 19:14:27 +01:00
Emil Gydesen
acd1e891cb Bluetooth: BAP: UC: Fix call to bt_gatt_get_mtu in notify
In the unicast_client_ep_notify we would always call
bt_gatt_get_mtu, regardless of whether data == NULL.

When there is a disconnection, the notify callbacks are
called with data == NULL to indicate a unsubscription.
In the case of the unicast client, this would also trigger
calls to bt_gatt_get_mtu when there is a disconnect, which
in turn would trigger a warning that ATT is not connected.

Postponing the call to bt_gatt_get_mtu fixes this.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-02-16 19:13:48 +01:00
Jordan Yates
129b71260a doc: release-notes: zbus kconfig reference fixes
Fix usage of `:kconfig:option:` in the zbus release notes.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2024-02-16 19:07:03 +01:00