Commit Graph

100685 Commits

Author SHA1 Message Date
Jimmy Zheng 91e524862d soc: common: riscv-privileged: add riscv_clic_irq_vector_set() for clic
Introduce riscv_clic_irq_vector_set() to implement z_riscv_irq_vector_set()
for CLIC. This commit also introduces CONFIG_CLIC_SMCLICSHV_EXT to indicate
support for the smclicshv extenion and riscv_clic_irq_vector_set().

Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
2024-08-26 17:05:53 +02:00
Jimmy Zheng 9ec596674b arch: riscv: add z_riscv_irq_vector_set() to set vector ISR
Introduce z_riscv_irq_vector_set() to hook into ARCH_IRQ_DIRECT_CONNECT(),
allowing users to set vector mode for a specified ISR.

Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
2024-08-26 17:05:53 +02:00
Jordan Yates 2f143fb2c1 doc: add `make html-live` and `html-live-fast`
Add two new commands that automatically locally host the generated
documentation upon completion and rebuild/rehost when the input files
change without any user interaction.

For more info see: https://pypi.org/project/sphinx-autobuild/

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-08-26 17:05:39 +02:00
Jordan Yates 2e99de8047 doc: conf.py: build directory from environment
Get the output directory from environment variables instead of
attempting to reparse the CLI arguments, as these can actually refer
to a program other than `sphinx-build` (for example `sphinx-autobuild`).

Signed-off-by: Jordan Yates <jordan@embeint.com>
2024-08-26 17:05:39 +02:00
Jamie McCrae 09a67ad678 doc: release: 4.0: Add note on new MCUmgr enum mgmt group
Adds a note about this new group

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-08-26 17:05:27 +02:00
Jamie McCrae edee1ed9a0 tests: mgmt: mcumgr: Add enum_mgmt test
Adds a test that checks the functionality of this new management
group

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-08-26 17:05:27 +02:00
Jamie McCrae 4f5c6da4e5 doc: mcumgr: Add documentation for SMP group 10 (enum)
Adds documentation for enumeration management group

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-08-26 17:05:27 +02:00
Jamie McCrae e577b140c3 mgmt: mcumgr: grp: Add names to groups when Kconfig is enabled
Adds string names to the groups in MCUmgr when the enum mgmt
Kconfig is enabled to support listing names of groups

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-08-26 17:05:27 +02:00
Jamie McCrae fc40e836d1 mgmt: mcumgr: grp: Add enumeration management group
Adds a new MCUmgr group which allows for listing which groups are
supported by the MCUmgr server by remote devices.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-08-26 17:05:27 +02:00
Jamie McCrae b28ccc207d mgmt: mcumgr: mgmt: Add group callback function
Adds a group callback function which can be used to iterate over
all the registered MCUmgr command groups

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-08-26 17:05:27 +02:00
Raffael Rostagno 3c19c85b32 drivers: clock_control: esp32c6: Fix for USB/JTAG port
Fixes non-working JTAG port when serial USB is not enabled.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-08-26 11:05:19 -04:00
Fabrice DJIATSA 9e4c554487 dts: arm: st: remove clock node from parent node soc
Since the clock node is not a child node of the soc node,
but from the root node.
This removes the warning log at compilation.


Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
2024-08-26 11:05:00 -04:00
Erwan Gouriou a078b4ee6b drivers: bluetooth: hci: Remove prompt on non user selectable symbols
Most of BT_FOO symbols that are designed to select the hci driver
implementation which will drive the comunication with controller are
selected based on device tree compatible and should not be made available
as an configurable option to the user.
To do this, remove the prompt on these symbols.

Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
2024-08-26 11:04:45 -04:00
Jilay Pandya f29377a12c mbedtls: remove stray uses of MBEDTLS_ZEPHYR_ENTROPY
This commit replaces stray uses of MBEDTLS_ZEPHYR_ENTROPY with
MBEDTLS_ENTROPY_POLL_ZEPHYR

