Commit graph

60088 commits

Author SHA1 Message Date
Joakim Andersson 453fbe2593 manifest: Update psa-arch-tests with nordic platform build fixes.
Update psa-arch-tests to include build fixes for the nordic platform.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2022-02-01 11:31:36 +01:00
Joakim Andersson 743b0583fc Bluetooth: controller: Enable debug pins with TF-M enabled
Enable debug pins when TF-M has been enabled for the image.
This would otherwise produce an error message as the DEBUG_SETUP would
not have been defined for the non-secure image.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2022-02-01 11:31:36 +01:00
Joakim Andersson e4260ac03f boards: nrf53: Fix board pin MCU selection with TF-M enabled
Fix board pin MCU selection not working with TF-M enabled.
This fixed no log output from the network core when TF-M is enabled.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2022-02-01 11:31:36 +01:00
Joakim Andersson aef46a8e51 soc: nrf53: Add handling of secure-only code in init with TFM enabled
Add handling of secure-only code with TF-M enabled that can only be done
from secure processing environment.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2022-02-01 11:31:36 +01:00
Joakim Andersson 17f8932f16 modules: trusted-firmware-m: Use TF-M install headers as interface
Use the set of headers that the TF-M build system places in the
install output. Not all public header files are available in the
interface/include directory and the TF-M build system uses the install
mechanism of cmake to include additional headers based on platform
or configuration.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2022-02-01 11:31:36 +01:00
Joakim Andersson d8dd0ed912 drivers: clock_control: Remove unused header file
Remove unused header file nrf_gpio.h which is not used by the
clock control driver.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2022-02-01 11:31:36 +01:00
Andrzej Puzdrowski 48c0faba1f release-note: Record on removal of the flash write protection API
Added API removal record and ite_8xxx2 rework record.

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2022-02-01 10:46:28 +01:00
Andrzej Puzdrowski 23b6e51e73 drivers/flash: remove flash_write_protection API
This API was designed to be removed in Zephyr 2.8

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2022-02-01 10:46:28 +01:00
Andrzej Puzdrowski f3a61dfecc tests/subsys/fs/multi-fs: remove write_protection flash handler
Removed the write_protection handler from the test_ram_backend.
This change was made due to deprecation of the flash write-protection
API.

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2022-02-01 10:46:28 +01:00
Andrzej Puzdrowski bbe4f87d09 drivers/flash/flash_ite_i8xxx2: remove write_protection handler
The handler was reworked to internal function and it
is called from the erase and the write
procedures automatically now.

This change was made due to deprecation of the flash write-protection
API.

Explanation for so late removal:
Reworked callback was introduced despite that the API had been
already deprecated at the addition time.

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2022-02-01 10:46:28 +01:00
Andrzej Puzdrowski 3d0e7553af tests/subsys: CONFIG_TEST_FLASH_DRIVERS=y only for qemu_x86
CONFIG_TEST_FLASH_DRIVERS is dedicated for qemu_x86.
This patch moves it to per board project configuration.

Setting this property for each target will cause build
failures.

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2022-02-01 10:46:01 +01:00
Andrzej Głąbek aa3b86600d drivers: flash: nrf_qspi_nor: Fix setting of the base clock divider
On nRF53 Series SoCs, the highest SCK frequencies can only be achieved
when the HFCLK192M clock divider is changed from the default /4 setting.
Such change results in increased power consumption, so the divider needs
to be changed only for periods when it is actually necessary.
This commit modifies the driver behavior so that it changes the divider
only when a QSPI bus operation is performed.
However, when XIP accesses to the flash chip are also used, it may be
needed to keep the divider changed even when the driver is idle so that
the XIP access speed is not reduced, hence a custom API function that
allows forcing this is introduced for the driver.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2022-02-01 10:31:50 +01:00
Maureen Helm 20c1e1a800 doc: release: Add sensor release notes for v3.0.0
Documents significant changes to sensor drivers in the v3.0.0 release,
including new drivers added and existing drivers modified.

