Commit graph

5033 commits

Author SHA1 Message Date
Stephanos Ioannidis a3a844d33f doc: Update to Zephyr SDK 0.16.1
This commit updates the Getting Started Guide and the Zephyr SDK
documentation to point to the Zephyr SDK 0.16.1 release.

Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
2023-05-16 01:50:00 +09:00
Jamie McCrae c54b71d3b0 doc: release: 3.4: Add note on MCUmgr SMP transport changes
Adds a note that transports now need to set up the struct
themselves prior to calling the registration function.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-05-15 10:23:35 +02:00
Jamie McCrae 0e1a1f4899 doc: release: 3.4: Add note on new SMP MCUmgr protocol version
Adds a note on the new version of the SMP MCUmgr protocol.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-05-15 09:27:16 +02:00
Jamie McCrae 794f3df08e doc: services: device_mgmt: Add version field
Adds the SMP version field to the diagram and description.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-05-15 09:27:16 +02:00
Grant Ramsay 4ed404a27f drivers: virtualization: Add interface for ivshmem-v2
ivshmem-v2 is primarily used for IPC in the Jailhouse hypervisor

Signed-off-by: Grant Ramsay <gramsay@enphaseenergy.com>
2023-05-14 18:17:33 -04:00
Fabio Baltieri eec4b2336c doc: drop the topic branch references from the contribution guideline
Topic branches are not in widespread use and the details on how are
managed are being reworked.

Drop the topic branches reference (now being renamed "collab" branches)
from the contribution guideline and just ask to open PRs against main,
as that's the common case right now, saves first time users from having
to dig through the various branches in the repository.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2023-05-12 09:59:56 +02:00
Robert Lubos ff0fd2d7a7 net: iface: Improve thread safety of net_if_ipv*_maddr_* functions
Provide an extra struct net_if * iface parameter to
net_if_ipv*_maddr_join/leave functions, so that the corresponding
interface context, the mcast address belong to, can be locked for the
operation.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2023-05-10 11:06:15 +02:00
Jamie McCrae bb0a85ae4b doc: services: device_mgmt: smp_groups: img_mgmt: Add sha has note
Adds a note on when the "sha" hash field can be provided or not
and what the difference in operation is.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-05-09 14:29:05 +02:00
Andrzej Głąbek 0b573a1f38 drivers: spi_flash_at45: Fix erasing of first two sectors
Most available AT45 flash chips have their first two sectors shorter
than the consecutive ones. Usually, the first sector is marked as 0a
and has its size equal to eight pages (one block) and the second one
(usually 0b) is the complement to the size of a regular sector.
This commits modifies the driver so that erasing of these first two
sectors is performed correctly. This modified behavior is configurable
with a new DT property so that it is still possible to also use legacy
AT45 chips that do not feature such sector split. Such legacy chips
usually also do not support the chip erase and sector erase commands,
so two more DT properties are introduced to cover that.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2023-05-09 12:22:15 +02:00
Keith Packard 9b90f2a351 libc/picolibc: Switch to common malloc implementation
Enable the common malloc implementation when using picolibc. Support
existing Picolibc configurations by respecting existing PICOLIBC_HEAP_SIZE
settings.

When PICOLIBC_HEAP_SIZE is set to a value other than -2, then
*always* set COMMON_LIBC_MALLOC_ARENA_SIZE to that value.

Signed-off-by: Keith Packard <keithp@keithp.com>
2023-05-09 01:29:16 +09:00
Manoel Brunnen f0e054634f doc: ztest: Use directives for ZTEST_SHUFFLE
ZTEST_SHUFFLE is a Kconfig, so the appropriate directive should be used.

Signed-off-by: Manoel Brunnen <mb@lee-brunnen.de>
2023-05-08 09:59:05 +02:00
Manoel Brunnen dbbcfa6749 doc: ztest: Fix broken link
Fix for #55450

Signed-off-by: Manoel Brunnen <mb@lee-brunnen.de>
2023-05-08 09:59:05 +02:00
Pavel Vasilyev 177e9b93bf Bluetooth: Mesh: Add API to store model's user data in settings work
Mesh models may have a data that needs to be stored persistently.
Currently, the models should call bt_mesh_model_data_store and the store
will happen in the calling context. Most likely that it will be called
in BT RX thread as this is the context from which model's opcodes
handlers are called. Thus, the thread will be blocked until the store is
finished.

