Commit graph

106032 commits

Author SHA1 Message Date
Jilay Pandya
92fce644e5 drivers: stepper: tmc5041: fix cid issues
fix cid issues related to unchecked return values.

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
2024-11-26 10:37:27 +00:00
Chen Xingyu
de1643d8fb net: mqtt: Fix error of size_t formatting with PRIu16
This addresses the following warning building with `CONFIG_64BIT=y`:

    error: format '%hu' expects argument of type 'int', but argument X has
    type 'size_t' {aka 'long unsigned int'}

Signed-off-by: Chen Xingyu <hi@xingrz.me>
2024-11-26 10:37:20 +00:00
Ivan Iushkov
75fc0a0776 Bluetooth: Host: deprecate bt_le_set_auto_conn()
bt_le_set_auto_conn() function is not working as
expected. Also, it doesn't have any test coverage
and any usage in sample applications.
The function is deprecated
Fixes #81597

Signed-off-by: Ivan Iushkov <ivan.iushkov@nordicsemi.no>
2024-11-26 10:37:12 +00:00
Arkadiusz Balys
a53cb73587 boards: nordic: Rearrange ram0x regions.
The ram0x partitions seem to be not compliant with nRF54H20
architecture and it causes that in the application dts overlay file
it is difficult to extend cpuapp_ram0x_region without modifying
whole layout.

It is better to place cpurad_ram0x_region at the beginning at
2f010000 address and then cpuapp_ram0x_region right after that.
Thanks to that, if the application needs to have more than 256 kB
of RAM, in the application dts overlay file, a user can increase
cpuapp_ram0x_region size up to 2f0be000.

Signed-off-by: Arkadiusz Balys <arkadiusz.balys@nordicsemi.no>
2024-11-26 10:37:06 +00:00
Khoa Nguyen
6dd7e14942 boards: renesas: add missing properties for spi node
Add missing "pinctrl-names" and "status" properties for
the spi1 node in ek_ra8m1.dts to able to test spi_loopback
on ek_ra8m1

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2024-11-26 10:36:55 +00:00
Khoa Nguyen
0fd6c97f98 drivers: spi: Add condition check for close before open spi
Add condition check for close before open to prevent
invalid pointer access

Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2024-11-26 10:36:55 +00:00
Jamie McCrae
b4e9806462 boards: nordic: nrf9131ek: Remove PINCTRL
Removes PINCTRL setting which is not needed

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-11-26 10:36:39 +00:00
Pieter De Gendt
520deb32cb cmake: Remove deprecated global CSTD property
Remove the global CSTD property as it has been deprecated for 2 releases.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-11-26 10:36:33 +00:00
Pieter De Gendt
85b991af5a tests: bindesc: reading: Remove usage of deprecated global CSTD
Replace global CSTD property with kconfig options.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-11-26 10:36:33 +00:00
Krzysztof Chruściński
eae3891303 tests: drivers: uart: uart_elementary: Add runtime PM configuration
Add configuration that uses device runtime PM.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-11-26 10:36:21 +00:00
Krzysztof Chruściński
13ed9e4210 drivers: serial: nrfx_uarte: Fix runtime PM for interrupt driven API
TX part of interrupt driven API was not calling PM device runtime
API. Additionally, when txstopped occurred after poll out it was
not handled correctly.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-11-26 10:36:21 +00:00
Chaitanya Tata
60dbb6fa4f modules: hostap: Move Enterprise configs under Enterprise
These are only for Enterprise.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-11-26 10:36:11 +00:00
Chaitanya Tata
9e63357355 modules: hostap: TLS is only needed for Enterprise
Move TLS MbedTLS wrapper to Enterprise only.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-11-26 10:36:11 +00:00
Chaitanya Tata
6316e40053 modules: hostap: Fix indentation
Cmake uses spaces (2) as the indentation.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-11-26 10:36:11 +00:00
Marvin Ouma
9211abcde6 tests: posix: common: separate posix xsi system logging to standalone test
posix.common contains testsuites that can be separated into smaller
groups of tests. This change moves syslog into a singular
testsuite at tests/posix/xsi_system_logging app directory.