Signed-off-by: Maureen Helm <maureen.helm@intel.com>
2022-01-31 19:04:26 -05:00
Gerard Marull-Paretas 81d43510a4 doc: getting_started: linux: reference to the 3rd party compilers page
The documentation was talking about not using Zephyr's SDK, but
referenced back to the GSG where only Zephyr SDK is covered in detail.
Refer to the 3rd party compilers page, where relevant information can be
found.

Fixes #42272

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2022-01-31 18:40:26 -05:00
Henrik Brix Andersen fab291779a drivers: can: use @deprecated for deprecated API functions
Use the @deprecated Doxygen command for documenting alternatives to
deprecated CAN API functions and macros.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2022-01-31 14:42:54 -06:00
Erwan Gouriou 28d3397545 west.yml: Use fixed STM32Cube STM32WL for exti
STM32Cube LL API for EXTI was buggy and returned
the wrong gpio port as IRQ source.

Point to the fixed version.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2022-01-31 14:37:11 -06:00
Erwan Gouriou ad12eef3f6 boards: nucleo_wl55jc: Fix openocd configuration
'connect_assert_srst' is preventing openocd to
connect to the board in debug mode.

To enable debug, fix openocd configuration to propose
two configurations:
- Debug compatible (default)
- Sleep mode compatible (commented)

Sleep mode compatible configuration should be used
when flashing over board's stock firmware.
A note has been added in board documentation to detail
this.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2022-01-31 14:37:11 -06:00
Erwan Gouriou 6a6c47b619 tests/drivers: gpio_basic_api: Add overlay to test nucleo_wl55jc
Add and overlay to enable gpio api test on this board.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2022-01-31 14:37:11 -06:00
Gerard Marull-Paretas aa660bf7b3 tests: boards: intel_s1000_crb: fix k_sleep arguments
k_sleep was still called with integer arguments, however, an initialized
k_timeout_t is expected. Use K_MSEC for that.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2022-01-31 15:25:42 -05:00
Gerard Marull-Paretas 3a38359f12 boards: xtensa: intel_s1000_crb: enable gpio0
gpio0 is used by the tlv320dac310x reset-gpios, however, it was not
enabled. In general, UART and GPIO are enabled by default as they fall
into the category of minimal peripherals. An alternative solution would
be to add an overlay to the sample.

The intel_s1000_crb board sample was actually broken, however, it got
unnoticed because it uses device_get_binding(), meaning the error would
show up at runtime.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2022-01-31 15:25:42 -05:00
TOKITA Hiroshi 45995212ab boards: riscv: longan_nano: Add BOARD definition
Define missing definition BOARD_LONGAN_NANO to defconfig.
And cleaning up some verbose comments.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2022-01-31 14:23:45 -06:00
Arnaud Mouiche 2eae4a3b72 c++: fix missing extern "C" closing }
Fix a failure to compile a C++ file including "pm/device_runtime.h"
A quick grep on all .h shows that net/tftp.h also needs to be fixed.


Signed-off-by: Arnaud Mouiche <arnaud.mouiche@invoxia.com>
2022-01-31 14:00:03 -06:00
Mahesh Mahadevan c43620f7d4 west.yml: Update NXP HAL to get system files
Include system.c file in the build for
MXRT5XX& MXRT6XX. Fix for Issue#42171

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2022-01-31 13:36:41 -06:00
Vinayak Kariappa Chettimada b5ab2f1353 Bluetooth: Controller: Fix missing ISO data packet receive
Fix missing ISO Data packet received by Synchronized
Receiver due to incorrect check on sink handle that did
not permit handle value of 0.

Fixed function to get ISO stream context to check for
valid ISO sync context, i.e. not being terminated.