Another issues is that some models may have states that changes
frequently. Triggering the store on every state change may wear out
flash. Therefore, the models need to implement some postpone mechanism
to reduce the flash wear out.

The mesh stack has already implemented the mechanism of deferred store
with its own settings. The models could use it instead of implementing
their own mechanism.

In combination with the mesh settings workqueue, the models can store
their data without blocking the stack work.

Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
2023-05-08 09:58:21 +02:00
Pavel Vasilyev e33a4ace0f Bluetooth: Mesh: Use separate workq for storing mesh settings
Currently mesh settings are stored in the system workqueue context.
Most of other stack functionality, such that advertisements (incl
relay), loopback, transport sar, beacons transmission, etc. is also
processed in the system workqueue context. When a massive amount of
data needs to be stored and in particularly when page erase needs to
be triggered by GC of NVS subsystem to allocate flash pages, the
execution of the stack (and other functionality that uses the system
workqueue) will be blocked until storing is finished. For example,
right after the provisioning of a erased device, a node may not be
responsive for up to 400ms before it can continue sending messages.
The waiting time may increase if there is a GATT connection in the
mean time.

When write or erase operation is triggered, the flash driver waits for
Bluetooth controller to allocate a time needed to perform the operation.
During the whole operation, the context from which the operation was
triggered is put to sleep. This allows other threads to run until
Bluetooth controller finds the time for the flash driver. In other words,
every settings_save_one or settings_delete should be considered as
rescheduling points.

Considering this, Bluetooth mesh can use another thread to store its
settings, thus releasing the system workqueue for other tasks including
the operation of the stack itself.

The consistency of the data to be stored is guaranteed by the current
implementation where the data is copied to another struct before calling
settings_save_one. The pending flag of a particular module is dropped in
settings.c before starting to store the corresponding data. Thus, if
during the sleep the node receives a message that triggers a change in a
module which data is currently being stored, the pending flag will be
restored and the new change will be stored eventually.

Having this option enabled including with the partial erase, will make
the node more responsive in the described situations.

Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
2023-05-08 09:58:21 +02:00
Keith Short a6af1dd43d docs: bc12: Update for charging mode operation
Add details for using charging mode and add the BC1.2 emulator API
information to the document.

Signed-off-by: Keith Short <keithshort@google.com>
2023-05-08 09:57:56 +02:00
Martí Bolívar b6425b913a doc: dts: adjust CONFIG_COMPILER_TRACK_MACRO_EXPANSION text
Rework to address some grammar issues and typos in the original.

Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no>
2023-05-05 12:19:36 -07:00
Yuval Peress d162bdb202 bbram: Add documentation
- Add doxygen group and improve documentation for bbram.h
- Add a bbram section under peripherals in the main doc/ directory

Fixes #55257

Signed-off-by: Yuval Peress <peress@google.com>
2023-05-05 10:57:01 -05:00
Gerard Marull-Paretas d45946c65d doc: build: dts: add CONFIG_COMPILER_TRACK_MACRO_EXPANSION
When debugging devicetree related issues, it may be useful to turn macro
expansion tracking off. Let's document this in the troubleshooting
section.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2023-05-05 12:08:48 +02:00
Maurits Fassaert 11863028c1 storage: updated release notes for flash_map list labels
The new CONFIG_FLASH_MAP_LABELS and its effect is described.

Signed-off-by: Maurits Fassaert <maurits.fassaert@sensorfy.ai>
2023-05-05 10:02:19 +02:00
Laczen JMS d496a17bb6 flash_simulator: add ability to use memory region
Add the ability for the flash simulator to store its contents in a
memory region.

This allows filesystems on the flash simulator to survive a reboot.
And allows subsystems (e.g. coredump) to store their info on ram while
using the (existing) flash partition backend.

