Commit Graph

67260 Commits

Author SHA1 Message Date
Andrei Emeltchenko b234ddc748 tests: ibecc: Fix IBECC tests
Fix IBECC tests moving common part to setup function.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2022-07-21 13:57:25 +00:00
Yinfang Wang 8a5bf765bc tests: subsys: edac: move ibecc to new ztest API
move ibecc to new ztest API.

Signed-off-by: Yinfang Wang <yinfang.wang@intel.com>
2022-07-21 13:57:25 +00:00
Yinfang Wang 6087bac296 tests: subsys: edac: move ibecc_cov to new ztest API
move ibecc_cov to new ztest API.

Signed-off-by: Yinfang Wang <yinfang.wang@intel.com>
2022-07-21 13:57:25 +00:00
Benjamin Björnsson 5ad251b8d2 samples: sensor: tmp116: Update sample to remove use of DT_INST
Simplify sample by removing usage of DT_INST.

Signed-off-by: Benjamin Björnsson <benjamin.bjornsson@gmail.com>
2022-07-21 08:28:29 -05:00
Krzysztof Chruscinski 75c6a9050a tests: logging: log_stack: Adjust thresholds
Adjust thresholds after updates in log_output.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2022-07-21 09:04:37 -04:00
Krzysztof Chruscinski a0e79710a0 tests: logging: log_output: Improve test coverage
Improve test coverage for log_output module.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2022-07-21 09:04:37 -04:00
Krzysztof Chruscinski 15fdee04e3 logging: log_output: Add function for processing input arguments
Add function which formats a logging string from input parameters
and not from logging message. This function is more flexible since
it does not require data to be placed in the log message.

Converted a function for message processing to used this new function
internally.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2022-07-21 09:04:37 -04:00
Krzysztof Chruscinski 63c071a713 tests: logging: log_stack: Adjust thresholds
Adjust threshold.

Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
2022-07-21 09:04:37 -04:00
Justin Huang cb5264162d logging: added log process thread priority support
Added Zephyr config items to support setting the priority of the log
process thread at build time.

Signed-off-by: Justin Huang <justinyhuang@fb.com>
2022-07-21 08:59:38 -04:00
Benjamin Björnsson 45adae9118 drivers: gpio: gpio_fxl6408: move driver to use i2c_dt_spec
Simplify driver by using i2c_dt_spec for bus access.

Signed-off-by: Benjamin Björnsson <benjamin.bjornsson@gmail.com>
2022-07-21 06:07:02 -05:00
Benjamin Björnsson 706949cf71 samples: drivers: espi: Convert to use DT_NODELABEL
Convert to use DT_NODELABEL to remove usage of DT_INST in sample.

Signed-off-by: Benjamin Björnsson <benjamin.bjornsson@gmail.com>
2022-07-21 06:06:02 -05:00
Henrik Brix Andersen bda6455234 drivers: eeprom: Update drivers to use devicetree Kconfig symbol
Update EEPROM drivers to use DT_HAS_<compat>_ENABLED Kconfig symbol
to expose the driver and enable it by default based on devicetree.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2022-07-21 06:03:04 -05:00
Henrik Brix Andersen 8746b2cb33 drivers: can: Update drivers to use devicetree Kconfig symbol
Update CAN drivers to use DT_HAS_<compat>_ENABLED Kconfig symbol to expose
the driver and enable it by default based on devicetree.

Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
2022-07-21 06:02:28 -05:00
Benjamin Björnsson 2bed3950c3 samples: drivers: ht16k33: Update sample to remove use of DT_INST
Simplify sample by removing usage of DT_INST.

Signed-off-by: Benjamin Björnsson <benjamin.bjornsson@gmail.com>
2022-07-21 05:31:57 -05:00
Simon Hein 02cfbfea51 kernel: comply to coding guidelines MISRA C:2012 Rule 14.4
MISRA C:2012 Rule 14.4 (The controlling expression of an if statement
and the controlling expression of an iteration-statement shall have
essentially Boolean type.)

Use `bool' instead of `int' to represent Boolean values.
Use `do { ... } while (false)' instead of `do { ... } while (0)'.
Use comparisons with zero instead of implicitly testing integers.