Regression introduced in commit 7c89f1fe9f ("Bluetooth:
controller: Support for separate ISO RX data path").

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-31 18:12:10 +01:00
Dominik Ermel 8a4c58618b mgmt/mcumgr/lib: Return error on bad SMP header
The changes smp_process_request_packet to return MGMT_ERR_ECORRUPT
in case when failed to read header.
This helps to recognize that there will not be any response sent
from mcumgr to the buffer given to smp_process_request_packet as
it has not been recognized as valid request.
It also removes redundant check on mgmt_streamer_init_reader which
always returns 0 (no failure) in Zephyr.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2022-01-31 17:22:03 +01:00
Robert Lubos f4a18e471b net: sockets: tls: Fix ZSOCK_POLLHUP detection
The previous approach to detect if the underlying transport was closed
(by checking the return value of `mbedtls_ssl_read()` was not right,
since the function call does not request any data - therefore 0 as a
return value is perfectly fine.

Instead, rely on the underlying transport ZSOCK_POLLHUP event - if it
reports that the connection ended, forward the event to the application.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2022-01-31 17:20:55 +01:00
Robert Lubos f8751629c7 net: sockets: Report ZSOCK_POLLHUP when socket is in EOF state
Report ZSOCK_POLLHUP event if peer closed the connection, and thus the
socket is in EOF state.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2022-01-31 17:20:55 +01:00
Andrzej Puzdrowski 7adee4dc23 test/subsys/storage/stream_flash: fix build size issue
This test uses SoC's flash from offset of 64 KB which might
overlap with executable for a target
(for instance nrf52840dk_nrf52840).
This patch moves this region to 128 KB which solves the issue.

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2022-01-31 16:49:43 +01:00
Dominik Ermel e83b074128 mgmg/mcumgr/lib: Image upload size no longer needs flash alignment
The mcumgr image upload uses buffed flash writes with use of stream
flash, which makes flash alignment check unneded.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2022-01-31 16:22:55 +01:00
Jordan Yates fdc25cd44c spi: nrfx_spi*: only run uninit if configured
Only run the `uninit` function if the SPI instance has previously been
configured. This stops an assertion in the HAL drivers from triggering
due to running `uninit` without a previous `init`.

Fixes #42299.

Signed-off-by: Jordan Yates <jordan.yates@data61.csiro.au>
2022-01-31 12:14:05 +01:00
Vinayak Kariappa Chettimada f759c813bb tests: Bluetooth: Fix missing Scan Max Data for Broadcast Audio test
Fix missing Kconfig value for Scan Max Data in the
Broadcast Audio test.

Regression in commit faa89c779c ("Bluetooth: Controller:
Fix Periodic Adv Report to scan max data length").

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-31 12:13:08 +01:00
Vinayak Kariappa Chettimada 3f37210cd6 Bluetooth: Controller: Fix parsing empty ADV_EXT_IND and ADV_SYNC_IND
Fix implementation to check for empty ADV_EXT_IND and
ADV_SYNC_IND PDUs, and not parse them incorrectly.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-31 12:13:08 +01:00
Enjia Mai b374dc6a7f boards: intel_adsp_cavs18: add test coverage
Increase the test coverage for intel_adsp_cavs18. To keep its
test coverage as the same as cavs15 and cavs25.

Currently only one test sutite failed , See #42157.
with #42158 expend the time of ringbuffer testing, it can reach
100% pass rate.

Signed-off-by: Enjia Mai <enjia.mai@intel.com>
2022-01-29 05:21:04 -05:00
Erwan Gouriou a053063178 doc/release-notes: V3.0: STM32 add-on
Update V3.0.0 release note with STM32 additions.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2022-01-28 19:15:31 -05:00
Erwan Gouriou fa16f8654a samples: lora: Add harnesses for execution with twister
Lora samples are missing harnesses and hence are reported
failed by default by twister.
Add required harnesses to be able to detect correct and faulty
test executions.

Fixes #42159

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2022-01-28 19:15:01 -05:00
Vinayak Kariappa Chettimada faa89c779c Bluetooth: Controller: Fix Periodic Adv Report to scan max data length
Fix implementation to limit Periodic Advertising data to a
configurable maximum length when generating HCI reports.

Bluetooth Test Specification defines Scan_Max_Data value
in IXIT. When HCI LE Periodic Advertising Report events are
generated by assembling the chain PDUs, the test cases
expect that if the data length is no more than
Scan_Max_Data, then at least once the IUT shall not
truncate the data in the advertising report.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-28 19:13:56 -05:00
Vinayak Kariappa Chettimada 93d6d1e114 Bluetooth: Controller: Minor fix isr_done context parameter passed
Remove redundant parameter pass of lll_aux to isr_done as
the auxiliary context use is always for scan context as the
parent.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-28 19:13:56 -05:00
Vinayak Kariappa Chettimada 1fe80ec62a Bluetooth: Controller: Minor refactor for consistent variable names
Minor refactor of auxiliary scanning implementation to use
consistent variable naming and assignment close to its
locality of reference.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-28 19:13:56 -05:00
Vinayak Kariappa Chettimada 3c1277b49d Bluetooth: Controller: Rename per_scan field to periodic
Rename per_scan field in scan context to periodic field to
avoid confusing with abbreviation for peripheral.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-28 19:13:56 -05:00
Vinayak Kariappa Chettimada 77e810e4b8 Bluetooth: Controller: Rename flag to sync_term to is_term
Rename the flag sync_term to is_term to be consistent with
other flags.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2022-01-28 19:13:56 -05:00
Sylvio Alves ef3ecbe596 uart: esp32: fix baudrate return value
HAL call function used to retrieve the configured baudrate
returns the real calculated value, which might not be exactly as
the configured. For baudrate of 115200, HAL api
returns 115201, which then causes uart_basic_api test
to fail. Instead of returning the calculated baudrate value,
returns the configured one.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2022-01-28 19:13:20 -05:00
Flavio Ceolin ae0297e8de github: Update github security page
Update supported versions on github security page.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2022-01-28 16:32:02 -05:00
David Leach 96599830cf samples: grove_display: Exclude ip_k66f from sample build
The ip_k66f doesn't have I2C_0 status set to OKAY so the build of
this sample generates warnings in the nightly build. Root problem
is that the groove display is not ported to the device tree so
there isn't a standard way of filtering on the display being
part of the platform.

fixes #41523

Signed-off-by: David Leach <david.leach@nxp.com>
2022-01-28 14:31:50 -06:00
Jeremy Wood 833d6c2315 drivers: can: m_can: fix reconfiguring bitrate
Set enable configuration change bit in can_mcan_set_timing() because
the NBTP register can only be changed if we're in init mode AND
configuration change bit is set, per MCU docs.

Signed-off-by: Jeremy Wood <jeremy@bcdevices.com>
2022-01-28 15:46:17 +01:00
Rubin Gerritsen 4e88c91964 Bluetooth: Host: Fix address and SID in the sync established cb
When the periodic advertiser list is used,
the address and SID may not be identical to those passed in by
the application.

Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
2022-01-28 15:42:25 +01:00
Piotr Mienkowski 1ed5ba7720 drivers: i2s_sam_ssc: fix cache coherency in dma_rx_callback
Invalidate the cache before the RX data block is passed to the DMA
engine and not after it is received. If the RX data block contains
dirty cache lines they can be flushed anytime, overwriting legitimate
data that have been prefilled by the DMA module.

Signed-off-by: Piotr Mienkowski <piotr.mienkowski@gmail.com>
2022-01-28 10:07:25 +01:00
Piotr Mienkowski a922fd1b2f drivers: qdec_sam: disable index signal
`qdec_sam` driver supports currently only position measurement and does
not support reading of the index signal. Unfortunately, the index
signal was internally enabled in the driver. If the pin to which the
index signal was connected was used by another driver it could lead to
a false detection of the signal change. Detection of the index signal
change resets the position measurement.

Signed-off-by: Piotr Mienkowski <piotr.mienkowski@gmail.com>
2022-01-28 10:07:06 +01:00
Erwan Gouriou d6f150e97b samples/compression/l4z: Increase min_ram
Increase minimum RAM requirements on this test as it appears
that 32 is too low and 40 is verified ok.

Fixes #42161

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2022-01-28 10:07:00 +01:00
Hake Huang ae4fd13433 hal: nxp: need remove hal layer sai_edma
zephyr does not use sai_edma driver as the dma framework is different

fixing: #42179

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
2022-01-28 10:06:53 +01:00
Hake Huang 496dd79fdb soc: rt1xxx: fix build errors
remove LOG_ERR in soc init

fixing: #42179

Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
2022-01-28 10:06:53 +01:00