Signed-off-by: Marvin Ouma <pancakesdeath@protonmail.com>
2024-11-26 08:45:43 +01:00
Jordan Yates
91e006cb7c sensor: bme280: bme280_wait_until_ready timeout
Add a timeout to the `bme280_wait_until_ready` loop to ensure that we
never get stuck in this loop even if the bus enters an error condition.

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-11-26 08:45:29 +01:00
Anas Nashif
ba5330e2ac ci: twister: for correctness, rename DAILY -> WEEKLY
We run on a weekly basis, not daily.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-11-26 08:45:16 +01:00
Anas Nashif
088670d605 ci: twister: report filter suites in weekly run
For analysis purposes, report filtered in weekly run.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-11-26 08:45:16 +01:00
Pieter De Gendt
43b112a309 scripts: west_commands: runners: Fix jlink unbound cmd
Commit e2a32d8b0ca596afeae48739c43817f693720a88 introduced an unbound
cmd issue for jlink flashing.

Fixed by moving cmd assignment outside of condition.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-11-26 08:45:06 +01:00
Anas Nashif
f90ce01d4a kernel: sched: use arch_current_thread instead of _current
_current is deprecated, use arch_current_thread()
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-11-25 19:06:57 -05:00
Valerio Setti
95aaa97dc3 mbedtls: add Kconfig to select the number of key slot in PSA Crypto core
Adding new CONFIG_MBEDTLS_PSA_KEY_SLOT_COUNT to select the number
of key slots in PSA Crypto core. The default value is 16. Be aware
that key slots consume RAM memory even if unused, so the proper value
should be a compromise between the number of slots required by
the application and the available RAM in the system.

This commit also:
- updates tests/crypto/secp256r1/mbedtls.conf to showcase how to
  use this new symbol to reduce RAM footprint.
- tests/bsim/bluetooth/mesh/overlay_psa.conf to support all the
  keys used in the test.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-11-26 00:12:56 +01:00
Valerio Setti
2f6ea8ed77 mbedtls: add Kconfig symbol CONFIG_MBEDTLS_PSA_STATIC_KEY_SLOTS
Adding the Kconfig symbol CONFIG_MBEDTLS_PSA_STATIC_KEY_SLOTS
to allow Mbed TLS's PSA Crypto core to use static key buffers
to store key's material. This helps reducing heap memory
usage and, potentially, it also discard code implementing
heap memory management if there's no other module in the build
that makes use of it.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-11-26 00:12:56 +01:00
Valerio Setti
f0944a2b4d manifest: mbedtls: include patch for static key slots
Update the Mbed TLS revision so as to take in a patch which
allows to use static key slot buffers for the PSA Crypto core
instead of dynamic (i.e. heap based) ones.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-11-26 00:12:56 +01:00
Lucas Tamborrino
cdbd2b5558 soc: espressif: Add hardware initialization
Bring hardware initialization to zephyr code base.

Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
2024-11-26 00:12:45 +01:00
Emil Dahl Juhl
2df905dc2c samples: led: lp5569: demo write_channels
Add a simple demonstration of the led_write_channels api on the lp5569
driver sample.
The demonstration simply turns on all of the channels with a single call to
led_write_channels. Then the same is done for turning off the channels.
Thus, it doesn't add much visually, but it shows the usage of the api.

Signed-off-by: Emil Dahl Juhl <emdj@bang-olufsen.dk>
2024-11-26 00:12:37 +01:00
Emil Dahl Juhl
d6ac9e8424 drivers: led: lp5569: implement write_channels api
The lp5569 has multiple pwm outputs, and thus implementing the
write_channels api to set multiple values in a single call makes sense.

Implement the write_channels function with a basic range check on the
channel range.
Since the lp5569 supports auto-increment, all of the channels can be
written in one i2c transfer, starting from the pwm register of the
start_channel.

Signed-off-by: Emil Dahl Juhl <emdj@bang-olufsen.dk>
2024-11-26 00:12:37 +01:00
Emil Dahl Juhl
45744b436f drivers: led: lp5569: enable auto-increment
The lp5569 controller supports auto-increment for its registers. This is by
default enabled in the chip, but the driver actively disabled it.

Since auto-increment is useful for writing multiple consecutive registers,
enable the feature. The driver, however, doesn't perform such consecutive
writes and thus the existing behavior is not altered.

Signed-off-by: Emil Dahl Juhl <emdj@bang-olufsen.dk>
2024-11-26 00:12:37 +01:00
Andy Ross
b3ff9ae82b kernel/sched: Optimize handling for suspend(_current)
k_thread_suspend() is an async API intended to stop any thread in any
state from any context.  Some apps just want to use it to "suspend
myself", which is a much (!) simpler operation.  Detect that specific
usage as a performance case.