This commit is a subset of the original commit:
5d02614e34

Signed-off-by: Simon Hein <SHein@baumer.com>
2022-07-21 06:16:16 -04:00
Jaroslaw Stelter fe5ed68356 soc: ace_v1x: check physical memory bounds on page unmap.
This patch fix issue with unmapping of virtual addresses mapped
to non-existing physical memory. MTL TLB table is initialised with
1:1 mapping, however virtual space is much wider than available
physical space. We should not try to free and manage of power for
non-existing physical pages.

Signed-off-by: Jaroslaw Stelter <Jaroslaw.Stelter@intel.com>
2022-07-21 05:32:03 -04:00
Simon Hein c29d0a3c4f soc: arm: comply to coding guidelines MISRA C:2012 Rule 14.4
MISRA C:2012 Rule 14.4 (The controlling expression of an if statement
and the controlling expression of an iteration-statement shall have
essentially Boolean type.)

Use `do { ... } while (false)' instead of `do { ... } while (0)'.

This commit is a subset of the original commit:
5d02614e34

Signed-off-by: Simon Hein <SHein@baumer.com>
2022-07-21 10:31:00 +02:00
Simon Hein 93dfc69a3a boards: comply to coding guidelines MISRA C:2012 Rule 14.4
MISRA C:2012 Rule 14.4 (The controlling expression of an if statement
and the controlling expression of an iteration-statement shall have
essentially Boolean type.)

Use `do { ... } while (false)' instead of `do { ... } while (0)'.

This commit is a subset of the original commit:
5d02614e34

Signed-off-by: Simon Hein <SHein@baumer.com>
2022-07-21 10:31:00 +02:00
Kumar Gala 7d5215ff19 drivers: serial: Update drivers to use devicetree Kconfig symbol
Update serial drivers to use DT_HAS_<compat>_ENABLED Kconfig symbol
to expose the driver and enable it by default based on devicetree.

We remove 'depend on' Kconfig for symbols that would be implied by
the devicetree node existing.

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-07-21 10:29:06 +02:00
Ryan Erickson 3d7f267d4a modem: hl7800: Fix TCP server closed interrupting TX/RX
If TCP server closed notification is received it
could interrupt the TCP socket RX or TX data sequence.
Remove the SOCK_SERVER_CLOSED state and instead
use a unique error code to know if the socket
has been closed by the server.

Signed-off-by: Ryan Erickson <ryan.erickson@lairdconnect.com>
2022-07-21 10:28:38 +02:00
Anas Nashif 3f22a97c48 MAINTAINERS: add tests/dts to pinctrl area
Add more coverage for this area to catch changes to tests and DTS
bindings.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2022-07-20 16:06:21 -04:00
Benjamin Björnsson f5073e461e modules: segger: Update header to use guard macros
Remove usage of pragma once for consistency across all headers.

Signed-off-by: Benjamin Björnsson <benjamin.bjornsson@gmail.com>
2022-07-20 13:39:23 -05:00
Benjamin Björnsson 386487acd8 arch: xtensa: core: include: Update header to use guard macros
Remove usage of pragma once for consistency across all headers.

Signed-off-by: Benjamin Björnsson <benjamin.bjornsson@gmail.com>
2022-07-20 13:39:23 -05:00
Benjamin Björnsson 2399145406 include: zephyr: Add missing guard macro
Add guard macros to header files for consistency.

Signed-off-by: Benjamin Björnsson <benjamin.bjornsson@gmail.com>
2022-07-20 13:39:23 -05:00
Anas Nashif 554eb03cb9 kconfig: guard usbc logging macros
Logging kconfig options should only appear when this driver is being
used.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2022-07-20 18:28:43 +02:00
Anas Nashif 3133666c9a kconfig: guard grove lcd logging macros
Logging kconfig options for this lcd should appear when the hardware is
enabled.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2022-07-20 18:28:43 +02:00
Anas Nashif 7d799fdff0 kconfig: guard MPU logging macros
MPU logging Kconfigs should only appear when MPU is enabled.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2022-07-20 18:28:43 +02:00
Fabio Baltieri a5dfd6bd64 ci: doc-build: bump timeout up to 45m
Give documentation a bit more time to build, seems like we are hitting
the current 30 minutes limit.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2022-07-20 09:41:32 -05:00
Fabio Baltieri 56ab3a74e4 doc: drop few reference of -s west build flag
This has been removed in:

