This file defines some of the most important properties in the
devicetree, including core concepts like 'compatible', 'reg', and
'interrupts'. For some reason, we've never prioritized writing up
proper descriptions that indicate their importance or show where the
user can get more information about them in the specs or elsewhere.
Give this file a once-over to improve the situation.
Signed-off-by: Martí Bolívar <mbolivar@amperecomputing.com>
Signed-off-by: Martí Bolívar <marti.bolivar@oss.qualcomm.com>
Although it's quite unlikely that we will see shared memory
objects in practice that are greater than 2GiB, there is a
possibility of integer overflow when comparing intptr_t and
size_t, since the former is signed and the latter is unsigned.
Explicitly check to ensure that the addend is less than
INTPTR_MAX before subtraction.
This fixes CID 487734
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The nsem_list_unlock() static inline function looks as though it
was designed to always ignore the return value of
k_mutex_unlock(), presumably for performance reasons.
A quick audit of the code looks as though the call should
always succeed.
Prepend (void) to the call to avoid the coverity defect in the
future.
CID 444386
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
To avoid starvation of a traffic class by another, limit the maximum amount
of packets, that can sit in a single traffic-class-fifo to a fraction of
the maximum amount of available packets. In the tx-case also reserve
packets for direct sending, in the case, where
CONFIG_NET_TC_SKIP_FOR_HIGH_PRIO is enabled.
Signed-off-by: Cla Mattia Galliard <cla-mattia.galliard@zuehlke.com>
Without this patch the hdlc_iface_init() function assigns to
ot_hdlc_rcp_context structure pointer (*ctx) value of 0, as in the
NET_DEVICE_DT_INST_DEFINE() preprocessor macro the 'data' field is
set to NULL.
Afterwards, the ctx->iface is set to iface address passed to the function
(as well as the ctx->ot_context is set).
Writing those values to address 0x0 is catastrophic to for example
mimxrt1020, which uses ITCM memory (mapped from 0x0) to store flash
handling functions, as those are used to XIP code directly from
SPI NOR memory (as mximxrt1020 doesn't have internal flash).
In this particular case - the flash_flexspi_nor_erase() function is mapped
(i.e. relocated) to ITCM's 0x0 address. Overwriting first 8 bytes of it
causes the SoC to enter "Precise data bus error" exception.
The fix is to define the static instance of struct ot_hdlc_rcp_context
and pass its address to the NET_DEVICE_DT_INST_DEFINE() macro. As a result
its storage is now in RAM, not ITCM.
This issue has been discovered on UART based HDLC RCP communication, but as
it also may be problematic on the NXP driver, this patch fixes it too.
Signed-off-by: Lukasz Majewski <lukma@denx.de>
To fix the native hardware chip select, we need to rewrite this driver
to not use the MCUX SDK handle abstraction, which does not fit the
zephyr use case.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Add functions to get remaining length in the transfer. Refactor a bit to
avoid duplicate code for the for loop that is the same as in the total
length function.
The difference between the total length and left length function is that
the current buffer total length is counted in the former and the current
buffer remaining length is counted in the latter.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Add properties for describing RX and TX fifo sizes.
Also reformat some descriptions and fix the description of the
transfer-delay property which was incorrect. Since zephyr spi bufs are
not continuous, every possible Zephyr LPSPI driver must use
continuous transfer mode, for which the meaning of this delay has
nothing to do with the chip select.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
There is no such thing as associating a compatible to a child binding
so remove this from the nxp,dmic binding definition and devicetree files
that incorrectly set one.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The GPIO peripheral on Silabs Series 2 devices is responsible for
allocating analog buses to analog peripherals. Enable support for
this in the pinctrl driver. Since these bus allocations are not
digital pins, introduce a new property silabs,analog-bus for this
purpose.
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
The event monitor did not handled IPv4 multicast address
addition or deletion information.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
To simplify debugging what event code is missing from the
events shell module, print also event id for the for unknown
events. This way it is a bit easier to figure out what the
unknown event is.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Print Ethernet carrier on/off and VLAN tag enabled/disabled
status when monitoring events.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Node properties are not created for all properties defined
by the node's binding (Binding.prop2specs),
only for those that actually have a value.
Signed-off-by: Christophe Dufaza <chris@openmarl.org>
PropertySpec.path does NOT tell "the file where the property
was last modified", but instead the binding file specifying
the devicetree node of which this is a property.
See: #65135
Signed-off-by: Christophe Dufaza <chris@openmarl.org>
In `--coverage-per-instance` mode for 'gcovr' merge individual
coverage.json reports into the aggregate code coverage report
instead of processing .gcda data files again.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
With this change, the coverage data (GCOV dump) is extracted from the
test log files after each of the test instance parallel execution,
instead of post processing all the logs at the end of the Twister run.
The new `--coverage-per-instance` mode extends Twister coverage operations
to report coverage statistics on each test instance execution individually
in addition to the default reporting mode which aggregates data to one
report with all the test instances in the current scope of the Twister run.
The split mode allows to identify precisely what amount of code coverage
each test suite provides and to analyze its contribution to the overall
test plan's coverage. Each test configuration's output directory will have
its own coverage report and data files, so the overall disk space and
the total execution time increase.
Another new `--disable-coverage-aggregation` option allows to execute
only the `--coverage-per-instance` mode when the aggregate coverage
report for the whole Twister run scope is not needed.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Group Twister code coverage command line arguments for better usability.
Add more details in descriptions.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
When reprinting the shell command buffer with long user inputs, the
reprinted buffer may cross a line boundary, and require a newline to be
printed. For these cases, print the command buffer character by
character, inserting newlines as appropriate.
Fixes#82155
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
nRF5340 SoC supports retained_mem driver, which can be
utilized for RAM retention in System OFF sleep mode.
Add sample configuration confirming this.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
Code is now incorporated into SystemInit() function of MDK 8.69.1,
which is integrated within nrfx 3.10.0.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
Makes the esp_console_init() calling during hardware initialization
conditioned to CONFIG_ESP_CONSOLE
Signed-off-by: Marcio Ribeiro <marcio.ribeiro@espressif.com>
Cast sector_count and sector_size to uint64_t to prevent potential
integer overflow when calculating total device size in
disk_access_device_size().
Fixes Coverity issue CID-322647
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
properly check return code from i2c_reg_write_byte_dt effectively
making it possible for gpio_npm2100_port_set_masked_raw to error out since:
if (ret != 0U) {
return ret;
}
was dead code before this fix.
Fixes CID-444376
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add a check to ensure the frame size does not exceed the video buffer
size defined by `CONFIG_VIDEO_BUFFER_POOL_SZ_MAX`. Even if the sensor
supports the resolution, the frame size could overflow the buffer.
Signed-off-by: Ibrahim Abdalkader <i.abdalkader@gmail.com>
Ensure the DCMI video buffer is released only after the DCMI
has been fully stopped. This prevents potential access to the
buffer while the DCMI is still active, avoiding undefined behavior.
Signed-off-by: Ibrahim Abdalkader <i.abdalkader@gmail.com>
One of the collaborators of Networking: OpenThread is not active
anymore and was replaced by another one.
Signed-off-by: Kamil Kasperczyk <kamil.kasperczyk@nordicsemi.no>
MCUboot's imgtool requirement has been moved directly to MCUboot
which can be installed using west packages if needed, remove it
from Zephyr's requirements
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
The commit marks stream_flash_erase_page as deprecated.
After the function is removed users will have to rely on stream
flash to erase space it needs prior to write.
The stream_flash_erase_page has several issues like using non-relative
offset for erases, allowing to destroy data already written or even
erase out of area available for stream flash.
This fixes#67407
Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
Keep on testing the function but fix logic where applicable
and remove last_erased_page_start_offset which has been replaced
with erased_up_to in stream_flash_ctx.
Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>