Signed-off-by: Jilay Pandya <jilay.pandya@zeiss.com>
2024-08-25 11:21:26 +02:00
Jilay Pandya d08864c4b3 mbedtls: remove stray uses MBEDTLS_ENTROPY_ENABLED
This commit replaces stray uses of MBEDTLS_ENTROPY_ENABLED with
MBED_TLS_ENTROPY_C

Signed-off-by: Jilay Pandya <jilay.pandya@zeiss.com>
2024-08-25 11:21:26 +02:00
Marcin Niestroj 6b8ebeb9d1 samples: sockets: echo_server: test on native_sim/native/64
Add 64-bit platform to allowed, so it is tested by twister.

Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
2024-08-24 19:22:42 -05:00
Declan Snyder 5f541431d6 soc: imxrtxxx: Fix flexspi boot issue
FCB was being relocated to the wrong location, and the flexspi clock
setup was not being relocated.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-08-24 19:22:23 -05:00
Jyri Sarha 746ddccf54 intel_adsp: debug_window: Add slot type for debug-stream transport
Add slot type for debug-stream transport over a debug window slot. For
details see src/debug/debug_stream/debug_stream_slot.h under SOF
sources [1].

[1] https://github.com/thesofproject/sof

Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
2024-08-24 19:21:57 -05:00
Anas Nashif 376085c9ed tests: kernel: add missing test call argument
Add missing param argument.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-08-24 07:17:15 -04:00
Josuah Demangeon c0f8658254 drivers: video: accept VIDEO_EP_ALL where VIDEO_EP_IN/OUT is given
The current video drivers did not allow VIDEO_EP_ALL to be selected,
as used by video_stream_stop().

This adds the VIDEO_EP_ALL to each video driver that filtered endpoints.

Signed-off-by: Josuah Demangeon <me@josuah.net>
2024-08-24 07:17:03 -04:00
Josuah Demangeon 9eb258c7f6 drivers: video: allow to specify individual ep with ID >= 0
This define the enum values so that they never clash with custom
endpoint IDs passed numerically, for devices that supports more
than one IN or OUT enpoint.

This also documents semantics for VIDEO_EP_IN/OUT/ALL/NONE,
while renaming VIDEO_EP_ANY to VIDEO_EP_ALL to remove the
ambiguity when there are several IN and/or OUT endpoints.

Signed-off-by: Josuah Demangeon <me@josuah.net>
2024-08-24 07:17:03 -04:00
Valerio Setti f23d800094 test: mbedtls: new test for PSA crypto initialization and RNG configuration
Add a simple test to showcase how RNG can be configured on different
platforms in order to allow Mbed TLS's PSA crypto implementation to
work properly.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-08-24 07:16:51 -04:00
Valerio Setti e26f00fc5f mbedtls: move entropy polling functions to a dedicated file
This commit just moves some code around. For sake of cleanliness
a new file is added to hold the entropy parsing functions
for Mbed TLS.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-08-24 07:16:51 -04:00
Valerio Setti 5ef44fdd8c mbedtls: add new kconfig for non-CSPRNG sources in psa_generate_random()
This is meant to be used only for tests on platforms where CSPRNG
sources are not available. It should not be used in production.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-08-24 07:16:51 -04:00
Valerio Setti 6523fb3cb0 mbedtls: improve description of PSA random number generators
Improve the description of both MBEDTLS_PSA_CRYPTO_LEGACY_RNG and
MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG kconfig symbols.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-08-24 07:16:51 -04:00
Valerio Setti 98ddf107fa mbedtls: rename CONFIG_MBEDTLS_ZEPHYR_ENTROPY and move it
- Slightly improve the name of this kconfig adding the suffix
  _POLL in order to highlight that this adds a callback
  function used to poll data.

- Description was also updated to point out that this symbols
  might not only use the (secure) entropy driver, but also
  generic number generators, some of which are not really
  secure.