Add a example (for nucleo_f411re) that shows how to configure the flash
simulator for hardware (cfg discussion #54166).

Signed-off-by: Laczen JMS <laczenjms@gmail.com>
2023-05-04 20:49:57 +02:00
Jamie McCrae 2b9370597d doc: sysbuild: Improve documentation for targets
Adds information on targets that can be used from sysbuild.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-05-03 14:26:04 +02:00
Jamie McCrae 9a5e9e412f doc: release: 3.4: Add note on build system changes.
Adds a note that *_ROOT variables are now supported properly on an
image basis when using sysbuild, and that sysbuild_cache_set has
been added, and that zephyr_get has had a MERGE option added.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-05-03 14:25:33 +02:00
Yasushi SHOJI 143dfda9d0 doc: services: storage: flash_map: Fix include references
We have moved all header files under include/zephyr/ for Zephyr 3.1.
Update the document accordingly.

Signed-off-by: Yasushi SHOJI <yashi@spacecubics.com>
2023-05-03 12:39:49 +02:00
Peter Mitsis 2adfa3e1ae doc: Update FIFO and LIFO documentation
Updates the FIFO and LIFO documentation to clarify behavior
surrounding re-adding data items to queues.

Fixes #56336

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2023-05-02 04:43:08 -04:00
Emil Obalski e1d7b0a0ca doc: ipc: Update the documentation
Update the doc for IPC service icmsg backend.

Signed-off-by: Emil Obalski <Emil.Obalski@nordicsemi.no>
2023-04-29 12:24:17 +02:00
Stine Åkredalen 80158c1428 doc: Bluetooth: Mesh: update proxy solicitation docs
Updated related docs. Small fix in mesh/Kconfig and shell.rst.

Signed-off-by: Stine Åkredalen <stine.akredalen@nordicsemi.no>
2023-04-28 20:37:45 +02:00
Sam Hurst 714eec8496 doc: Document the USB-C Source Subsystem
Documents the USB-C Source Subsystem API.

Signed-off-by: Sam Hurst <sbh1187@gmail.com>
2023-04-28 10:06:01 +02:00
Keith Packard a9c62caab7 lib/libc: Move malloc from minimal to common library
This will (eventually) permit use of a common malloc implementation with
other C libraries, reducing the amount of Zephyr-specific code required
to support each C library.

Signed-off-by: Keith Packard <keithp@keithp.com>
2023-04-27 20:17:24 +09:00
Keith Packard 22320db5f7 doc/develop: Document common C library APIs
Right now, there's only 'time', which makes this doc pretty short.

Signed-off-by: Keith Packard <keithp@keithp.com>
2023-04-27 20:17:24 +09:00
Martí Bolívar c625a0e7a8 doc: dts: add help for undefined reference to __device_dts_ord_N
This is an FAQ and we don't have a satisfactory page that describes
the current state of the world for how to troubleshoot. This leads
to frustrated users and duplicated support efforts. Try to improve
this by at least writing down what people have to do today.

If we ever improve the situation by adding a machine-readable map
between drivers, Kconfig options, and DT compatibles, we can hopefully
do better than this, but at least it's a start.

Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no>
2023-04-26 12:53:48 +02:00
Declan Snyder ef697e5c4f doc: release 3.4: update doc for LPADC DT change
Update 3.4 release notes to bring awareness to the
shifted values of voltage-ref and power-level
properties of the LPADC node

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2023-04-25 19:59:23 +02:00
Vinayak Kariappa Chettimada 4fab10d0a1 doc: connectivity: Bluetooth: Controller SoC peripheral usage
Document the Controller SoC peripheral requirements for
Nordic Semiconductor SoCs.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2023-04-25 12:13:19 +02:00
Vinayak Kariappa Chettimada 7d81692fd9 doc: connectivity: Bluetooth: Add initial Controller sections
Add initial Controller architecture and design sections.
These are images contributed by Zephyr member companies and
collected over the various Face-to-Face meetings we have
been hold in the past years of Bluetooth Low Energy
Controller implementation.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2023-04-25 12:13:19 +02:00
Gerard Marull-Paretas d2917610a5 doc: release-notes: inform about SPI CS changes
Inform about the cs field change in struct spi_config. Also mention what
drivers must use from now on.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
2023-04-24 21:29:55 +02:00
Pawel Osypiuk 4b7f156403 IPC: rpmsg: Changed method of checking bounded endpoints
Initially that was checked by presence of name and now is changed
to check the flag.

Signed-off-by: Pawel Osypiuk <pawelosyp@gmail.com>
2023-04-24 15:45:09 +02:00
Daniel Mangum 63e7f106ea docs(build): fix typo of in CONFIG_GEN_ISR_TABLES description
Fixes misspelling of `scans` in the description of `CONFIG_GEN_ISR_TABLES`
in the build system documentation.

Signed-off-by: Daniel Mangum <georgedanielmangum@gmail.com>
2023-04-24 13:36:28 +02:00
Nicolas VINCENT 84a7feab45 doc: flash_map: add const to code snippet
flash_area_open() uses an argument of type 'const struct flash_area **'
while the code snippet suggested 'struct flash_area **'
Update code snippet

Signed-off-by: Nicolas VINCENT <nicolas.vincent@vossloh.com>
2023-04-24 13:35:07 +02:00
Sihyun Noh 7d730ff0a7 doc: releases: Update File systems
Added updates to the file system.

Signed-off-by: Sihyun Noh <awake_noh@naver.com>
2023-04-24 13:34:37 +02:00
Jamie McCrae 20e142cb34 doc: release: 3.4: Add retention subsystem and boot mode entries
Adds details on the newly introduced retention subsystem and boot
mode APIs to the release notes.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-04-24 13:27:53 +02:00
Jamie McCrae 9c6e394731 doc: Add documentation for retention subsystem
Adds documentation for the retention subsystem and boot mode
interface. Also marks the retention subsystem as experimental.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-04-24 13:27:53 +02:00
Jamie McCrae 1369bcec3f doc: release: 3.4: Add nRF51/nRF52 sys_reboot deprecation note
Adds a note that the old behaviour of setting the GPREGRET register
to the parameter of sys_reboot() is no longer the default as the
boot mode interface has replaced it.

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2023-04-24 13:27:53 +02:00
Christian Schlotter 951a37d5a0 doc: security: Unify style
Unify style in Zephyr Security Overview.

Signed-off-by: Christian Schlotter <christian.schlotter@zeiss.com>
2023-04-21 16:33:16 +02:00
Dawid Niedzwiecki 7f7e48e66e mgmt: ec_host_cmd: create chosen string per backend
Create strings to set the chosen node per backend. It is done for
better clarity.

Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
2023-04-21 16:29:59 +02:00
Dawid Niedzwiecki 1d62002bba mgmt: ec_host_cmd: update configs naming
Just use better namings for the buffer sizes configs.

Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
2023-04-21 16:29:59 +02:00
Alberto Escolar Piedras ad3c3909ae tests/bsim: Add a script to generate coverage reports
For users convenience, as it is a typical usecase to
want to see the actual coverage of a set of tests.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2023-04-21 16:23:35 +02:00
Carlo Caione de90dfccbc syscall: Introduce __syscall_always_inline
Sometimes we want to force the inlining of a __syscall. Introduce a new
__syscall_always_inline symbol to do that.

Signed-off-by: Carlo Caione <ccaione@baylibre.com>
2023-04-20 14:56:09 -04:00
Benjamin Cabé d497ca0089 doc: doxygen: Remove kernel tests
Remove kernel tests from Doxygen INPUT as they end up unnecessarily
included in the generated API documentation.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2023-04-20 08:17:06 -04:00
Bjarki Arge Andreasen 20bbb538c9 tests/drivers/rtc/rtc_api_helpers: Test for more archs
The test suite was limited to the native_posix board,
now it is built and run for any board supported by CI.

The native_posix yaml files for both 32 and 64 bit
boards have been expanded to support rtc, allowing CI
to build and test the rtc_api test suite against the
native_posix and native_posix_64 boards.

Signed-off-by: Bjarki Arge Andreasen <baa@trackunit.com>
2023-04-20 11:43:35 +02:00
Bjarki Arge Andreasen 95751328f5 doc/release/release-notes-3.4.rst: Added RTC API entry
Added entry for new RTC API in new APIs section of
release notes.

Signed-off-by: Bjarki Arge Andreasen <baa@trackunit.com>
2023-04-20 11:43:35 +02:00
Bjarki Arge Andreasen 84569f8f33 doc/hardware/peripherals/rtc.rst: Refine docs
Fixed spelling mistakes, added links in place of
highlighted text where appropriate and switched
unformatted blocks with bash commands to bash
code blocks.

Signed-off-by: Bjarki Arge Andreasen <baa@trackunit.com>
2023-04-20 11:43:35 +02:00