b710177a27 west: commands: build: Specify source dir without a flag

and hidden from the help, drop it from the documents to avoid confusion.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2022-07-20 09:41:32 -05:00
Fabio Baltieri 43e0a4678f boards: litex_vexriscv: fix duplicate doc title
The document title is repeated for some reason, causing it to be listed
twice in the board list. Drop one of the instances.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2022-07-20 09:41:32 -05:00
Fabio Baltieri dd24c61a4a samples: fix shell_module Kconfig menu name
Shell sample has the wrong mainmenu name, rename it one that makes
sense.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2022-07-20 09:41:32 -05:00
Kumar Gala 37b16e62ab tests: i2c: Remove label property from devicetree overlays
"label" properties are not required.  Remove them from tests.

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-07-20 09:31:17 -05:00
Daniel DeGrasse cb3d1313e5 drivers: lpuart: prevent spurious transmission complete interrupts
Correct issue where transmission complete interrupt was not disabled when
using interrupt driven serial API with power management enabled,
resulting in continuous spurious interrupts that effectively locked
the system.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2022-07-20 09:29:38 -05:00
Kumar Gala 60d3d49405 samples: boards: arc_secure_services: Remove empty prj.conf
We get the following error message from twister:

ERROR   - samples/boards/arc_secure_services/prj.conf:
          can't find: cannot mmap an empty file

Fix by removing the empty file.

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-07-20 09:29:11 -05:00
Simon Hein b5522fffbc arch: comply to coding guidelines MISRA C:2012 Rule 14.4
MISRA C:2012 Rule 14.4 (The controlling expression of an if statement
and the controlling expression of an iteration-statement shall have
essentially Boolean type.)

Use `do { ... } while (false)' instead of `do { ... } while (0)'.
Use comparisons with zero instead of implicitly testing integers.
Use comparisons with NULL instead of implicitly testing pointers.
Use comparisons with NUL instead of implicitly testing plain chars.

This commit is a subset of the original auditable-branch commit:
5d02614e34