- The symbol was move from Kconfig to Kconfig.tls-generic because
  this is where MBEDTLS_ENTROPY_C is located and since
  MBEDTLS_ENTROPY_HARDWARE_ALT depends on the former (it only
  makes sense if the entropy module is also enabled), we add
  also the "depends on".

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-08-24 07:16:51 -04:00
Valerio Setti e3e13fb40b mbedtls: rename MBEDTLS_ENTROPY_ENABLED as MBEDTLS_ENTROPY_C
ENABLED suffix does not really makes much sense for a kconfig
so it should be removed. Also other MBEDTLS symbols were recently
updated accordingly.
Moreover having it named exactly the same way as in Mbed TLS
symplifies the understanding of what this kconfig is doing.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-08-24 07:16:51 -04:00
Daniel Leung 8d53b506a2 kernel: remove deprecated macro K_THREAD_STACK_MEMBER
Remove the macro K_THREAD_STACK_MEMBER that has been
deprecated since v3.5.0.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-24 07:16:38 -04:00
Simone Orru ad208e1e7c modules: mbedtls: Enable PEM writing when PEM cert format is selected
Enable the `MBEDTLS_PEM_WRITE_C` mbedtls configuration option when
`CONFIG_MBEDTLS_PEM_CERTIFICATE_FORMAT` is selected.

Signed-off-by: Simone Orru <simone.orru@secomind.com>
2024-08-24 07:16:25 -04:00
Lucien Zhao fd1c057f18 boards: nxp: mimxrt1180_evk: change to use hyperram as RAM region
Change to use hyperram as RAM region
Enable external mem kconfig

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-08-24 07:16:11 -04:00
Lucien Zhao 8077a74621 dts: arm: nxp: add ITCM/DTCM region into linker
add ITCM/DTCM region into linker file

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-08-24 07:16:11 -04:00
Lucien Zhao 1b90b46f75 soc: nxp: imxrt: support external memory hyperram
add xmcd data section to save xmcd data in linker.ld

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-08-24 07:16:11 -04:00
Anas Nashif 998f7546a8 doc: kernel: fix doxygen for K_FP_REGS
Move unrelated macro definition up to get doxygen docstring associated
with K_FP_REGS.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-08-24 07:15:58 -04:00
Sylvio Alves b7b03e5682 soc: esp32: kconfig: add unsupported revision config
ESP32 SoC has multiple revisions, some of which are not supported
by the current implementation, as such as REV0 and REV1. This PR
adds an option to indicate user that this is not recommended and not
supported.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2024-08-24 07:15:50 -04:00
Grzegorz Chwierut 892b25aece twister: tests: Add unit test for readline method in handler
Check if lines from serial are processed one by one
in case when was received in one buffer from redline method.

Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
2024-08-24 07:15:17 -04:00
Grzegorz Chwierut 79ef0b6b10 twister: scripts: Split lines before processing
Readline method sometimes receives more lines in buffer.
Split them to avoid misinterpreting data in harness module.

Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
2024-08-24 07:15:17 -04:00
Daniel Leung 8851891278 doc: clean ENABLED_SECTION option for doxygen
The ENABLED_SECTION option is not a YES/NO option but should
contain a list of section label to be processed. For example,
adding INTERNAL_HIDDEN will make doxygen to look through all
the blocks with "@cond INTERNAL_HIDDEN" and "@endcond". So
just remove the "YES" and leave it an empty list.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-24 07:15:07 -04:00
Daniel Leung dcfdea4aed net: net_pkt: move #ifdef to before doxygen block
This moves the #ifdef to enclose the associated doxygen block.
Or else the function prototype are ignored/skipped but doxygen
still processes the block, and it will apply the documentation
to the next function in the file... and it will complain about
parameters not being found.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-24 07:14:57 -04:00
Daniel Leung 2e0a185b72 sys/poweroff: remove extra doxygen group ending command
Remove the extra doxygen group ending command "@}".

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-24 07:14:57 -04:00
Daniel Leung b678fcc5c6 serial: fix doxygen tag typo
@briref -> @brief.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-24 07:14:57 -04:00
Daniel Leung e0de79b9a5 regulator: fix doxygen ref tag typo.
@reg -> @ref.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-24 07:14:57 -04:00
Daniel Leung 4c6033aac2 mbox: fix param typo in mbox_set_enabled_t
enables -> enabled.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-24 07:14:57 -04:00
Lucas Tamborrino 3c91c408a4 drivers: dma: esp32: Add psram support
Add support for external ram access in DMA.

Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
2024-08-24 07:14:48 -04:00
Georges Oates_Larsen a900d17660 net: shell: cm: Fix snprintf warnings on NEWLIBC
Building with NEWLIBC triggers warnings about
snprintf since stdio is no longer automatically
included by printk.h