Signed-off-by: Andy Ross <andyross@google.com>
2024-11-26 00:12:28 +01:00
Daniel Leung
22de29e768 soc: intel_adsp/ace: put syscall helpers in vector code section
This puts the syscall helpers into the vector code section, and
is a tiny TLB optimization. Before this, worst case scenario is
that there would 2 instruction TLB misses when both the syscall
helpers and the vector code pages are not in TLB cache. With
this change, there would be at most 1 instruction TLB miss as
now the syscall helper and the vector code (which includes
exception handling code and xtensa_do_syscall()) are now in
the same page, and the same TLB entry.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-11-26 00:12:18 +01:00
Anas Nashif
b207035851 tests: add integration_platforms and misc optimizations
Add integration_platforms to many tests that use platform_allow to
manage scope of pull_request CI.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-11-26 00:12:07 +01:00
Winston Arrocena
51708a760f boards: st: dts: fix slot0_partition address error
The B_L4S5I_IOT01A Discovery kit does not boot up when using --sysbuild.
The error is caused by slot0_partition which is assigned an address of
0x1000 which overlaps with the boot_partition. Setting the address to
0x10000 fixed it.

Signed-off-by: Winston Arrocena <we.arrocena@gmail.com>
2024-11-26 00:11:54 +01:00
Fin Maaß
1e3b106435 drivers: ethernet: phy_mii rename functions
rename internal reg_* functions.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2024-11-26 00:11:43 +01:00
Martin Åberg
b88d0bf8c7 soc: Enable SVT on GR716A by default
GR716A has limited instruction memory capacity. Enabling SVT
saves 3.5 KiB.

Signed-off-by: Martin Åberg <martin.aberg@gaisler.com>
2024-11-25 21:53:55 +01:00
Martin Åberg
fbd9dd4526 SPARC: Add support for single-vector trapping (SVT)
This adds support for the single-vector trapping (SVT) model, defined by
SPARC-V8 Embedded (V8E) Architecture Specification. SVT is available in
most LEON processors.

With single-vector trapping enabled, all traps are vectored through a
single trap vector (TBR.A) rather than one 16-byte entry for each trap
type. This improves memory utilization because the full 4 KiB trap table
is not needed.

This implementation uses a two-level of lookup table to find the handler
for the trap type (0..255).
- Execution time is constant.
- Condition flags are preserved.
- The implementation footprint is 60 bytes .text and 284 bytes .rodata.
  For comparison, a non-SVT table is always 4096 .text.

Signed-off-by: Martin Åberg <martin.aberg@gaisler.com>
2024-11-25 21:53:55 +01:00
Jean-Christophe Pince
dd5874b924 jlink: custom flashing support
Allows to use a custom flashing script with jlink runners.

Signed-off-by: Jean-Christophe Pince <jean.christophe.pince@qorvo.com>
2024-11-25 21:53:43 +01:00
Andries Kruithof
bb3bab7a34 Bluetooth: Audio: implement the distribute broadcast code procedure
Implemenation of the distribute broadcast code CAP procedure, as well
as unittesting

Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
2024-11-25 21:52:53 +01:00
Ian Morris
37fcadc6b3 boards: renesas: da14695_dk_usb: added mikrobus node labels
Added mikrobus_header, mikrobus_i2c, mikrobus_spi and mikrobus_serial
node labels to da14695_dk_usb device tree board definition, allowing
compatible shield boards to be used. Also fixed minor issues with
pin assignment and header labelling.

Signed-off-by: Ian Morris <ian.d.morris@outlook.com>
2024-11-25 21:52:34 +01:00
Emil Gydesen
322b177549 samples: Bluetooth: Reduce heap for hci_ipc
Reducing the heap requirement for the hci_ipc sample from
8KiB to 4KiB. It has been tested in various configurations to
work with 2300, but 4KiB was used to provide some leeway for
future updates.

The heap requirement is not documented, and it is unclear why
values lower than 2300 (not exact number) won't boot, and should
be investigated further.

Memory has become a very scarce resource for especially the ISO
builds for the nRF5340, which is why this is getting reduced.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2024-11-25 21:52:15 +01:00
Kai Vehmanen
a14ae39e74 driver: ssp: remove use of out-of-tree CONFIG_INTEL_MN
The SSP driver has odd dependency to outside definition of
CONFIG_INTEL_NM. This is in practise tied to SSP hardware
version and always enabled for SSP block version 1.0.

Use the new SSP_IP_VER define to replace the CONFIG_INTEL_MN
preprocssor checks. Also modify the board test case to
remove the obsolete config setting.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2024-11-25 21:51:56 +01:00
Anas Nashif
5b29fff725 tests: workqueue: avoid filters
Use Kconfig to configure watchdog instead of using expensive filters.