Signed-off-by: Simon Hein <SHein@baumer.com>
2022-07-20 09:28:38 -05:00
Evgeniy Paltsev 1bc2cb7fd7 ARC: fix SMP race in ASM ARC interrupt handling code
In interrupt chandler code we don't save full current task context
on stack (we don't save callee regs) before z_get_next_switch_handle()
call, but we passing _current to it, so z_get_next_switch_handle
saves current task to switch_handle, which means that this CPU
current task can be picked by other CPU before we fully store it
context on this CPU.

Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
2022-07-20 09:26:24 -05:00
Kumar Gala b2f10ce0d0 dts: arc: Remove label property from devicetrees
Label properties are not required.

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-07-20 09:23:45 -05:00
Nikodem Kastelik 295e0e35b9 manifest: Update hal_nordic revision to use nrfx 2.9.0
Pull in new nrfx version that integrates MDK 8.47.0

Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
2022-07-20 14:07:29 +00:00
Pieter De Gendt d01934f9e9 drivers: sensor: bq274xx: convert lazy load Kconfig option to dts property
This change allows per-instance configuration of lazy loading and
fixes build issue.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2022-07-20 08:39:45 -05:00
Kumar Gala 16eb5a026f tests: counter: counter_basic_api: Rework test to use struct device
Move to pass 'struct device *' instead of a 'char *'.  This lets us move
from device_get_binding to DEVICE_DT_GET.

Reworked get_counter_period_us() to not be name based, but instead
we keep a list of devices that need a different period value to check
against.

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-07-20 08:32:04 -05:00
Kumar Gala d8dca94144 tests: counter_basic_api: refactor period handling
We do the same check for determining the period in a number of the
tests.  Refactor that code into get_counter_period_us().

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-07-20 08:32:04 -05:00
Kumar Gala 50cf6ca826 tests: led_api: Convert to use DEVICE_DT_GET
Move to use DEVICE_DT_GET instead of device_get_binding as
we work on phasing out use of DTS 'label' property.

Signed-off-by: Kumar Gala <galak@kernel.org>
2022-07-20 10:07:17 +00:00
Reto Schneider 75ea632ba1 fs: fcb: Define length padding bytes
Before this, on flashes with a write alignment greater than one, the
padding bytes had no defined value.

The effect of this non-deterministic code made it hard(er) to verify
data written by FCB.

Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
2022-07-20 11:09:29 +02:00
Ahmed Moheb e22d5bcb59 bluetooth: Fix bt_buf_get_rx() documentation
Edit the 'type' parameter description that describes the
allowed input values in order to match the implementation

Signed-off-by: Ahmed Moheb <ahmed.moheb@nordicsemi.no>
2022-07-20 11:09:16 +02:00
Tim Lin d7ccea6357 ITE: drivers/i2c: Add command queue mode not allowed condition
If the transaction of write or read is divided into two transfers
(not two messages), the command queue mode does not support.

Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
2022-07-20 11:08:56 +02:00
Thomas Stranger 0cb7a1edcd samples/drivers/dac: add overlay file for nucleo_u575zi_q
Add overlayfile for the dac sample to use dac1_out1 on pa4.

Signed-off-by: Thomas Stranger <thomas.stranger@outlook.com>
2022-07-20 11:08:42 +02:00
Thomas Stranger 9a6ba3f6bc tests/drivers/spi/spi_loopback: add overlay for nucleo_u575zi_q
SYSCLK frequency is 160MHz therefore w/o overlayfile the
slow frequency can only be reached with the divider added
by this commit in the overlay.

Signed-off-by: Thomas Stranger <thomas.stranger@outlook.com>
2022-07-20 11:08:42 +02:00
Thomas Stranger 570ce2410e boards: nucleo_u575zi_q enable additional peripheral nodes
This commit enables additional nodes and specifies pinctrl for:
lpuart1, usart2, i2c1, i2c2, spi1, dac1, and iwdg

- nodes added in board dts file.
- nodes are also added to docs in alphabethical order.
- additionally arduino_spi, arduino_i2c, and arduino_serial
  node labels are added.
- enable support for these peripherals in the board.yaml file.

noteworthy:
- the slected spi1 nss pin does not mach the arduino header,
  because the pin connected does not support hardware nss.
  pa4 is chosen instead.
- For the dac the pin pa4 is chosen because the there are only two
  potential pins, and it seems preferable to have a conflict with
  SPI1_NSS(pa4) than with SPI1_SCK(pa5).

Signed-off-by: Thomas Stranger <thomas.stranger@outlook.com>
2022-07-20 11:08:42 +02:00
Thomas Stranger 0ce1d4b091 boards: nucleo_u575zi_q add pyocd and jlink support
This commit adds jlink and pyocd as debuggers to the
nucleo_u575zi_q.

Signed-off-by: Thomas Stranger <thomas.stranger@outlook.com>
2022-07-20 11:08:42 +02:00
Aleksander Wasaznik 58c5e32e08 Bluetooth: Host: Disable host-based RPA resolution when !BT_PRIVACY
Change doc of CONFIG_BT_PRIVACY to explicitly say it's needed for both
generating and resolving RPAs.

Disable host-based RPA resolution in `bt_conn_le_create` when
!CONFIG_BT_PRIVACY.

Update doc of `bt_conn_le_create` to document that CONFIG_BT_PRIVACY is
a requirement for resolving RPAs. Also explictly say that this function
will resolve private identities. Also explain the expected effect of
Network Privacy on this function.

Reduce coupling to `bt_le_create_conn_ext` and
`bt_le_create_conn_legacy` in `bt_conn_le_create` by just use
`resp_addr` when it's set, instead of "knowing" when it had been set.
The alternative would be to also update `bt_le_create_conn_ext` and
`bt_le_create_conn_legacy` to have `(IS_ENABLED(CONFIG_BT_PRIVACY) &&
(!bt_dev.le.rl_size || bt_dev.le.rl_entries > bt_dev.le.rl_size))`

Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
2022-07-20 10:48:09 +02:00