This PR switches to using snprintk to avoid these
warnings.

Fixes #77330

Signed-off-by: Georges Oates_Larsen <georges.larsen@nordicsemi.no>
2024-08-24 07:14:32 -04:00
Patryk Biel 816708aa4d devicetree: Reduce LoRa SPI frequency to allow reliable communciation
The heltec_wireless_stick_lite_v3 board does not properly handle
receive operations when the SPI used to communicate with onboard SX1262 has
the clock frequency set too high. This causes radio recv operation to
almost always hang forever without any error, as the SX1262 module returns
0xFF00 value as the interrupt status which does not make any sense, thus
causing the LoRaWAN library to trigger RXTX timeout handler which in the
current SX1262 driver implementation is not privded. The issue occurs
almost always, sometimes allowing to receive few (3-5) tranmissions
correctly, then fail. The root of the problem is not known for sure, but it
is highly likely a board's limitation, though not confirmed by the
manufacturer.
The current SPI frequency was chosen arbitrarily based on the conducted
experiments where the 30 000 messages have been received continiously
without any problems (with 5s interval for each message).

Signed-off-by: Patryk Biel <pbiel7@gmail.com>
2024-08-24 07:14:10 -04:00
Yong Cong Sin 143b14bb4f shell: modules: kernel: print cpu_mask when available
Dump the `cpu_mask` of threads when available.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2024-08-23 15:51:01 +01:00
Sylvio Alves 2e95ac8fbe boards: dts: esp_rust: enable bluetooth peripheral
Adds BLE DTS entry to enable Bluetooth LE in esp_rust board.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2024-08-23 15:50:54 +01:00
Axel Le Bourhis 179c85aa06 tests: net: socket: udp: clear control data buffer before recvmsg
Currently, the test doesn't clear the control data buffer before
calling recvmsg. This leads to recvmsg being unable to add the new
control data, which corresponds to the current received data.
This commit aims to clear the control data buffer to match most use
cases, when the control data buffer is empty before calling recvmsg.

Signed-off-by: Axel Le Bourhis <axel.lebourhis@nxp.com>
2024-08-23 15:50:37 +01:00
Axel Le Bourhis 5d643f4b00 net: sockets: Update msg_controllen in recvmsg properly
According to recvmsg man page, msg_controllen should be set to the sum
of the length of all control messages in the buffer.
This is missing from the current recvmsg implementation.
This commit aims to fix this by updating msg_controllen each time control
data are added to the buffer.
This commit also fixes cases where the msg_controllen is cleared
incorrectly.

Fixes #77303

Signed-off-by: Axel Le Bourhis <axel.lebourhis@nxp.com>
2024-08-23 15:50:37 +01:00
Grzegorz Chwierut fcf17dd17e twister: pytest: Change the order or pytest-args
Use pytest-args parameters provided in command line after
parameters taken from yaml file. The last occurence is
considered by argparse, so parameters from command line
will be used.

Fixes: #77319

Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
2024-08-23 15:50:19 +01:00