Also disable CONFIG_TEST_HW_STACK_PROTECTION for this test so we do not
have to create special cases.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-11-25 21:51:36 +01:00
Anas Nashif
a8b788d344 tests: mem_map: reduce runtime filters
Improve CI performance improving filtering and coverage selection.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-11-25 21:51:36 +01:00
Matthias Alleman
e7c353bf14 posix: fpu: Fix compiler error when enabling fpu on posix boards
Enabling CONFIG_FPU and CONFIG_FPU_SHARING requires the
definition of `arch_float_disable` and `arch_float_enable`.

Signed-off-by: Matthias Alleman <matthias.alleman@basalte.be>
2024-11-25 21:50:58 +01:00
Ahmed Zamouche
305ceba920 drivers: eth: enc28j60: Misc fixes
- Bank select mask should be 0x03:

| b7    | b6    | b5    | b4     | b3    | b2   | b1     | b0     |
|------:|------:|------:|-------:|------:|-----:|-------:|-------:|
| TXRST | RXRST | DMAST | CSUMEN | TXRTS | RXEN | BSEL1  | BSEL0  |

See  **REGISTER 3-1: ECON1: ETHERNET CONTROL REGISTER 1**

- ENC28J60_BIT_PHCON2_HDLDIS should be 0x0100

|b15| b14   |b13   |b12|b11|b10    |b9|b8     |b7|b6|b5|b4|b3|b2|b1|b0|
|--:|------:|-----:|--:|--:|------:|-:|------:|-:|-:|-:|-:|-:|-:|-:|-:|
| - |FRCLNK |TXDIS |r  |r  |JABBER |r |HDLDIS |r |r |r |r |r |r |r |r |

see **REGISTER 6-5: PHCON2: PHY CONTROL REGISTER 2**

- remove duplicate definitions

ENC28J60Data Sheet:
https://ww1.microchip.com/downloads/en/DeviceDoc/39662c.pdf

Signed-off-by: Ahmed Zamouche <ahmed.zamouche1@assaabloy.com>
2024-11-25 17:43:57 +01:00
Jerzy Kasenberg
1d4b1ade43 tests: drivers: spi: Fix nrf52840 overlay
spi-max-frequency was missing in overlay

Now it's set to 8 MHz as per datasheet

Signed-off-by: Jerzy Kasenberg <jerzy.kasenberg@codecoup.pl>
2024-11-25 17:43:48 +01:00
Jerzy Kasenberg
75d3f45d5a tests: drivers: spi: spi_slave: Fix memory corruption
This fixes memory corruption of delayable work when
tests executes unsupported function.

When test (e.g. only_rx_in_chunks) is executed it starts
delayed work for master functionality (with 10 ms delay).
Later when slave function is tried and reports that
function is unsupported, test is terminated (task ends)
but work is still scheduled.

When next test starts it clears work that is already
scheduled:

static void before(void *not_used)
{
	ARG_UNUSED(not_used);

	memset(&tdata, 0, sizeof(tdata));

this leads to memory corruption and system work queue
tries to remove work but it never does since head/next
pointers are zeroed at that time.

This just adds after function that cancels work
regardless if it was scheduled or not.

Signed-off-by: Jerzy Kasenberg <jerzy.kasenberg@codecoup.pl>
2024-11-25 17:43:48 +01:00
Alvis Sun
c9a95ddbdd drivers: i3c: npcx: add npcx i3c target driver
As title.

Signed-off-by: Alvis Sun <yfsun@nuvoton.com>
2024-11-25 17:43:41 +01:00
Alvis Sun
9976f8a8a9 dts: i3c: npcx: add target mode property and port configuration
As title.

Signed-off-by: Alvis Sun <yfsun@nuvoton.com>
2024-11-25 17:43:41 +01:00
Alvis Sun
f517929a11 include: i3c: npcx: remove unnecessary soc functions.
As title.

Signed-off-by: Alvis Sun <yfsun@nuvoton.com>
2024-11-25 17:43:41 +01:00
Alvis Sun
bb03d1a472 include: i3c: target_device: add target driver buffer mode
As title.

Signed-off-by: Alvis Sun <yfsun@nuvoton.com>
2024-11-25 17:43:41 +01:00
Chaitanya Tata
e512151474 manifest: hal_nordic: Pull nRF Wi-Fi removal
Pulls PR that removed nRF Wi-Fi.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2024-11-25 17:43:34 +01:00