RFU bits has to be ignored according to the spec; In addition,
some MediaTek devices seems to have it set (by mistake I assume),
so having the check means we cannot sync to these devices
Signed-off-by: Troels Nilsson <trnn@demant.com>
Adding a brief fly-in of the main concepts of the
implementation of link layer control procedures handling
Signed-off-by: Erik Brockhoff <erbr@oticon.com>
Currently, the camera fixture test can only tell whether data are dumped
onto memory. This is to check further if the image content is correct.
The algorithm is rather simple: compare the average color of each bar
of a generated pattern with a predefined target in CIELAB76 color
space (which is nearly perceptually uniform).
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
The logs that the fixture test are based on are not printed anymore due
to recent changes from "printk" to "LOG_DBG". Change the log level so
that it can work again.
Remove "Capture started" as it is not a relevant test regex. Logs are
sometimes not correctly printed in the console, for example, we can see:
DEBUG - DEVICE: muart:~$ [mapture started
As "Capture started" is a one-time log, fixture test will then fail due
to timeout.
Also, consolidate other regex.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Add a test that checks behavior of
CONFIG_BT_CONN_CHECK_NULL_BEFORE_CREATE Kconfig option.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
This commit adds a warning and a Kconfig option to `bt_conn_le_create`
and `bt_conn_le_create_synced` functions which are meant to warn a user
of a potential leakage of an active connection object.
This change is implemented due to frequent incorrect use of the
connection pointer where a pointer to an existing connection object
is overwritten by `bt_conn_le_create` and `bt_conn_le_create_synced`
functions which in turns leads to sporadic critical bugs. See
https://github.com/zephyrproject-rtos/zephyr/pull/78284#discussion_r1754304535
for more details.
The Kconfig option is introduced instead of always returning the error
to not affect current implementations. However, it is recommended to
keep this option enabled to avoid potential bugs.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
Some devices may belong to >1 power domain, so with the current design
this is something not possible to describe. It's worth to note that
Linux also uses the `power-domains` naming scheme, not `power-domain`.
This patch also introduces `power-domain-names` so that each entry in
`power-domains` can be given a name if needed. `#power-domain-cells`
is now required as well.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Current code does no longer support
the non monolithic feature.
Hence, removing unnecessary code.
Signed-off-by: Yassine El Aissaoui <yassine.elaissaoui@nxp.com>
This config will be used to indicate if a platform
has the support for monolithic BT feature.
Signed-off-by: Yassine El Aissaoui <yassine.elaissaoui@nxp.com>
Enabled the MRT at the board level for
mcxn947. Enabled the clocking for the MRT
in the clock control.
Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
Change integration_platform -> platform_allow to not build the
shell test suite for all supported boards.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
This adds promiscuous mode support functions into build for filter
operation when the configuration CONFIG_NRF70_PROMISC_DATA_RX
is enabled.
Signed-off-by: Vivekananda Uppunda <vivekananda.uppunda@nordicsemi.no>
This set of changes brings in promiscuous mode filtering support in
driver. Since, firmware would be unable to filter packets due to
connection issues, the filtering support for promiscuous mode is
moved to the driver.
Signed-off-by: Vivekananda Uppunda <vivekananda.uppunda@nordicsemi.no>
Moved MCUboot trailer's status erase ahead any write operation,
which is step which helps with addition of support for devices
don't require explicit pager erase.
For these kind of devices flattening of mcuboot image status in
the trailer was introduced.
Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
Driver now uses multi-instance PDM nrfx API and
defines PDM device based on available instances.
It also introduces calculating PDM frequency using
prescaler, present on nRF54L15 FP1.
Updated nrfx API version changed to 3.7 to use the
new PDM API.
Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
New PDM, some present on nRF54L15 FP1, instances have
been added. Modified condfiguration file for nRF5340,
which now requires PDM0 instance.
Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
Added dedicated nrfx configuration files for
nRF54L15 FP1, which differ from ENGA variant with
inclusion of PDM.
Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
Doc and .yaml descriptions shall mention retained_mem
in supported features on affected boards.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
retained_mem driver is now compatible with nrf54h20 cpuapp & cpurad.
Also add missing .conf for nrf54l15.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
nRF54H20 cpuapp and cpurad are now compatible with retained_mem,
so explicit list of supported devices can be removed.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
Tests for prometheus library support.
It contains integration and unit test
each metric types.
Signed-off-by: Mustafa Abdullah Kus <mustafa.kus@sparsetechnology.com>
The sample uses the Zephyr HTTP server library
and demonstrates the Prometheus metric
server node. Prometheus client library
runs as a pull method. The sample contains
the HTTP request counter and increases
when refresh path of '/metrics' from the browser.
Signed-off-by: Mustafa Abdullah Kus <mustafa.kus@sparsetechnology.com>
The library provides Prometheus metrics
types, collector and exposion formatter.
The library isn't thread-safe for now.
The next first pull request will support
that. Can be use exposion formatted
output with Zephyr Http server.
Signed-off-by: Mustafa Abdullah Kus <mustafa.kus@sparsetechnology.com>
Initialize the 'enabled' variable before using it.
This fixes the following compilation warning:
"warning: 'enabled' may be used uninitialized [-Wmaybe-uninitialized]"
issued when compiling with `CONFIG_DEBUG` enabled.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Tested-by: Daniel Baluta <daniel.baluta@nxp.com>
Enable the irqstr interrupt controller for the adsp-based
imx8mp.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Tested-by: Daniel Baluta <daniel.baluta@nxp.com>
Add 1-Wire register file
Some MAX32 MCUs has 1-Wire peripheral some one not
So that added in device related dtsi file.
Has 1-W Not have 1-W
MAX32655 MAX32662
MAX32666 MAX32670
MAX32680 MAX32672
MAX32690 MAX32675
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Enable dma boards/test for S32Z270.
The non-cacheable memory used for DMA tests (chan_blen_transfer and
loop_transfer) is split from the system SRAM.
Signed-off-by: Ha Duong Quang <ha.duongquang@nxp.com>
Support multiple instances for dma.
Memset struct data and tcdpool on initialization is not necessary.
Therefore remove it.
Signed-off-by: Ha Duong Quang <ha.duongquang@nxp.com>
Adds HCI support for:
- LE CS Security Enable
- LE CS Procedure Enable
- LE CS Set Procedure Parameters
- LE CS Set Channel Classification
- LE CS Read Local Supported Capabilities
- LE CS Write Cached Remote Supported Capabilities
- LE CS Write Cached Remote FAE Table
Signed-off-by: Adam Cavender <adam.cavender@nordicsemi.no>
If OA read fails, then the essential thread is terminated.
Correct the behavior so that the driver re-tries the read and
continues to work.
Refactor offload thread OA and Generic SPI parts into
if/else statement.
Add missing `is_adin2111` to OA port 2 RX status check.
Signed-off-by: Georgij Cernysiov <geo.cgv@gmail.com>
Fix to setup correct short prepare timeout when preempt
callback does not find the prepare in the head of the
pipeline. In this case, find the short prepare and setup
a fresh preempt timeout for the determined short prepare
present in the pipeline.
Relates to commit 7d1bc1789e ("Bluetooth: Controller: Fix
short prepare preempt timeout start").
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix delayed ULL scheduling an auxiliary PDU reception by
skipping it. When many bufferred ADV_EXT_IND are to be
processed, the ULL scheduling could get late and then cause
the scan aux LLL to detect increased overhead start timing.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix to reschedule at window start when there are no more
tickers in the list to check for overlap.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Remove ticks_elapsed use in reschedule_in_window as it has
already been used in the bottom half processing.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
During use of tests/bluetooth/shell application to perform
extended scanning with periodic advertising and broadcast
audio source devices around, it was observed that the
application crashed due to too low BT_RX_STACK_SIZE, hence
increase by 128 bytes.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix implementation of single switch timer minimum compare
value requirement. Do not always add the maximum possible
radio latency duration, but check if the required compare
value is smaller, then use the remainder required as the
extra compare value. This fix reduces latencies to setup
radio receptions and fixes an assertion in lll_scan_aux
when radio_tmr_start_us() is checked for latencies.
Relates to commit bcd28e0a86 ("Bluetooth: Controller:
Fix sw switch single timer for spurious TXEN/RXEN").
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Consistently use the nRF54L15 as the non-TF-M integration platform
in addition to `native_sim`, and the nRF9151 as the TF-M one.
In addition, add the `integration_platforms` specification to the
tests that were missing it.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
add `ALLOW_EMPTY TRUE` property to silence cmake warnings in case
when no sources are added to subsys__net library
Signed-off-by: Maciej Baczmanski <maciej.baczmanski@nordicsemi.no>
Seen when having multiple network interfaces that the sock_error
was 0 even if the socket was serviced properly. So if SO_ERROR
returns 0, just ignore it.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
We must register all listening sockets under one file descriptor
array when calling dns_dispatcher_register() which then calls
net_socket_service_register(). The socket services expects all
the registered sockets under one service context to be in one
array. If this is not done, the latest socket array wins and
the earlier registrations are forgotten.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
As the DNS might listen to multicast addresses (like in mDNS) in
different network interfaces, make sure to check the network
interface index when registering the dispatcher context. This
allows two mDNS registrations to more than one network interface.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Initial support for SSD1322 OLED display driver. Only 1 bit color mode is
supported.
Most options map directly to values documented in the datasheet,
except segments-per-pixel, which I had to add to support the Newhaven
NHD-2.7-12864WDW3. This is a slightly odd feature, but in practice
it is a lot nicer to support it in the driver, and since we're currently
remapping pixels anyway, it makes sense to implement here.
This driver also has a configurable buffer size for the pixel conversion.
By using a larger buffer, we can potentially use DMA for the SPI transfer.
The default is set to 8, which is the smallest value that supports
segments-per-pixel = 2
Initial driver implementation by Lukasz Hawrylko <lukasz@hawrylko.pl>.
Additional options and configurability by Tobias Pisani <mail@topisani.dev>
Signed-off-by: Lukasz Hawrylko <lukasz@hawrylko.pl>
Signed-off-by: Tobias Pisani <mail@topisani.dev>
Co-authored-by: Lukasz Hawrylko <lukasz@hawrylko.pl>
Co-authored-by: Tobias Pisani <mail@topisani.dev>
Like 2ca179c, check and warn if incoming HCI event parameters exceed
the specification. This helps debugging controllers by detecting the
out-of-spec value that shouldn't appear.
Signed-off-by: Sungwoo Kim <iam@sung-woo.kim>
The RxFIFO is already flushed any time a transceive operation
finishes, there is no need for doing it also before the
transaction start.
The aim of this change is to simplify the logic and to
(potentially) reduce the minimum time between transactions.
Signed-off-by: Daniel Gaston Ochoa <dgastonochoa@gmail.com>
Fix errors found in CI for missing clock_t and clockid_t types
when building the tests/posix/net testsuite against newlib.
Also use angle-brackets and prefixed path with
`<zephyr/posix/posix_types.h>` since it is not in the default
search path and is analagous to `<sys/types.h>`.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Adds support for cooperative locking/unlocking the VPX vector registers.
Provided that all VPX enabled threads use these routines to control
access to the VPX vector registers, it will allow multiple threads to
safely use them without the need for saving/restoring them upon each
context switch.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
To check if DVFS can be used, the CONFIG_NRFS_DVFS_LOCAL_DOMAIN symbol
needs to be used, not CONFIG_NRFS_HAS_DVFS_SERVICE which only indicates
that DVFS is technically possible, not that its local domain part is
actually included in the build.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Current nPM1300 charger driver does not work with batteries
without NTC thermistor. Added supported for this feature.
Signed-off-by: Javier Santos <jasr93@outlook.es>
This commit adds support for INA236 into the existing INA230 driver.
These two chips are similar enough to share most of the code.
The device can be defined the same way as INA230 and we only have
the extra option to select the high-precision mode.
```
ina236: ina236@40 {
status = "okay";
compatible = "ti,ina236", "ti,ina230";
reg = <0x40>;
adc-mode = "Bus and shunt voltage continuous";
vbus-conversion-time-us = <1100>;
vshunt-conversion-time-us = <1100>;
avg-count = <1>;
current-lsb-microamps = <1000>;
rshunt-micro-ohms = <15000>;
alert-gpios = <&gpiod 0 GPIO_ACTIVE_LOW>;
high-precision;
};
```
Signed-off-by: Tomáš Juřena <jurenatomas@gmail.com>
Enforce some minimum delay between enabling the voltage divider with a
GPIO and sampling the analog voltage. Without this delay the ADC can
easily sample the transient power up curve instead of the steady state
output.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Implement the parallel mode in the powertrain switch TLE9104.
This allows that OUT1 and OUT2 are controlled together, as well
as OUT3 and OUT4.
Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
Inform the executor of a submissions completion with -ENOMEM
if the size of the workq is not big enough.
Signed-off-by: Florian Weber <Florian.Weber@live.de>
This function can be used to parse HCI-formatted subevent results
regardless of whether they come from CS Test or not
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
Add some defines for packet quality and rssi for RTT,
these are useful for filtering out steps where the RTT exchange
was unsuccessful
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
These options are in microseconds but not fully configurable,
document what options are allowed in 6.0
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
It's more common (and more readable) convention to use lower-case
names for string-based device tree property values. Convert the HCI bus
and quirks to follow this convention. Also take advantage of the
recently added support for string-array enums to enforce that the
correct values are used.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
To enable breakpoints on this board, remove the `dgdb_memory_map disable`,
which is a leftover from early development steps.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
This updates the SHA for SOF to their v2.11 release.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Although boards/index.rst is not included in the PDF toc, it seems as if
Sphinx tries to build the page anyway, which fails because the board
catalog directive is not outputting any node on non-HTML builders.
This commit fixes it by returning a "Board catalog is only available in
HTML." paragraph. In the future, we might want to output some kind of
static table or bullet list for non-HTML builders.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Support for R_XTENSA_SLOT0_OP was implemented with a relocation table
test case, containing only one entry at offset 0. For multiple
entries .r_addend has to be taken into account.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Add I2C and SPI configuration to board DTS and mark as supported in YAML.
Also add support for arduino_i2c and arduino_spi.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Add I2C and SPI configuration to board DTS and mark as supported in YAML.
Also add support for arduino_i2c and arduino_spi.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Add I2C and SPI Device Tree nodes in SoC DTSI files to allow usage of these
peripherals.
Note that the SPI driver requires no modification to be functional on WB0.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Select COMBINED_INTERRUPT mode of operation for STM32WB0 to match the
hardware and allow the driver to build - no other modification required.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
- Disables on reset NMI and EzPort.
- Fixes frdm-k64 SW3 user button on reset issue.
So it can be assigned to the mcuboot-button0 alias.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
System lists are not thread safe, therefore all accesses should be
protected with a mutex. Introduce a LwM2M context specific mutex,
and use it whenever lists defined per-context are acessed.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
The LwM2M message allocation was not thread safe, i. e. the message was
acquired by setting the ctx pointer, and it was freed by clearing the
entire message structure.
If preemptive threads were enabled, and memset() clearing the message
content was preempted, the message structure being currently zeroed
migh've been allocated and initialized by some other thread. If the
thread releasing the message resumed work, it would continue clearing
the freshly allocated and initialized message structure.
In order to prevent this, introduce a new global mutex for the lwm2m
engine global variables. The mutex is used when LwM2M message is
allocated/deallocated. This will prevent reallocating the message
during the release process.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
In "connect" all networks are removed and new network is always added,
but in disconnect the network isn't deleted, so, the memory is
unnecessarily held till next connect. This is not exactly a leak, but if
someone profiles using "kernel heap" then this can be construed as a
leak.
Fix this by removing network during the disconnection (for now "all") so
that the memory can be used by someone else.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
When shell is integrated with the logging frontend then pointer to
the logging backend in the shell structure is null. When null pointer
is found assume that it is a shell instance with logging frontend
integration and use frontend in the logging commands.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
ETR handler (for Coresight STM logging) is using console UART and
can act as the shell backend. When that happens default serial shell
backend shall be disabled (and it is by default enabled if there is
a zephyr,console chosen set.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Extend ETR handler to be able to work as shell backend and multiplex
Coresight STM logging with shell content on the UART used by the
ETR handler. Shell backend works only in the standalone mode.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Use DMM_MEMORY_SECTION instead of a custom macro. When file was created
dmm was not present yet.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Extract shell instance creation from SHELL_DEFINE to Z_SHELL_DEFINE.
SHELL_DEFINE creates logging backend and calls Z_SHELL_DEFINE to
create a shell instance with that logging backend. With this split
it is possible to create a shell instance with logging integration
but without the default shell logging backend.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Shell is capable of acting as the logging backend and multiplex
logging messages with shell content. It expects that logging
messages goes through the logging backend. However, there is an
option that logs go only to the custom logging frontend. In
that case this default approach does not work and logging
frontend cannot be easily integrated with the shell (due to
its custom nature). Add Kconfig option SHELL_LOG_BACKEND_OOB
which prevent compilation of the default shell log backend.
When enabled, application can provide frontend specific
implementation to integrate shell with the logging.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
With rtio_sqe_prep_read() buf is assigned to userdata. The __ASSERT
should check if the same userdata arrived with rtio_cqe_consume_block()$
Signed-off-by: Mirko Becker <mirko.becker@phoenixcontact.com>
Extended functionality of the current driver to support
Synopsys DesignWare 8250 UART.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Refactor the char read into a function, check for availability
before reading.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Rename `uart_ns16550_device_config` to `uart_ns16550_dev_config` so
that it looks consistent with the device data structure.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Frame timeout is a hardware feature present in newer versions
of UARTE (e.g. in NRF54X platforms) for detecting idle state
on RX line and ending RX after configurable timeout.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Rework driver to support new way of asynchronous RX handling.
Previously RX was handled in two modes: using RXDRDY interrupt for byte
counting or TIMER + PPI. Both modes had flaws. RXDRDY interrupt mode
could miscalculated amount of received bytes when interrupt was not
handled on time. Data was not lost but was not reported on time that
could lead to issues. PPI+TIMER mode requires additional resources
thus it was not the default mode. Often user was not aware of that
option and was expiriencing driver RX faults.
New RX mode is switching buffers when there is new data (RXDRDY event
not set for given amount of time). It does not require additional
resources to get precise byte counting. Additionally, this is in line
with new UARTE feature (RX frame timeout) which is present in nRF54X
devices. The behavior of the driver is the same for legacy devices
and new one. For legacy devices k_timer periodic interrupts are used
to check if there are any new bytes and it is not needed when RX frame
timeout is present.
Improved RX mode is enabled by default
(CONFIG_UART_NRFX_UARTE_ENHANCED_RX=y) but legacy modes are still
available though not recommended to be used.
Note that new RX mode (CONFIG_UART_NRFX_UARTE_ENHANCED_RX=y) behaves
a bit different because timeout always triggers switch of buffers
which means that there will be no UART_RX_RDY events with non-zero
offset. It also means that every UART_RX_RDY will be followed by
UART_RX_BUF_RELEASED.
After rework, driver is recommended to be used for all platforms as it
performs much better and takes much less code than the second UART shim
available for Nordic devices.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Refactor RX asynchronous API function to use a pointer to the RX
async data structure instead of top level data structure pointer.
It improves readability with more concise code.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
1. add delay read config for platforms that has capacitor with pin
2. add dts pin flags to gpio_pin_config when output.
Signed-off-by: Hake Huang <hake.huang@nxp.com>
update boards that can not use the common pins
mimxrt102x reuse with ethernet
mimxrt106x has external pull up
lpcxpresso55s3x reuse with int
add CONFIG_SKIP_PULL_TEST by default to be more general
user can enable this test in customized case with select pin
ST prefer to using D9 D10 pair to testing.
Signed-off-by: Hake Huang <hake.huang@nxp.com>
As per USB 2.0 specification 7.1.5.1: The voltage source on the pull-up
resistor must be derived from or controlled by the power supplied on the
USB cable such that when VBUS is removed, the pull-up resistor does not
supply current on the data line to which it is attached.
Signed-off-by: Lukas Gehreke <lk.gehreke@gmail.com>
Extend `footprint-tracking` CI workflow with two more steps:
* pack Memory Footprint data produced by `track.py` script
into Twister JSON footprint reports (`twister-footprint.json).
* upload Twister JSON footprint reports into ElasticSearch storage.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Add usage example for sys_trace_user_event, to demonstrate how users
could add tracing functionality to their application.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Document availability of sys_trace_user_event, for users who are trying
to add custom trace events to their application.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add support for a "named event" trace. This trace is intentionally not
used by the system. The purpose of this trace is to allow driver or
application developers to quickly add tracing for events for debug
purposes, and to provide an example of how tracing subsystems can be
extended with additional trace identifiers.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Support the BMM150 being on a power domain, which may not be powered at
boot. For example, Nordic Thingy53.
Signed-off-by: Jordan Yates <jordan@embeint.com>
There is an (undocumented) additional delay necessary if the device woke
up and a measurement is triggered via the "force"-mode. The additional
sleep time was determined empirically on different devices.
Signed-off-by: Juliane Schulze <juliane.schulze@deveritec.com>
Update power management to only start/stop periodic measurements in
`CONFIG_BME280_MODE_NORMAL`, instead of re-initialising the chip
completely.
In `CONFIG_BME280_MODE_FORCED`, there is nothing to do when suspending,
as the sensor is already in its lowest power mode.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Adds a new NOTRUN status, which indicates
that a test was successfully built, but
not run on account of being not
runnable in given test instance.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
Add support for the Telit ME310G1 LTE modem which is very similar to
the ME910G1. Re-use the ME910G1's AT command scripts but rename
them to mex10_xx and define a shutdown script (AT#SHDN).
Signed-off-by: Niklas Gürtler <niklas.guertler@e-obs.de>
Add a DTS binding file for Telit ME310G1 cellular modem based
on the binding for ME910G1 but without the mdm-reset-gpios as
the ME310 doesn't have a reset input.
Signed-off-by: Niklas Gürtler <niklas.guertler@e-obs.de>
Add support to define a shutdown script for cellular modems, i.e.
AT commands to shutdown the modem. This allows to shutdown the
modem much quicker compared to using a power pulse which saves power.
Signed-off-by: Niklas Gürtler <niklas.guertler@e-obs.de>
Add EAP-TLS, EAP-PEAP-MSCHAPv2, EAP-PEAP-GTC, EAP-TTLS-MSCHAPv2,
EAP-PEAP-TLS, EAP-TLS-SHA256 enterprise wpa2 and wpa3 suiteb
support for station.
Signed-off-by: Rex Chen <rex.chen_1@nxp.com>
This allows to run the test 'chan_blen_transfer' and 'loop_transfer' on
the sgrm board.
The functionality tested in `chan_link_transfer` and `scatter_gather` is
not (yet) supported by the Si32 DMA driver, and those tests therefore
not enabled.
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Adding myself as maintainer because my employer Husqvarna wants to
upstream the Gardena smart gateway radio module SoM to Zephyr, and keep
it well-supported.
Adding as collaborator M1cha, because he did the initial port.
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This adds support for the SiM3U/Si4467 based SoM used on the GARDENA
smart Gateway [1] (art. no 19000 and 19005).
[1] https://github.com/husqvarnagroup/smart-garden-gateway-public
Signed-off-by: Michael Zimmermann <michael.zimmermann@grandcentrix.net>
Add updates to support MCXW71
Add support if RX data are received in ISR context
Add support to set BT address using Vendor command
Signed-off-by: Yassine El Aissaoui <yassine.elaissaoui@nxp.com>
If AP indicates the presence of buffered traffic, then it is up to the
STA to decide whether to stay in PS or come out of PS, add configuration
options that can be used at runtime to choose this.
This is tagged as "noup" because it's a backport and "fromlist" cannot
be used as it won't apply cleanly.
Signed-off-by: Ajay Parida <ajay.parida@nordicsemi.no>
The mutex is used to protect RPU zephyr context which gets modified for
every interface down and up (including recovery), so, it was being
re-initialized but also used to protect down and up which is a bug.
Move the re-initialization to the driver entry so that it happens only
once and we can properly use the mutext for down and up protection.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
The RPU context lock is not unlocked this is causing recovery to be
stuck waiting for the lock.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
There is a race condition when recovery is in progress and in parallel
Wi-Fi util commands are being executed (CTF), where the RPU context is
de-initialized as part of recovery but no checks are present in the
Wi-Fi util command processing causing a crash.
This needs a proper fix for all commands, but for maintenance branch
fix is added only for commonly used commands.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Dynamically set power save exit strategy runtime configuration that
allows to switch b/w stratgies depending on conserving power and
low-latency traffic download.
Signed-off-by: Ajay Parida <ajay.parida@nordicsemi.no>
Ideally we should be using Zephyr spinlock APIs but that requires
changes to shim API, so, for this maintenance release just replace with
mutex to keep the context same and no API changes.
This solves the locking issue that we see when control and data path are
excited concurrently due to locking semantics of semaphores, the issue
is not root caused but mutex enforce strict locking semantics for
multiple threads and solve the issue.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Add a null check for HAL context in the interrupt handler, this was
causing locking issue operating on null. The root cause of null is not
known, but this solves the locking issue when data and control paths are
excited in parallel.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
To handle interoperability issue with few APs, add a feature to keep
sending keepalive frames periodically to avoid AP disconnecting the STA.
This is disabled by default to avoid unnecessary power consumption as
it's only seen with few old APs.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In crowded environments RPU is active for more than 10s due to too many
retries and this triggers a false RPU recovery. To avoid this, increase
the default to 50s to handle corner cases, as this will only impact the
recovery triggered case, higher timeout doesn't have any impact in
normal cases.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
With this offload, host doesn't need to manage RX buffers for management
frames, and this saves Host-RPU comms and thus giving RPU to sleep more
often and is essential to test RPU recovery.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
These are very frequent, so, a separate debug is added for debugging
host RPU recovery logic.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
During interface down in case TX has pending buffers in either TXQ or
Pending_Q then they are not freed instead the Q itself is freed.
Fix by traversing the Q and freeing all members.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Fix RPU recovery protection to solve build failures when RPU recovery is
disabled.
As recovery is primarily based on power-management, add a Kconfig
dependency to enforce, this simplies the macros to protect the code.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In case RPU is stuck in consecutive recovery over a time period then
that means it's not recoverable through RPU recovery, only thing left to
do is to trigger a system reboot. This feature is disabled by default,
so, either application can do their own implementatio or enable this
feature in the driver along with configurable retries and window period.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Check for RPU context as well.
To fix this properly we need more fixes to be backported, but this
should suffice for now.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
This is to avoid successive recoveries in case we get successive
watchdog interrupts from the RPU.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
During recovery we might get further watchdog interrupts causing
multiple recovery requests, ignore them if a recovery is already in
progress.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In order for the interface down to propagate and cleanup it needs more
time, using Shell 10ms was working due to human delay, but
programatically this needs higher delay.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Before proceeding with RPU bringup, do a sanity check by reading a known
signature to make sure the Host-RPU comms are operational.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In case RPU is stuck and need a recovery, the failures in interface down
should be ignored as they are expected and we should proceed with device
removal that in turn removes power to the RPU.
TODO: This works for single VIF, but needs more thought for multi-VIF.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
During watchdog (or any) interrupt processing, RPU accesses are being
made and they assert the wakeup_now flag this causes RPU recovery to not
trigger.
New false or true recovery detection algo:
Check the time difference b/w last de-assert and assert, and if it
exceeds minimum time needed for RPU to enter sleep, then not the
timestamp. This timestamp will be used to compare when a watchdog
interrupt is received and see if during the last window if host has
given a chance for RPU to attempt sleep, if yes, then attempt recovery
else ignore watchdog.
Also, add a Kconfig for the 10s active time that triggers recovery, this
needs to be passed to the FW (once we have enough patch memory).
Also, add a Kconfig for the minimum time needed for RPU to attempt sleep
in positive case.
Also, add a new _ms API for time stamp fetch, this is to avoid
precision loss when converting to and from ms to us and also makes code
readable by avoiding *1000 and /1000.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Use EXTRA_CONF_FILE in sample yaml files,
that replaced deprecated OVERLAY_CONFIG
since the Zephyr v3.4 release.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
This commit applies several changes in the way "heap_runtime"
feature is used. It can't be split due to bisectability issues.
Whenever the feature is enabled, a new heap is created and
custom malloc/calloc/free functions are added into the build
system. Those functions are currently used for internal Wi-Fi and BLE
drivers only.
Such changes are described below:
1) Rename heap.c to esp_heap_runtime.c for better readability.
2) Rename RUNTIME_HEAP to HEAP_RUNTIME to make it similar to what is
available in Zephyr.
3) Add runtime heap to BT as such as Wi-Fi.
Fixes#79490Fixes#79470
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Update both Wi-FI and BLE init codes to return proper
error code and logging when it is missing heap.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Since we now have PSA Crypto APIs/Mbed TLS alternatives for crypto
operations in all Zephyr's codebase we can start the deprecation
of the TinyCrypt libary (as planned from #43712).
This commit is only the inital step: updates documentation and
add the DEPRECATED Kconfig option to the TINYCRYPT one.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
Added extra testcases for the IGMPv3 protocol. The IGMP driver is
supposed to send an IGMPv3 report when joining a group.
Signed-off-by: Ibe Van de Veire <ibe.vandeveire@basalte.be>
Add igmp.h file to declare definitions for IGMP that are not meant te be
included by the application but can be used in e.g. tests.
Signed-off-by: Ibe Van de Veire <ibe.vandeveire@basalte.be>
According to RFC2236 section 2.5, the IGMP message may be longer then 8
bytes. The rest of the bytes should be ignored.
Signed-off-by: Ibe Van de Veire <ibe.vandeveire@basalte.be>
The header length of the net ip packet was calculated using only the
net_pkt_ip_hdr_len function. The correct header length should be
calculated by adding net_pkt_ip_hdr_len and net_pkt_ipv4_opts_len. This
resulted in an incorrect IGMP version type in case of IGMPv2 message
(when IGMPv3 was enabled). The IGMP message was not parsed correctly and
therefore dropped.
Signed-off-by: Ibe Van de Veire <ibe.vandeveire@basalte.be>
flushregs alias is deprecated, so it was replaced by the command:
"maintenance flush register-cache"
Signed-off-by: Marcio Ribeiro <marcio.ribeiro@espressif.com>
Add a no-disconnect property that skips the call to disconnect the pin
during suspend, this is useful as not all gpio controllers supports pin
disconnection, and right now using the gpio-keys driver on one of those
results in a failed initialization if PM runtime is enabled.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Fix DPP build error when HOSTAPD enabled and DPP disabled.
Guard hapd_dpp_dispatch in both CONFIG_WIFI_NM_WPA_SUPPLICANT_DPP
and CONFIG_WIFI_NM_HOSTAPD_AP.
Signed-off-by: Fengming Ye <frank.ye@nxp.com>
The commit 221199e15b presents a bug that
makes west flash failed with error.
AttributeError: 'NoneType' object has no attribute 'startswith'
In function is_tunnel(), tunnel may contain None and has no attribute
"startswith". Fix it.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Adds CONFIG_UDC_DWC2_USBHS_VBUS_READY_TIMEOUT_MS that allows
for waiting for a USBHS VBUS ready event for a specified
amount of time. Earlier it waited forever and because of that,
the udc_enable() was blocked forever if the USB cable was
disconnected. Now the function returns error on timeout.
Signed-off-by: Aleksander Strzebonski <aleksander.strzebonski@nordicsemi.no>
Adds a Kconfig fragment which changes the MFD init priority
Signed-off-by: Maximilian Deubel <maximilian.deubel@nordicsemi.no>
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
This is a follow-up to commit 7a2ce2882a.
Do not enable clock control by default on nRF54H Series SoCs when
the system timer is present, because clock control is not needed
for this purpose there.
Add missing `default y` in the CLOCK_CONTROL_NRF2 Kconfig option that
enables compilation of clock control drivers for nRF54H Series.
This way modules that actually require clock control (like drivers
that use radio) will be able to enable it using the generic option
(CLOCK_CONTROL), not the above one that is specific for nRF54H.
Update accordingly applications that referenced the CLOCK_CONTROL_NRF2
option.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
- A lot of zephyr networking samples (zperf, http_server, etc) will
complain if both 2.4g and subg ieee802154 are enabled simultaneously.
- This leads to a lot of new people getting confused with the network code
not working without any clear errors.
- As we already set the alias `zephyr,ieee802154 = &ieee802154g`, I think
it would be best to enable only subg by default.
Signed-off-by: Ayush Singh <ayush@beagleboard.org>
k_pipe_put_* functions should take const void* data
instead of void* data. This can lead to warnings at the
the -Werror=discarded-qualifiers compiler flag, because the
the input will be const void* and the parameter will be void*.
Fix it by replacing void* data with “const void* data”.
Signed-off-by: Bruce Rosier <brucerosier9@gmail.com>
This allows to select if device appearance requires encryption or
authentication or none. This makes it similar to what is implemented
for device name characteristic.
Signed-off-by: Szymon Janc <szymon.janc@codecoup.pl>
This makes it clear on how security requirements are set and avoid
confusion on how encryption and authentication are handled.
Signed-off-by: Szymon Janc <szymon.janc@codecoup.pl>
This is a new role available in Sphinx 8.1 and it very useful to avoid
typos and to provide a consistent way to link to CVEs.
This commit actually fixes some such typos :)
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Last 1k is used for saving VPR context and shall not be exposed.
Limiting RAM to 511k.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
dark-mode-toggle now allows to also set current mode to "system", which
allows people to use the system-wide dark mode setting rather than
having to definitively choose between light and dark mode once they've
used the button once.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
This hooks up the dark-mode-toggle-stylesheets-loader so that the dark
mode styles are loaded immediately, rather than waiting for the page to
load and then switching to dark mode. This prevents the "flashing" of
light mode styles on page load.
Fixes#79791
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Fix errors found in CI for missing clock_t and clockid_t types
when building the tests/posix/net testsuite.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The test targets the following devices at this time.
- atmel,winc1500
- inventek,eswifi
- inventek,eswifi-uart
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
`eswifi-uart` uses the ring buffer library, but the dependency is
not indicated.
Specify `select RING_BUFFER` to resolve the dependency.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
`_POSIX_C_SOURCE` must be specified to use the `strnlen()` function
in string.h. Make sure to specify this explicitly.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Implement callback for incoming CAN messages for any of the
configured filters for CANopenNode.
This can be used to wake the loop calling CO_process when a
new message was received which needs processing.
Signed-off-by: Christian Gabriel <ch_gabriel@web.de>
As the search form is becoming richer, provide some guidance on how to
filter the list of supported boards and what to do when no results are
found.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Store soc(s) information for each board in the catalog, as
well as populate a tree structure for the full list of
family->series->soc.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Now that we have full_name available in board.yml, stop trying
to "guess" full/commercial name of the board based on its
documentation.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Declaration with const keyword (subscriber, listener,message)
require extern cpp declaration otherwise the name is mangled.
Fixes https://github.com/zephyrproject-rtos/zephyr/issues/79664
Signed-off-by: Victor Chavez <vchavezb@protonmail.com>
When non-random number generation is allowed via
`TEST_RANDOM_GENERATOR`, enable an implementation for `sys_csrand_get`
that stubs out to `sys_rand_get`. This enables libraries that request
CS random numbers to be tested in CI, even if the results are not CS in
that context.
The documentation for `TEST_RANDOM_GENERATOR` is explicit enough about
the dangers of enabling this in production.
Signed-off-by: Jordan Yates <jordan@embeint.com>
This PR implements the set_signal callback from the video API.
A signal registered on VIDEO_EP_OUT raises once a new image has
been received completely.
Signed-off-by: Armin Kessler <ake@espros.com>
Regardless IO capabilities, clear MITM flag for pairing
initiator if the required security level is less than
BT_SECURITY_L3.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
SAADC peripheral for nRF54L Series allows to choose internal
voltages as positive inputs and samples shall showcase that.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
SAADC peripheral for nRF54L Series allows to choose internal
voltages as positive inputs.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
Split header files containing symbols denoting SAADC inputs
so that only supported inputs can be used for given device.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
All the remaining modules uses LOG_MODULE_REGISTER(<module>, <log level>)
Lets update the logging registration as the other modules are doing it.
Signed-off-by: Kiara Navarro <sophiekovalevsky@fedoraproject.org>
In the test scenario without alarms, it might
be the case that counter is already running and
it will not match the expected tick.
This adds a tick offset into the expected value
based on current counter reading.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Force capture call so that timer counter value is updated
accordingly.
This also adds get_value_64 counter API function.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
When Proxy advertising or PB-GATT Advertising Enabled and use a same
advertising sets.
As adv\_start will call multi HCI Command will cause syswork_q yield.
At same time, if another thread(BT RX) all schedule\_send will cause
unable send mesh message, because ADV\_FLAG\_ACTIVE was be set, but
ADV\_FLAG\_PROXY not set currentlly.
Add ADV\_FLAG\_SCHEDULE\_PENDING indicate mesh buf has been pendings
but not scheduled, so when proxy advertising enable, let's take again,
as we can't break or terminated adv\_start, so we must waiting proxy
advertising enabled.
But after https://github.com/zephyrproject-rtos/zephyr/pull/68558
The `k_work_is_pending` always true in `send_pending_adv`, which cause
unable to send more mesh message until more mesh message comming
Signed-off-by: Lingao Meng <menglingao@xiaomi.com>
Move myself from maintainer to collaborator.
I am not active enough on Zephyr to take on the role of maintainer.
Signed-off-by: Arnaud Pouliquen <arnaud.pouliquen@foss.st.com>
The FW blobs are contentious topic in OSS, so, add a provision to use
external tooling (e.g., NCS) to handle FW blobs for advanced usecases
(e.g., storing in external flash).
This won't be used upstream, only built-in or build-only are supported.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
The smp library implements de/serialization of SMP messages.
The smpclient library implements the serial, BLE, and UDP
transport layers for Windows, Linux, and macOS.
Signed-off-by: JP Hutchins <jp@intercreate.io>
When try to start SAP on channel 12 with region code US, the channel
check will fail and calls supplicant_send_wifi_mgmt_ap_status() with
iface->owner is NULL, which causes DUT hang. Set iface->owner when
enable the SAP can fix this issue.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
The Drivers using Pinctrl should be turning Pinctrl on
this should not be the responsibility of the board. This
commit removes CONFIG_PINCTRL from the boards side for nxp boards.
Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
1. optimized the logic for buffer usage in async api
2. skip timeout flush when the remaining counts is 0,
as this will trigger dma_callback to process.
3. remove scatter mode, as we are not using this mode
4. trigger after dma_reload.
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Modifies the CS bitfields that are used for accessing HCI
event data to take platform endiannes into consideration.
Signed-off-by: Burak Gorduk <burak.gorduk@nordicsemi.no>
Adds HCI support for LE CS subevent result continue
event and the reassembly logic for the partial results.
When subevent results are completed or the subevent is
aborted, the user callback is invoked with a buffer
pointing to the HCI event buffer, so no copy is done.
When subevent results are incomplete, then a reassembly
buffer is allocated from a fixed sized pool. This buffer
is used for the reassembling of the subevent result
containing all of the step data, which is then passed
to the user via the callback. kconfigs have been added
to set the size and the count of the reassembly buffer.
Signed-off-by: Burak Gorduk <burak.gorduk@nordicsemi.no>
Following the footstep of GCC/Clang cmake code to remove
TOOLCHAIN_LIBS, xcc also has it removed and utilizes
something similar to c_library to link the HAL library.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Shuffling of ld/lld on C library linking cmake code causes
issue with XCC as the HAL library is not being included in
linking. So make XCC to use xt-ld linker cmake code such
that the HAL library is included.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Removing the routine z_ready_thread_locked() as it is not
used anywhere. It was a leftover artefact from development
that previously escaped cleanup.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
As per board porting guidelines, the board image should be named after
the board.
This commit implements the changes for boards found to be non-compliant.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add ethernet phy header to ethernet group
Add ethernet.h to ethernet group
Add net/mdio.h to mdio group
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Don't attempt to take a mutex if operating from inside an ISR. The only
expected use-case where this should occur is when attempting to reboot
via `tfm_platform_system_reset` from an exception handler.
Fixes#79687.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Request calibration on ADC samples to improve the accuracy of the ADC
outputs and therefore the final measured current.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Instead of relying on INCBIN macros which do not properly add
dependencies, e.g., modifying FW file doesn't trigger rebuild.
Use the Zephyr cmake tooling to load the FW patch file as a header.
This also improves memory report where the patch target is clearly
visible instead of a hidden section.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
This reverts commit e2e96acebf.
This will be properly fixes by adding a target for nRF70.bin and
removing INCBIN approach.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Replace wrong compatibility strings for max14906 and max14916.
Fix wrong addressees for max14906 and max14916.
Signed-off-by: Stoyan Bogdanov <sbogdanov@baylibre.com>
Insert Feature Units in between:
* USB Streaming Input Terminal and Headphones Output Terminal
* Microphone Input Terminal and USB Streaming Output Terminal
The Feature Units have Mute control only on the Primary channel 0.
The headphones Feature Unit also has Automatic Gain control on all
channels while microphone Feature Unit has Automatic Gain control only
on the Logichal channel 1.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Rework NUM_SPATIAL_LOCATIONS() to evaluate to integer literal to allow
using it with LISTIFY() macro. This is necessary because Feature Unit do
not operate on channel clusters but rather on logical channels.
Track back Output Terminal channel cluster to appropriate entity. This
is necessary because Feature Unit does not repeat the channel cluster
information.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add initial Feature Unit bindings allowing user to place the Feature
Unit inside UAC2 instance description. Currently the bindings facilitate
only specifying which controls are available on the Primary channel 0
and on each Logical channel. The number of Logical channels has to be
derived from data-source property.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Ensure Jinja templates don't have extra blank lines in the output by
using the {% -%} syntax to suppress them.
This is not incredibly important but this helps keeps the HTML output
more readable.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add proper labels to the form fields for better UX/accessibility
Updated the placeholder for the "board name" field to be more
informative.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Fix definition for ROM status register for ACE1.5. The value should be
same as ACE2.0 and only different for ACE3.0.
Fixes: 6ad9b6ccab ("soc: intel_adsp: tools: add intel_adsp_ace30
support to cavstool.py")
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Update the HW models module to:
eeed2591d38e5e9bf89658df67555f2777249fc0
eeed259 RADIO: Do not warn about TASK_RSSISTART during RXIDLE
565220e 54L15.mk: Fix flipper hal target name
bb8c6fd Makefile: Let's install libraries by default
6dbb843 RADIO: Implement immediate RSSI measurement when needed
3a5d567 RADIO: Allow triggering TASK_RSSISTART from register writes
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Currently, Zephyr is always sending back notifications to
AP (e.g Linux in our case) on channel 0.
But this currently doesn't work if Linux uses other channel
id for communication. So, add option to use predefined
vring ID that can accomodate Linux used ID.
Signed-off-by: Alexandru Lastur <alexandru.lastur@nxp.com>
MbedTLS specifically checks for null-terminator, else it skips PEM
format processing and tries to parse it as DER causing parsing failures.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Enterprise security doesn't have either SAE or PSK, so, using a blanker
else throws a false warning. Fix the checks to proper handler enterprise
mode.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
This overlay has all necessary configuration needed for Enterprise mode.
Two variants are given, once with fixed size network buffers and other
with variable size network buffers (still experimental).
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
EAP-FAST has extra requirements (TLS 1.3, session tickets etc) and is
seldom used, so, remove it from Enterprise list and add a separate
Kconfig option.
This solves the build error when Enterprise mode is enabled.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
- Fixes bug where the sample would only look at the first name type
and skip the rest.
Signed-off-by: Alexander Svensen <alexander.svensen@nordicsemi.no>
This commit deprecates passing of async signal in functions such as move
and set_target_position. As per the new API, the async signal has to be
set via set_async_signal.
If RAMPSTAT_POLL is activated then enable_constant_velocity_mode would be
able to raise signals like END_STOP_DETECTED & SENSORLESS_STALL_DETECTED.
This commit also adjusts shell script in order to test these signals.
Signed-off-by: Jilay Pandya <jilay.pandya@zeiss.com>
conn_mgr_tests were occasionally failing when executed under heavy load.
The reason for this are short timeout values used when waiting for
events - if executed under heavy load, the even might not be delivered
on time.
An obvious solution would be to simply increase the timeout, however
when testing it turned out the actual timeout value would need to be
pretty high to ensure tests reliability. Therefore, to avoid
unnecessary increase of the overall test execution time to protect
against rare edge cases, rework the event waiting mechanism to use
semaphore instead. The test cases will now specify the events they're
waiting for, and the event handlers will feed the semaphore if all
expected events have been delivered. This allows the increase the
maximum timeout when waiting for events, w/o affecting too much the test
execution time under normal conditions.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Use SW2 instead of SW3 for entering MCUboot serial recovery/USB DFU
mode. Holding SW3 during reset results in a NMI, causing the boot process
to halt.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
The `m2gl025_miv` is breaking the ci during the zbus integration tests. To
solve that in a meanwhile, this commit excludes the board from the
zbus integration tests.
Signed-off-by: Rodrigo Peixoto <rodrigopex@gmail.com>
The test_k_mem_map_unmap test requires some free physical pages
to work correctly. On qemu_x86_tiny, the physical memory is
artificially limited to test demand paging, which is 320KB as
of writing of this commit message. We also reserve 128KB of
physical memory as swapping area. And we do pin quite lot of
text and data (relatively speaking) in memory. There is not
much memory left for the test. So lower the amount of reserved
memory for paging to leave some pages for the test.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Test the new c-macros for dt enums. The new macros are already used in
the existing macros. As an example, DT_ENUM_IDX(node_id, prop) uses
DT_ENUM_IDX_BY_IDX(node_id, prop, 0) to get its result. However, this is
insufficient for testing the complete functionality of these macros.
Therefore, additional tests are added to make sure they work
appropriately for other indices besides 0.
Signed-off-by: Joel Hirsbrunner <jhirsbrunner@baumer.com>
The existing APIs for enums were rewritten to support the changes.
Additional macros were added to now also support getting specific
indices from the array / string-array.
The macros can be evoked the same way like before, since nothing changed
for the interface. Therefore, these changes are backward compatible.
Signed-off-by: Joel Hirsbrunner <jhirsbrunner@baumer.com>
Adjust existing tests to support the changes and add new tests to test
the newly added feature.
Signed-off-by: Joel Hirsbrunner <jhirsbrunner@baumer.com>
It is currently impossible to use enum with any array like type (i.e.
string-array and array, these are the only ones that make sense) in the
devicetree and dt-bindings.
However, there is no such remark in the dt-bindings section of the docs.
Since this is a feature that comes in very handy and is implemented
fairly easily, I adjusted the scripts for this.
It is now possible to do something like this.
```yaml
compatible = "enums"
properties:
array-enum:
type: string-array
enum:
- bar
- foo
- baz
- zoo
```
```dts
/ {
enums {
compatible = "enums";
array-enum = "foo", "bar";
};
};
```
Signed-off-by: Joel Hirsbrunner <jhirsbrunner@baumer.com>
Update the default memory maps for `nrf54h20dk` and `nrf9280pdk` to
remove the `shared_ram20_region` and `shared_ram3x_region` nodes,
because their child nodes no longer need to be grouped together:
* IPC buffers in RAM20 are statically allocated.
* DMA buffers in RAM3x have separate access owners.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Apply the following changes to `nrf54h20dk` and `nrf9280pdk`:
* Convert `perm-*` properties to the newly introduced `nordic,access`,
both in board files and tests.
* Redefine shared regions to specify multiple access owners per node,
and ensure that each such region is reserved by one domain at a time.
`cpuapp_cpurad_ram0x_region` is only enabled by Radiocore, while
`cpuapp_cpucell_ram0x_region` is only enabled by Application core.
* Divide `shared_ram3x_region` so that each sub-region is owned by a
different domain. Their addresses must be rounded down to fit the
current UICR format.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
This concerns both `nordic,owned-memory` and `nordic,owned-partitions`.
Introduce a property named `nordic,access`, which is meant to replace
the `owner-id` and `perm-*` properties. It allows for describing how
multiple domains should access a single memory region, possibly with
different permissions per owner, but without having to create more than
one DT node for this purpose.
This change is also motivated by updated memory protection requirements
on the nRF54H20, which mandate that a given memory region must only be
reserved by one domain, even if multiple domains can have access to it.
This restriction is now described in the binding itself.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
This creates a websocket based shell backend that is used to
implement a websocket console that can be connected using a browser.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Allow logging output to websocket console. Requires that
websocket shell backend and websocket HTTP server support
is also enabled.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Do not apply format setting unless needed. Also, correct the check for
the RGB565 format setting- the zephyr display API treats RGB565 and
BGR565 as big endian, so the format needed here is BGR565.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add support for using the SMARTDMA engine on the FRDM-MCXN947 board with
the video capture sample.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add support for SMARTDMA camera engine, and a OV7670 parallel camera
definition for the frdm_mcnx947 board. This support has been tested with
the video capture sample.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add support for LPI2C7. This peripheral is used for interfacing with
cameras connected to the J9 header.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add SMARTDMA video driver. This driver uses the SMARTDMA engine as a
parallel camera interface, which can read QVGA frames from a camera
device. Due to SRAM constraints, the video driver divides the camera
stream into multiple horizontal video buffers as it streams them back to
an application.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Improve resolution init code for OV7670 driver, to properly program the
full set of registers needed to realize a given output resolution. The
settings for these registers are based on those used in the MCUX SDK
driver, which are derived from the resolution register settings given in
the OV7670 programming guide, with a different configuration for the
CLKSRC and DBLV registers used for the input clock.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
The SMARTDMA is a programmable DMA engine, and supports custom firmware
in order to run complex DMA operations. Update the driver to increase
the flexibility users have when configuring the SMARTDMA with
custom firmware, and remove the RT500 display firmware specific
definitions and functionality from the driver.
This display setup is now handled from the MIPI DSI driver, since the
firmware used for this case is specific to the MIPI DSI IP.
This change also requires an update to the RT500 devicetree, as the
register definition for the SMARTDMA has changed, so the base address
must as well.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Handle line_offset field within video capture sample. Other samples do
not support partial framebuffers and therefore can ignore this field.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Since all video drivers in tree use a full frame, their video buffers
will always start at a line_offset of 0 within the frame.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add line_offset field to the video_buffer structure. This field
indicates the offset (in horizontal lines) within a frame that a video
buffer starts at. This is useful for video devices that produce or
consume video buffers that constitute a partial frame.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Update existing video drivers to handle the min/max line count field
within the video_caps structure. All drivers work with full frames
currently, so use the special LINE_COUNT_HEIGHT value to indicate this.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add min and max line count to the video_caps structure- these fields can
be used by applications to determine the size of video buffer they need
to allocate for a video endpoint
The min and max line count fields are designed to enable supporting
endpoints that may produce or consume partial frames within each video
buffer, and may support arbitrarily sized video buffers.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Fixed incorrect I2C register definitions in the test file
tests/drivers/build_all/sensor/i2c.dtsi.
Signed-off-by: Paweł Czaplewski <pawel.czaplewski@arrow.com>
TI tmp1075 driver implemented based on tmp108 driver.
The driver initializes the sensor based on the DTS.
Added tmp1075 example overlay file to thermometer sample.
All you need to do to use the sensor is to connect the I2C and
optionally interrupt line.
To see default DTS configuration option inspect `ti,tmp1075.yaml`
bindings file and sensor spec.
Signed-off-by: Paweł Czaplewski <pawel.czaplewski@arrow.com>
Add unit tests of the CCID functions.
To support these new tests, the GATT mocks need to
support dynamic GATT DB so we can add and remove
a service that contains CCIDs.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Move the CCID header to the include directory
to make it public.
This also compiles the ccid.c file whenver CONFIG_BT_CONN
is enabled, rather than having an additional Kconfig for it,
since the API is now public and may be used by other than
our internal services.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Rather than throwing an assert, it will now do a better
check for already-allocated CCIDs and return an error instead.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
alloc_value is more correct as it does allocate a new
value, rather than just returning/getting a value.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
This adds support for J-Link tunnels, which run on top of an IP network
and therefore uses the -IP option. J-Link tunnels are identified by a
tunnel: prefix instead of a bare IP address. This change checks for the
presence of such a prefix, and choses the -IP transport option if the
tunnel prefix is found.
This has been tested with J-Link Remote Server v7.98g and the SEGGER
tunnel option.
Signed-off-by: Adam Dunkels <adam@dunkels.com>
- Updates teensy board configs for use with new `eth_nxp_enet.c` driver
- Remove ethernet configs from teensy40 (4.0 has no ethernet phy)
- Adds a device entry to include `tests/drivers/build_all/ethernet/`
Signed-off-by: Bernhard Krämer <bdkrae@gmail.com>
The source code uses functions from stdio.h,
such as `sprintf()`, but they are not explicitly included
so that we will add it.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
The `default y`, which is coupled with
`depends on DT_HAS_REYAX_RYLRXXX_ENABLED` to link the settings with
DeviceTree, which was missing, so I added it.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Before unmapping a memory page, the cache is flushed. If the given memory
page is not mapped, this operation ends with a cpu exception on the
ptl platform. Add check if tlb translation is active before flushing.
Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
The sys_mm_drv_unmap_region_initial function is responsible for unmapping
all unused virtual memory during tlb driver initialization. Most addresses
will not have a mapped page. Ignore the error code indicating unmapped
memory that will occur when trying to unmap.
Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Enable LPI2C1 on the frdm_mcxw71 board which is connected to a
FXLS8964AF sensor (no driver for the sensor yet).
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
The external flash (mx25r64) was accidentally disabled during
testing. The node should be enabled by default like its spi.
This commit removes the status = "disabled";
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
like extra_confs, add extr_args filterable by
soc:<arch>:<extra_args> or
platfrom:<platform name>: <extra_args>
simulation:<simulator name>: <extra_args>
which will only apply to given platform or arch
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Create a macro that encapsulates all filtering and use it in standard
and hexdump macros.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Change logging level definitions to just numbers instead of
numbers with unsigned indicator (e.g. 1 instead of 1U). Levels
from Kconfig comes as just numbers and often levels are used
for IS_ENABLED-type of macros where values are concatenated
into tokens and it actually makes the difference if value is
1 or 1U. It allows minor cleanup in the internal macros.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
No real need to be enabling and disabling IRQs, this logic has been
reported to be causing spurious interrupts and strange behavior, we can
just enable the interrupt and switch to interrupt based logic one time
and keep the interrupt enabled at that point.
Also, fix a W1C bug where |= was used instead of = to clear a flag.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
SOC_FLASH_MCUX has additional dependencies for LPC55xxx CPUs, due to the
fact that the flash should be disabled when executing in nonsecure mode.
Since the merge of HWMv2, this dependency has been set incorrectly at
the SOC level, resulting in the IAP flash driver being enabled when
targeting CPU1, which is incorrect. Fix the Kconfig dependency to
resolve this issue.
Fixes#79576
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
The 11v_btm_query shell command was calling parse_number() using
a pointer to uint8_t. This will cause memory overwrite and possible
crash. Convert to use long temporary value to avoid this.
Fix also the output prints in case of an error.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Rework the wifi-shell code so that external subcommands can be
bolted into it easily. This means that the commands should be
created using SHELL_SUBCMD_ADD().
Place the various subcommands in alphabetical order to find them
more easily.
Split long lines in order to pass CI checks.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
This change makes sure that when a call to `bt_id_set_scan_own_addr` is
sucessful, i.e., the return value is 0, the `own_addr_type` will
be set by the `bt_id_set_scan_own_addr`.
Not setting the `own_addr_type` in a successful call to
`bt_id_set_scan_own_addr` causes, for example,
the `start_le_scan_ext` method in `scan.c` to use an
uninitialized `own_addr_type`.
Eventually this results in an unexpected failure further down in
`start_le_scan_ext`, when sending HCI command to controller with
an uninitialized `own_addr_type`.
Signed-off-by: Erik Sandgren <erik.sandgren@nordicsemi.no>
Allow using direct IRQs (which are obligatory when buiding
with `CONFIG_GEN_SW_ISR_TABLE=n`).
Signed-off-by: Marcin Szymczyk <marcin.szymczyk@nordicsemi.no>
Some deprecated inclusions in max32672.h are causing compilation
warnings, which are interpreted as errors by build tests. Grab relevant
fixes from hal_adi.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Modify the GAP connect to use 30ms. The default parameters
typically ended up with 50ms which is OK in most cases,
but for ISO related test cases, using an ACL interval that
is a multiple of the ISO SDU interval (7.5/10ms) generally
provides better stability. 30ms is the lowest multiple
of both 7.5 and 10ms, and was thus chosen.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
These two functions have stood the test of the time and they have
absolutely nothing specific to sign.py
This has the benefit of transitioning away from west's global and
deprecated logging interface
(https://github.com/zephyrproject-rtos/west/issues/149) and this
deprecation is what prompted this commit: see #79240.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Applies the 'unlikely' attribute to various kernel objects that
use z_unpend_first_thread() to optimize for the non-blocking path.
This boosts the thread_metric synchronization benchmark numbers
on the frdm_k64f board by about 10%.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
If there is a carrier (cable plugged in) on device initialisation
there is a race between the interrupt service and the L2 init.
Signed-off-by: Dean Sellers <dsellers@evos.com.au>
Like in all other legacy boards, hw-flow-control should not be
enabled for console UART. With hw-flow-control sample stuck
during printing some initial information and sample appears to
be not working correctly unless com port is opened.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
STM32F1 doesn't have synchronous/asynchronous source clock choice.
The recently added clock check was failing compilation for these series.
This commit removes the check for F1.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
The comparator drivers area contains the following incorrect area:
files:
- include/zephyr/dt-bindings/clock/
and contains the following duplicate area:
files:
- include/zephyr/drivers/comparator/
this commit removes them.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Board frdm_mcxc242 does not have UART IP configured.
Add UART configuration and pin control. Set state to disabled,
as it serves as alternative to default LPUART0 or as second
uart only. Add uart to supported features in yaml.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Removes extraneous word in note on net_context struct describing why the
source address is not stored directly in struct.
Signed-off-by: Daniel Mangum <georgedanielmangum@gmail.com>
This commit introduces a new option, OPENTHREAD_CLI_VENDOR_EXTENSION,
in the Zephyr OpenThread module to map the upstream option
OT_CLI_VENDOR_EXTENSION.
OPENTHREAD_CLI_VENDOR_EXTENSION option specifies the path to a CMake
file that defines and links the CLI vendor extension. By setting this
option, it enables the addition of vendor-specific commands to
the OpenThread CLI interface.
Signed-off-by: Lukasz Maciejonczyk <lukasz.maciejonczyk@nordicsemi.no>
Enabling all EAP types for enterprise mode increases
memory usage in both ROM and RAM. Provide config options for each
type to let solutions choose the methods based on their
requirements.
Signed-off-by: Ravi Dondaputi <ravi.dondaputi@nordicsemi.no>
Reduce the valid scaling range for the gain multipliers and dividers to
provide more headroom on int64_t overflows in the calculations. Take
advantage of this headroom to perform all multiplications before
divisions.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Change the unit of the sense resistor in the devicetree binding from
micro-ohms to milli-ohms. This is done for three reasons.
Firstly, the maximum value resistor that can currently be represented
is 4.2 kOhms, due to the limitation of devicetree properties to 32 bits.
Secondly, storing the resistance at such a high resolution makes
overflows much more likely when the desired output unit is micro-amps,
not milli-amps.
Finally, micro-ohms, are an unnecessarily precise unit for the purpose
of these calculations, and a resolution that is not realistic to
achieve. The high resistor resolution results in large divisors that
reduce the resolution of outputs. Unlike resistors characterised down to
the micro-ohm, devices wanting to measure micro-amps are actually
realistic.
Signed-off-by: Jordan Yates <jordan@embeint.com>
If the Broadcast ID is initially set to 0x000000,
which is valid, comparison logic on add of an
actual Broadcast ID of 0x000000 fails.
Likewise for SID.
Moving INVALID_BROADCAST_ID define to bap.h
Signed-off-by: Lars Knudsen <LAKD@demant.com>
The event is sent from both WPA supplicant and hostapd, but hostapd
should only be sent when using hostapd to create the AP.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Instead of having one large compile.sh for all audio samples,
it has been split into multiple. This makes it easier to
build and run specific tests (e.g. BAP or CAP), without
having to build all of them.
This also makes it easier to expand later, without
creating one huge compile.sh file.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
There is nothing like AMD-Xilinx Inc. That's why use full AMD name
instead.
Fixes: 09e2a4e9eb ("drivers: ipm: add zynqmp r5f support")
Co-developed-by: Mubin Sayyed <mubin.sayyed@amd.com>
Signed-off-by: Mubin Sayyed <mubin.sayyed@amd.com>
Signed-off-by: Michal Simek <michal.simek@amd.com>
Make clear in the include/ header that data frame size
is the same thing as word size for the context of this API.
Also, add some comments to the spi_context to make it easier
for driver writers to understand how to use the functions,
by noting the meaning of the dfs and len parameters to the update
functions. Otherwise it takes some time to understand what they mean.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Two ethernet capabilities were missing. Added them to allow
the 2.5G and 5G strings to appended.
Signed-off-by: Christoph Seitz <christoph.seitz@infineon.com>
The "struct video_driver_api" struct field "get_ctrl" had the wrong type
although this did not have any practical effect as "video_api_set_ctrl_t"
and "video_api_get_ctrl_t" have the same signature.
Signed-off-by: Josuah Demangeon <me@josuah.net>
Update to latest Sphinx RTD Theme version.
Main benefit will be to be able to leverage Sphinx 8.0 since previous
version of the theme was depending on 'sphinx < 8.0'.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add basic support for the phyBOARD-Nash, a SBC based on the phyCORE-i.MX93.
Both CPU types (Cortex-A55, Cortex-M33) are supported.
Signed-off-by: Jonas Remmert <j.remmert@phytec.de>
CONFIG_ZVFS_POLL_MAX is now used to control the maximum number of poll()
entires. Thereby, CONFIG_NET_SOCKETS_POLL_MAX is redundant and shall
be deprecated.
Modify the defaults for NET_SOCKETS_POLL_MAX and ZVS_POLL_MAX so that
the deprecation actually makes sense instead of symbol removal. In case
the application still sets the old config, it will modify the
ZVS_POLL_MAX default.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Currently Zephyr depends on POSIX, which presents a
dependency cycle.
Newlib does not seem to like this dependency cycle so it
requires that we re-declare off_t and ssize_t.
We should really stop using off_t and ssize_t below the
POSIX API line in Zephyr.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Several help prompts for non-user-selectable Kconfig options
included the phrase "select 'y' here", which does not make
any sense in this situation.
Adjust the help sections to use more appropriate language.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Mark the POSIX_DEVICE_IO Option Group as commplete. This Option
Group is required for PSE51, PSE52, PSE53, PSE54, and most of
the interesting applications involving file descriptors and
sockets.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Move the implementation of zsock_select() to zvfs_select(). This
allows other types of file descriptors to also make use of
select() functionality even when the network subsystem is not
enabled.
Additionally, it partially removes a dependency cycle between
posix and networking by moving functionality into a mutual
dependency.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Move the implementation of zsock_poll to zvfs_poll. This allows
other types of file descriptors to also make use of poll()
functionality even when the network subsystem is not enabled.
Additionally, it partially removes a dependency cycle between
posix and networking by moving functionality into a mutual
dependency.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Add pread() and pwrite() implementations, which are nearly
identical to read() and write() but differ in that they do not
update the file-descriptor offset and instead read from a
specific file offset.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The POSIX_DEVICE_IO Option Group requires a number of c89
functions mainly from stdio.h .
Namely,
clearerr(), fclose(), feof(), ferror(), fflush(), fetc(),
fgets(), fprintf(), fputc(), fputs(), fread(), freopen(),
fscanf(), fwrite(), getc(), getchar(), gets(), perror(),
printf(), putc(), putchar(), puts(), scanf(), setbuf(),
setvbuf(), ungetc(), vfprintf(), vfscanf(), vfprintf(), and
vscanf().
Additionally, symbols stdin, stdout, and stderr should be
provided.
These should be provided by any conformant C library
(not by the POSIX API).
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Only invoke vtable methods read, write, and close if they are
non-NULL.
The close() vtable method is optional, so that should not return
an error if zvfs_close() is called and that method is
unimplemented.
Otherwise, if zvfs_read() or zvfs_write() are called and the
corresponding vtable method is unimplemented, fail setting
errno to EIO.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Add common video interface binding. This binding contains the most
common properties needed to configure an endpoint subnode for data
exchange with other device.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
bindesc.h did not explicitly include device.h. For some build scenarios
this caused compilation warnings, failing the CI.
Signed-off-by: Yonatan Schachter <yonatan.schachter@gmail.com>
The variable config in sw_port_off() is not used, and it's
causing CI build error about unused variable. So remove it.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The NS variants need crypto changes from NCS, so, remove it from
upstream till their support is upstreamed.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Added tests for bindesc reading, to test reading on multiple C/C++
standards. Only RAM and flash backends are tested, as the flash
simulator can't simulate a memory mapped flash.
Signed-off-by: Yonatan Schachter <yonatan.schachter@gmail.com>
This commit adds support for reading and parsing binary descriptors.
It can be used for reading the descriptors of another image, or for
iterating over one's own descriptors.
Signed-off-by: Yonatan Schachter <yonatan.schachter@gmail.com>
Add a Kconfig symbol to limit the maximum size of a descriptor's
data, enforced by a build assertion.
Signed-off-by: Yonatan Schachter <yonatan.schachter@gmail.com>
Add `west bindesc get_offset` command to print the offset of
the descriptors inside the given image.
Signed-off-by: Yonatan Schachter <yonatan.schachter@gmail.com>
Prior to this fix the descriptors end tag was placed in the binary
using LONG. This was wrong because the tag is of type short, and
the size of the descriptor (0), should have also been placed.
It so happened that on little endian machines the incorrect linker
script yielded correct results, as the extra zeros added to make
the value a long ended up as the correct byte sequence
(FF FF 00 00). On big endian machines however, the wrong sequence
is generated (00 00 FF FF).
This patch correct this issue.
Signed-off-by: Yonatan Schachter <yonatan.schachter@gmail.com>
This patch changes GPIO initialization
to be in PORT_OFF state by default.
Also, if no transceiver is attached to the signals,
the GPIOs are configured to be disconnected to preserve power.
I tested this on a prototype board where we are going to have
a debugger in a low-power context.
Signed-off-by: Maximilian Deubel <maximilian.deubel@nordicsemi.no>
Add an example implementation of `get_fattime` to the API tests. Also
ensure that `FS_FATFS_EXTRA_NATIVE_API` compiles in a test.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Adds supporting code that allows the RAM load mode of MCUboot to
be used and for applications to build successfully with it.
Sysbuild can be used to build images for this mode
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Rework PM handling to use pm_device_driver_init(). Shim is not using
put and get internally as there is no api that disables or stops
pwm so it is hard to determine when to put the device. There are cases
when PWM peripheral is stopped but PWM is still active because
duty cycle is 100% or 0% and pin is driven by GPIO and not PWM.
If user want to use runtime PM with PWM it is possible and getting
the device will initialize internal data and putting will suspend
by forcing PWM stop if used and setting pins to sleep state. However,
from power consumption perspective it is enough to set 0% or 100%
duty cycle on all channels.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Shim was not correctly disabling PWM when it was not used. Task
STOP was triggered but PWM->ENABLE remained set which caused
increased current. Added interrupt and enabled event handler in
the nrfx driver to allow disabling PWM on STOPPED event.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Use NRFX_FOREACH_PRESENT macro to iterate over all PWM instances
and create device only for those enabled in the devicetree.
This approach removes need of changing driver code when new
instance id is added.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Supported memory attribute for device for Cortex-M.
Not sure why such code was conditional compile for only Cortex-R,
but Cortex-M also suited.
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Fix the DMAMUX driver for the STM32C0 HAL update. Typedef used in function
is now const.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
STM32C0 have a different prescaler for SYSCLK and for HCLK.
Updates the clock driver to use the appropriate prescaler for each series.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
What is changed?
1. Updated the data sync barrier to make sure the other parameters of
`arm_cpu_boot_params` are updated before updating its member `mpidr`
2. Updated the MPIDR affinity level mask to account for affinity level
1 and 2 along with level 0.
Why do we need this change?
1. As reported in issue #76182, on Cortex_A_R, the current code
execution fails to consider the correct sequence of data sync
barrier and cache maintenece for the code to work on non cache
coherent cores in SMP enabled mode.
The secondary cores are waiting in a loop for primary core to set
`arm_cpu_boot_params.mpidr`. As soon as primary core set this,
the secondary cores start reading other parameters from the
`arm_cpu_boot_params` however, the existing position of DSB
instruction doesn't guarantee that `arg`, `cpu_num` and other
parameters of `arm_cpu_boot_params` would be updated before `mpidr`
is udpated and this could lead to a unpredicatble behaviour so,
we need to move the DSB instruction.
2. The affinity level mask is updated because it didn't account for
level 1 to identify individual cores within a cluster and
level 2 to identify different clusters within the system which can
lead to an incorrect conversion between mpidr to core-id.
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
What is the changed?
CPU affinity test for SMP cores will now cover a change in ROM offset.
How is it changed?
Add a new testcase section with ROM offset set to something other than
the default 0.
Why is it change?
There is no test to cover the issue reported in #76182 and the cpu
affinity test is the closest to test the issue. Adding a new testcase
will makes sure there is no breaking change in the future.
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
What is changed?
Secondary cores can now boot successfully on cache and non-cache
coherent systems if the Zephyr image/vector table is loaded at an
address other than the default address 0x0.
How is it changed?
1. By calling the relocate_vector() from reset.S as part of EL1 reset
initialization instead of prep_c to have VBAR set for all cores and
not just for the primary core.
2. Remove dead code under CONFIG_SW_VECTOR_RELAY and
CONFIG_SW_VECTOR_RELAY_CLIENT.
Why do we need this change?
1. As reported in issue #76182, on Cortex_ar, VBAR is set only for
the primary cores while VBAR for the secondary cores are left with
default value 0.
This results in Zephyr not booting on secondary cores if the vector
table for secondary cores is loaded at an address other than 0x0.
VBAR is set in relocate_vector() so we move it to reboot.c which is
better suited to have configs related to system control block.
2. The two SW_VECTOR_RELAY configs have a direct dependency on
CONFIG_CPU_CORTEX_M, which is disabled while compiling for
Cortex-A and Cortex-R hence leading to a dead code.
How is the change verified?
Verified with fvp_baser_aemv8r/fvp_aemv8r_aarch32/smp.
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
Enables the XSPIM2 rail when using GPIO bank N
Enables the XSPIM1 rail when using GPIO bank O or P
Enables the USBvoltage detector when using the GPIO M
Signed-off-by: Francois Ramu <francois.ramu@st.com>
Change adds a release note informing about the newly introduced Kconfig
option for Bluetooth stack.
Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
Use a separate workqueue instead of system workqueue for connection TX
notify processing. This makes Bluetooth stack more independent from the
system workqueue.
Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
Fix build of nrf_qspi_nor flash driver without multithreading enabled.
This is required for builds like mcuboot.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Defining OPENOCD and OPENOCD_DEFAULT_PATH when we are using sysbuild
doesn't make any effect.
This updates flash.cmake to make these variables compatible with sysbuild.
Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
This commit updates picolibc module so that CMAKE_BUILD_TYPE is not
defined by picolibc when building with Zephyr.
The avoids a situation where both picolibc and Zephyr defines the
optimization level, for example like: `-Os -O2`.
And remove the warning:
> CMake Warning at .../zephyr/CMakeLists.txt:2166 (message):
>
> The CMake build type was set to 'MinSizeRel', but the optimization
> flag was set to '-O2'.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Remove explicit CAN controller sample-point/sample-point-data values and
instead rely on the defaults, as they change with the configured bitrate.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
Apply selection from the hash URL *after* having sorted the vendors
alphabetically.
Remove the initial call to updateBoardCount() as it is useless to
have one this early.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Fix a regression introduced at the last minute when cleaning up
the stylesheet. The rule as it was made no sense.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
It is undefined behaviour to shift / add offsets to a null pointer.
Move to direct offset tracking to satisfy UBSAN.
Simple translation of code:
buf0 -> buf
buf +=/++ -> offset +=/++
buf = -> buf+offset =
Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
The stm32l4 devices were previously assigned the generic STM32 AES driver,
which turned out to be incompatible with the stm32l4 series. This commit
updates the nodes to use the new driver specifically designed for this
series.
Add missing node for stm32l4a6, stm32l4q5, stm32l4s5 and stm32l486 socs.
It appears stm32l4p5 and stm32l496 socs do not have the AES accelerator
present, so the nodes are removed from the dts files.
Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
This patch resolves compiler warnings related to mismatched pointer types
between the STM32L4 and generic STM32 AES HAL by introducing CAST_VEC
macro.
Fix github CI warning
Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
This patch completes the addition of support for the STM32L4 AES
accelerator by introducing conditional handling for different STM32 AES
HAL variants. Key changes include:
- Created device tree bindings `st,stm32l4-aes` for STM32L4 AES
- Replaced `copy_reverse_words` with `copy_words_adjust_endianness`
to handle endianness conversion for different variants.
Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
This patch introduces a unified function pointer approach to handle
encryption and decryption operations for the STM32 AES accelerator.
- Replace separate `do_encrypt` and `do_decrypt` functions with a generic
`do_aes` function, using function pointers to AES HAL functions.
Signed-off-by: Lucas Dietrich <ld.adecy@gmail.com>
Drop preprocessor redefinitions
Some preprocessor defines were redefined to follow
stm32 hal naming conventions.
People seems to be confused by redefines and use
them with alternating names.
This PR does not change code behaviour,
but shall increase it's readability.
Signed-off-by: Alexander Kozhinov <ak.alexander.kozhinov@gmail.com>
Add support for PM. The strategy is as follows:
1) For level 1 interrupts: don't care, these don't
require the PM domain of irqsteer to be turned on
since they are, well, direct.
2) For level 2 interrupts: use the reference count
of the dispatchers.
Upon doing a get() on a dispatcher with its reference count
set to 0, before enabling the IRQ (meaning accessing the
reg. space) increment the reference count of the irqstr device
(which will result in the PM domain being enabled if 0).
Upon doin a put() on a dispatcher with its reference count
set to 1, after disabling the IRQ (meaning accessing the
reg. space) decrement the reference count of the irqstr device
(which will result in the PM domain being disabled if 0).
In summary, the PM domain of the device will be enabled if
at least one dispatcher is in use. On the other hand, the
PM domain of the device will be disabled if there's no
dispatchers in use (assuming there's no other dependencies).
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
IRQs are currently only enabled during the driver
initialization function (i.e: sai_init()). As such,
even though they're not needed (i.e: after a TRIGGER_STOP
operation) they remain enabled. Fix this by enabling IRQs
after during the TRIGGER_START operation and disabling them
during the TRIGGER_STOP operation.
This change is required by irq chips (i.e: irqsteer) which
perform PM operations during irq_enable()/irq_disable(). If
interrupts are left enabled all the time that means the irq
chip's PM resources might also remain enabled.
To make this change possible, the irq will have to be stored
inside the SAI's configuration structure.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
IRQs are currently only enabled during channel setup
and never disabled. As such, even though they're not
needed (i.e: after a channel has been suspended or stopped)
they remain enabled. Fix this by enabling IRQs during the
channel start() operation and disabling them during the
channel stop() operation.
This change is required by irq chips (i.e: irqsteer) which
perform PM operations during irq_enable()/irq_disable(). If
interrupts are left enabled all the time that means the irq
chip's PM resources might also remain enabled when not needed.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Currently, all dispatcher interrupts are enabled during
the driver init() function, which will cause a bus fault
unless the PM domain associated with irqsteer is powered on.
Since PM will be done during irq_enable()/irq_disable(),
add support for dynamically enabling/disabling dispatchers.
This way, the reg. space of the dispatchers will be accessed
when the PM domain is powered on.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Currently, shared interrupts pose a big problem because
irq_disable() doesn't keep track of the number of clients
using that interrupt line. As such, add a reference count
mechanism which will stop the interrupt from being disabled
if there's still clients using it.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Testcase execution time doesn't match between twister.xml and
twister.log. Testcase execution time is the sum of the previous
testcases' execution time plus its own execution time in
twister.xml.
This patch fixes the issue above.
Signed-off-by: Ioannis Damigos <ioannis.damigos.uj@renesas.com>
NPCX9 and former chips defines two kinds of sub-power-states to support:
1. Standard wake-up time: if the chip needs to stay in the deep sleep
state more than 200 ms.
2. Instant wake-up time: if the chip needs to stay in the deep sleep
state less than 200 ms.
As NPCX4 can stay in the deep sleep state at more than 200 ms with the
instant wake-up capability, we can define only one sub-power state.
Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
Remove the unnecessary video-controls header included in video.h.
Drivers, applications should explicitly include it when needed.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Add entyr mentioning the deprecation of the nxp, prefixed properties
in the nxp,kinetis-acmp dts binding.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Update the devicetree binding for the nxp,kinetis-acmp comparator and
move the binding to dts/bindings/comparator.
The update to the binding includes:
- Remove unused io-channel-cells property
- Remove unused sensor-device include
- Adding missing properties dac config, discrete mode config, and
input configs.
- Rename properties to exclude redundant vendor prefix since props in
this binding are not inhereted, and as such, don't need to be
namespaced.
- Deprecate the old names of the renamed properties
The sensor based device driver has been updated to support both the
deprecated and new property names. This allows it to use both
nxp,enable-sample and filter-enable-sample for example.
Additionally, remove the unused io-channel-cells properties from
in-tree nodes of compatible = "nxp,kinetis-acmp"
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
The mcux_acmp will get support by the comparator subsystem. To avoid
namespace clashes, namespace the driver, kconfigs and use the
MCUX_ACMP config solely to select the MCUX SDK driver.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Add comparator build_all test suite designed to test multiple
devicetree overlays and boards for each comparator device driver.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Adjust comparator nodes of nrf SoCs to exclude the unused
io-channel-cells property and simplify the comment describing how
to configure the comparator hardware block as COMP or LPCOMP for
SoCs which support this.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Add top level CMakeLists.txt entry and Kconfig options along with
userspace handlers for comparator API.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Provide a mechanism to propagate useful arguments from one runner to the
next. The primary use case for this is to propagate a JLink serial
number, so that if it is queried from the terminal the user only needs
to make the choice once.
Implements #76077.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Clarify that the actual calls to these backend functions are made
from `settings_save_subtree()`, which is called by `settings_save()`
or can be used directly.
Signed-off-by: Nerijus Bendžiūnas <nerijus.bendziunas@astrolightspace.com>
Port80 notifications are continously generated as long as NOT_EMPTY
bit inside of Data Attributes register is set. This register was only
read once prior entering loop and its value was not checked on each
iteration.
This patch will include reading Data Attributes register on each
iteration, this way we can exit loop when no more data is available.
Signed-off-by: Bernardo Perez Priego <bernardo.perez.priego@intel.com>
The code in shell_ops.c that calls telnet_write will assert if it
returns non-zero. For a telnet shell it's normal that the
network might disconnect unexepectedly, so that should not
trigger an assert.
Fixes#67637
Link: https://github.com/zephyrproject-rtos/zephyr/issues/67637
Signed-off-by: Kevin ORourke <kevin.orourke@ferroamp.se>
Fixes garbage characters on mcuboot by adjusting UART baudrate
during boot phase according to clock source.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Full name was set based on the information available either in board
documentation or in Twister files.
Whenever applicable, vendor name was dropped from the full name so that
all boards have a consistent naming scheme.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The ENTDAA does not have a way to assign DA that are with a PID. It will
assign DAs that were in it's RRs in the order that they win arbitration.
Assign only available addresses in to it's RRs before ENTDAA.
Cleanup the attach api to no longer require a addr argument and remove
the helper function `i3c_determine_default_addr`. This now looks at if
it has a static address or if it already has a dynamic address (such as
from DEFTGTS) and will register the address if either exist with
precidence of dynamic addr over static addr.
This also fixes up the look up for if a device already has a dynamic
addr to find which pos of the RRs is it is in.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Update build_info() calls to use `PATH` argument when values passed to
`build_info()` are user specified and thereby might use native path
separator, such as a single `\`.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Support PATH argument in build_info() function.
The PATH argument can be used to provide a list of paths paths and that
those paths might be using native style, such as `c:\win\path', and
therefore should be converted to CMake style path.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
This improves context switching by 7% when measured using the
thread_metric benchmark.
Before:
**** Thread-Metric Preemptive Scheduling Test **** Relative Time: 120
Time Period Total: 5451879
After:
**** Thread-Metric Preemptive Scheduling Test **** Relative Time: 30
Time Period Total: 5853535
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Overflow errorcode is now correctly detected when expected.
Subsequent sensor_channel_get() yield the same values, so
the check can be no longer ignored.
Added a sensor_sample_fetch() where missing for correct
sensor_channel_get() calls.
Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
QDEC sensor driver fails to inform user of the overflow in the
ACC register, which makes the most recently fetched data invalid.
An error code return has been added to nrfx_qdec_sample_fetch(),
that indicates that an overflow has occured, based on oveflow flag.
Also, raw_acc field was added in the qdec_nrfx_data structure, to
adjust QDEC to sensor API rules - two subsequent sensor_channel_get()
calls should will yield the same values.
Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
mcxc242 has lptmr, pit and rtc counters, but it is not documented and
not listed in frdm_mcxc242.yaml.
Add the counters to board documentation, to the yaml file, and enable
it explicitly in board dts. Set rtc clock to 32 kHz oscillator.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Counters configuration is missing in Devicetree for NXP MCX C series.
Add lptmr, rtc and pit configuration to Devicetree.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Notifying users that the supplied timeout is being ignored is worthy of
a higher log level than debug. Any such usage should be changed at the
application level.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Notifying users that the supplied timeout is being ignored is worthy of
a higher log level than debug. Any such usage should be changed at the
application level.
Signed-off-by: Jordan Yates <jordan@embeint.com>
In case of UATT, if a connection was lost while user was holding a read
or write attribute callback, `bt_l2cap_send_pdu` (called from
`att.c::chan_send`) will anyway queue a PDU and trigger tx work. The PDU
won't be sent eventually, but neither will hold an error code, which
will allow it to bypass the error check in `att_on_sent_cb` and call
`att_sent` function.
For EATT `bt_l2cap_chan_send` is used which already handles this case
and the error code is passed to `att_on_sent_cb`.
This change adds connection state check to `bt_l2cap_send_pdu`
preventing from unnecessary code execution when connection does not
exist anymore.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
The timeout state is local and can block new ATT operations, but does
not affect the remote side. Disconnecting the GATT connection upon ATT
timeout simplifies error handling for developers. This reduces rare
failure conditions to a common one, without needing special cases for
ATT timeouts.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
Fix build error in DPP struct when building Matter over Wi-Fi.
The struct declaration must be done outside of the anonymous union.
Only struct definition can be done inside the anonymous union.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
The format of wpa_passphrase and sae_password is wrong when start the
SAP, which leads the invaild MIC check error when other STA try to
connect in security mode. Change the wrong format can fix this issue.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
DT_REG_ADDR now generates an unsigned string terminated with U
which doesn't match the way the macros is used in a CONCAT
to build a FMC_BANK1_(1/2/3) define that is defined in hal.
`DT_REG_ADDR_RAW` should now be used to get the RAW FMC bank index
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
add references to images of boards already present in the
index.rst files (for nucleo_u083rc, nucleo_u031r8, stm32u083c_dk)
so that they can be displayed in the documentation.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Random MAC address setting can never be configured as the two defaults
cover all cases. Fix the defaults, now the order is
* Fixed
* OTP (default, in case of no config)
* Random
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Add optional statistics around the channel publishing action. Store the
time a channel was last published to, and a total publish count.
This information can be used to determine how old a given channels data
is, and an average channel publishing frequency.
Signed-off-by: Jordan Yates <jordan@embeint.com>
This commit adds support for generating an interactive catalog of all
the supported boards that can be included in the documentation using
the `.. zephyr:board-catalog::` directive.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add some controls:
- hue
- saturation
- brightness
- contrast
- gain
- hflip
- vflip
- power line frequency filter
- pixel rate (read-only) which is needed for changing frame rate
Signed-off-by: Farah Fliss <farah.fliss@nxp.com>
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Add support for 4 test pattern modes:
- Color bar
- Color bar rolling
- Square
- Square rolling
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Add some minor fixes and optimizations:
- Fix coding style
- Rename some variables
- Use the array variable size directly instead of defining a macro
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Signed-off-by: Trung Hieu Le <trunghieu.le@nxp.com>
Color bar is one type of test patterns. Rename it to
VIDEO_CID_CAMERA_TEST_PATTERN to be more generic.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
Add some control IDs:
- VIDEO_CID_CAMERA_HUE
- VIDEO_CID_POWER_LINE_FREQUENCY
- VIDEO_CID_PIXEL_RATE which is needed for changing frame rate
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
ZBus currently does not have a `HEAP_MEM_POOL_ADD_SIZE_ZBUS` when using
message subscribers or runtime observers, forcing the developer to set that
manually. Adding the configuration option to zbus would improve its
usability and make zbus easier to use. With this feature, zbus aligns with
the other Zephyr subsystems' heap memory allocation approach.
Signed-off-by: Rodrigo Peixoto <rodrigopex@gmail.com>
Make the blinking and fading parameters adjustable so that samples
can be run on devices that support only short periods.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
If the `divider-int-0` or variations of these for each channel properties
are not specified, or if these is 0,
the driver dynamically configures the division ratio by specified cycles.
The driver will operate at the specified division ratio if a non-zero
value is specified for `divider-int-0`.
This is unchanged from previous behavior.
Please specify ``divider-int-0`` explicitly to make the same behavior as
before.
In addition, the default device tree properties related to the division
ratio have been removed.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Now that hostap is used k_heap, it needs to reserve the kernel heap not
libc heap.
Fixes#79477.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
This was we can modify it in a single place that works both for native
and OS specific code.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Title of the document was wrong, image info was missing, and a bunch of
other formatting issues.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
- update the EVK's board.cmake, making linkserver the default runner
- update the board's document file
Signed-off-by: Yves Vandervennet <yves.vandervennet@nxp.com>
Fix M1 errors seen with HDR-DDR writes, M1 errors we seen between CRC
and HDR exit sequence. The fix was to set Bit-8 of HDR-DDR CRC TXFIFO
word.
Signed-off-by: Naveen Gangadharan <naveeng1001@meta.com>
Add scan cb to scan delegator so that Application
can be notified when assistant starts or stops
scanning.
Also state information of Broadcast Assistant
is removed as info is not used.
Signed-off-by: Nithin Ramesh Myliattil <niym@demant.com>
The recently introduced board.full_name property can now be used as part
of the format string in the `west boards -f ...` command.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
NXP mcxc series has boot source configured to ROM. ROM bootloader
waits 5 sec for active peripheral detection timeout before jumping
to application in flash which makes booting very slow.
Change configuration to boot from flash and allow boot source
selection by external pin.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
msghdr_non_empty_iov_count() is used by TLS sockets too therefore should
be available regardless of native IP sockets being enabled or not.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
When CONFIG_LOG_OUTPUT is set, it indicates that logging strings
are formatted by the application (using log_output module). It is
not needed when backend works in the dictionary mode. So far
LOG_OUTPUT was set also when dictionary mode was used and that
prevented removing of the logging strings from binary which is
an important feature of the dictionary logging.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Move log_output_flush and log_output_write (renamed internal
buffer_write() function) to the header as inline functions.
Those function are used by log_output_dict.c and there are cases
when log_output.c is not compiled in.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
IPv6 based interface lookups doesn't require native IP stack support,
hence reflect that in the API.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Some tests are failing on nrf54h20 cpurad in non-obvious manner
because of this memory region being too small.
Instead of adding overlays to each individual application,
make this region larger at expense of cpuapp equivalent.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
All Intel Audio DSP platforms have non-coherent cache between
CPUs. So the zbus_channel struct data goes out-of-sync between
CPUs with multiple producer and consumer threads running
concurrently on multiple CPUs, resulting in bad pointer being
used, e.g. passed to memcpy(). So exclude these platforms from
running in twister as they are certain to fail.
Fixes: #79368
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Service for powering peripherals that use GPIO pins
in the global power domains:
- Active Fast
- Active Slow
- Main Slow
Signed-off-by: Rafal Dyla <rafal.dyla@nordicsemi.no>
Add netif:eth to twister yaml for frdm_rw612
Exclude from wifi test because of binary blob requirement
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
IAP is a reference to the method of software interaction with the flash
used in the current driver implementing support for this flash. The
DT compatible should not be named like this.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Fix incorrect elapsed events value when event prepare are
aborted in the pipeline. This caused premature supervision
timeouts.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix BT_CTLR_SCAN_AUX_SYNC_RESERVE_MIN such that event is not
aborted when near supervision timeout conditions.
Relates to commit ddf04997a5 ("Bluetooth: Controller: Add
abort fairness in overlapping Periodic Sync").
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Introduce BT_CTLR_PERIPHERAL_ISO_RESERVE_MAX Kconfig option
so that disabling this option will use minimum time
reservation and exercise the peripheral ISO connection event
continuation using is_abort_cb mechanism.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Introduce BT_CTLR_PERIPHERAL_RESERVE_MAX Kconfig option so
that disabling this option will use minimum time reservation
and exercise the peripheral connection event continuation
using is_abort_cb mechanism.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
This inverts x and y axes as reported by stmpe811 driver for stm32f429i.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
This adds zephyr,touch property to boards with touch controllers, analogous
to `zephyr,display`.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
The sample is supposed to help examine the issues with touchscreen.
It draws a plus in last touched position.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
seperate the autohandler from the main
hawkbit source. This way the autohandler can
be disabled if it is not needed.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
Add function to get the poll interval.
This is needed to seperate the autohandler
from the main hawkbit code.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
* Setting the adv data, scan rsp and adv aux ad data can happen on
overlapping buffers
* There can be other memcpy's that need to be changed to memmove but
these are the only ones I could reproduce the issue and since memmove
has a performance penalty, I left the others as is.
Signed-off-by: Yago Fontoura do Rosario <yafo@demant.com>
Remove the `work_q` parameter from `NET_SOCKET_SERVICE_SYNC_DEFINE` and
`NET_SOCKET_SERVICE_SYNC_DEFINE_STATIC` as this feature was dropped
during review but the removal was not 100% complete.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Added a generic function `z_shell_backend_rx_buffer_flush` to clear
the RX buffer when resuming the shell. The function repeatedly calls
the backend's `read` API until the buffer is empty or a maximum of
1000 iterations is reached. This prevents unintended command
execution after `shell_start`.
Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@verkada.com>
Trigger bsim tests also on changes to the MbedTLS module code in Zephyr
side. To avoid possible regressions in bsim tests when this code is
changed getting into main.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Add crypto module test kconfig option
CONFIG_WIFI_NM_WPA_SUPPLICANT_CRYPTO_TEST,
which is default n and hidden.
It is only available by developer for crypto module test.
Signed-off-by: Fengming Ye <frank.ye@nxp.com>
Decoder was casting uint8_t pointers to uint64_t pointers which could
result in double word instruction which does not support unaligned
access on Cortex-M. Issue was revealed when -O3 optimization was
used instead of -Os. In size optimized version, compiler was
using word load and store instructions which support unaligned
access and issue was not visible.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
This reverts commit ec7943bb18.
This commit introduced a regression.
Let's revert it so we do not block development in main.
For more information see:
https://github.com/zephyrproject-rtos/zephyr/issues/79594
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
As in all other esp32-based boards, APPCPU
does not require to have MINIMAL_LIBC as default libc.
In the past, that was required due to memory constraints,
which is not the case anymore.
This fixes build issues in `tests/lib/c_lib/common`.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
To improve performance in FCS calculation, this commit replaces
the usage of the generic `crc8` function with the specific `crc8_rohc`
function in `modem_cmux.c`.
The `crc8_rohc` function utilizes a small table approach, enhancing
the efficiency of CRC-8/ROHC variant calculations while optimizing
memory usage.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Replace `zassert` with `zassert_equal` in CRC8-CCITT and CRC8-ROHC
test cases, as `zassert_equal` is more appropriate for comparing
actual and expected values.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
This commit introduces the `crc8_rohc` function to the CRC library,
implementing the CRC-8/ROHC (RObust Header Compression) variant.
This algorithm is widely used in networking protocols, which is commonly
found in modem subsystems.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
This driver depends on its mboxes to be initialized, or the build
will fail like this:
ERROR: Device initialization priority validation failed, the sequence of \
initialization calls does not match the devicetree dependencies.
ERROR: /ipm <ipm_mbox_init> is initialized before its dependency \
/mailbox0@31f80000 <omap_mailbox_0_init> (POST_KERNEL+0 < \
POST_KERNEL+2)
Lift its priority to device level.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Modify the BAP unicast client callback structure to be a
linked list. The purpose of this is to have multiple listeners
of the unicast client changes and notifications.
This is needed for the CAP initiatior.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Convert the compilation of the trigger type feature to depend
on Kconfig, following the same pattern of software-triggered
interrupt.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Implement `riscv_plic_irq_set_pending()` to trigger a
software-generated interrupt.
The "4. Interrupt Pending Bits" of the riscv-plic specs
described the reading of the pending bits, but not the writing
Since not all PLIC implementations support software-generated
interrupt, the function is compiled only when
`CONFIG_PLIC_SUPPORTS_SOFT_INTERRUPT` is enabled on PLIC that
supports it, such as the Andes' NCEPLIC100.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Add a new `andestech,nceplic100` binding that inherits from the
`sifive,plic-1.0.0` binding. This is so that the Kconfig
`DT_HAS_ANDESTECH_NCEPLIC100_ENABLED` would be generated during
build.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Gdb is typically able to reconstruct the first two frames of the
failing stack using the "pc" and "lr" registers. After that, (if
the frame pointer is omitted) it appears to need the stack pointer
(sp register) to point to the top of the stack before a fatal
error occurred.
The ARM Cortex-M processors push registers r0-r3, r12, LR,
{possibly FPU registers}, PC, SPSR onto the stack before entering the
exception handler. We adjust the stack pointer back to the point
before these registers were pushed for preservation in the dump.
During k_oops/k_panic, the sp wasn't stored in the core dump at all.
Apply similar logic to store it when failures occur in that path.
Signed-off-by: Mark Holden <mholden@meta.com>
The function jwt_payload_len doesn't return payload length but returns
used data in builder->buf
If jwt_payload_len is called after jwt_init_builder, header length will
be returned
If jwt_payload_len is called after jwt_add_payload, header+payload
length will be returned
If jwt_payload_len is called after jwt_sign, header+payload+sign length
will be returned
So, this commit removes the function and uses strlen instead
Signed-off-by: Benjamin Lemouzy <blemouzy@centralp.fr>
Update JWT subsystem documentation concerning the changes related
to:
- default library used
- new Kconfigs added
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
- Some files (PEM/DER files, jwt-test-cert.c, user-tls-conf.h)
were removed because they are not used or no longer necessary.
Private keys used in the test are now in the jwt-test-private.c
file as arrays.
- testcase.yaml has been improved in order to test all possible
use cases: ECDSA with TC, ECDSA with PSA, RSA;
- unnecessary Kconfigs were removed from prj.conf.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
This commit:
- creates 2 new files, jwt_ecdsa.c and jwt_rsa.c, to hold the
implementations of the corresponding ECDSA/RSA signature
algorithms;
- RSA signature is stil done through Mbed TLS's PK module which
can optionally make use of PSA (if enabled);
- ECDSA signature will instead use PSA, if possible, or TinyCrypt
as fallback.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
Sometimes there's an unusually large cycles for tests that are
known to complete with just a few cycles. Upon some testing,
I found that it was because the overhead cycles was larger
than the cycles taken by tests, causing the cycles to
underflow.
To workaround that, make sure that the overhead measurement
thread runs uninterrupted, repeat the measurement for a few
times, and take the minimum value.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Fix of the subnet bridging table function to only
compact the table if elements has been removed, and
fixing the compact function to compact the table if
several elemnts has been removed at the same time.
Fixes zephyrproject-rtos#78794
Signed-off-by: Ingar Kulbrandstad <ingar.kulbrandstad@nordicsemi.no>
No need to reset in cfg link, this was blocking system workqueue during
phy callbacks that call cfg link, since this happens from monitor work
handler which is in the system workqueue.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
There is a check to see if it is no longer able to push more
messages into a full queue. When these is another CPU consuming
messages, the queue would not be full at that point. A new message
can be pushed into the queue and thus failing the "full queue"
check. So limit this to 1 CPU only so this check's assumption
can be fulfilled.
Fixes#79319
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The previous NET_EVENT_SUPPLICANT_CMD_INT_EVENT is from
"enum net_event_supplicant_cmd" but the supplicant_send_wifi_mgmt_event()
has the event parameter as an "enum net_event_wifi_cmd" and those event
number spaces are different.
This meant that the wrong event value NET_EVENT_SUPPLICANT_CMD_INT_EVENT
maps to NET_EVENT_WIFI_CMD_TWT (from "enum net_event_wifi_cmd") which
fortunately did not cause issue in this case because the
supplicant_send_wifi_mgmt_event() has no handling for this TWT event value.
It is important we fix this as this can cause great confusion in the
future.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Version 2 of the ADAC interface implemented by secure domain firmware
changes the ADAC RESET command used in the custom reset handling in
the JLink support scripts. The command has been split into two
commands, RESET and START, and has different semantics from
the previous RESET command. The new RESET command resets both the
application and radio domains without starting the CPUs again, and the
START command must then be used to start the CPUs.
Update the JLink support scripts for nrf54h20dk/nrf54h20/cpuapp,
nrf54h20dk/nrf54h20/cpurad, nrf9280pdk/nrf9280/cpuapp and
nrf9280pdk/nrf9280/cpurad so that they read out the ADAC interface
version from the device and use the newer commands if ADAC version 2 is
detected. If the version is lower than 2, the legacy implementation is
used.
Also improve the CTRL-AP MAILBOX transaction implementation
to avoid the need for arbitrary sleeps or unnecessary polling of
the MAILBOX. This should improve stability when using the script.
Signed-off-by: Jonathan Nilsen <jonathan.nilsen@nordicsemi.no>
Industrial 8 channel output with advanced diagnostics.
Allowing giagnostic configuration both on per channel or global bases
In SPI communication diagnostic status transmitted on every
READ/WRITE which includes generic status of chip.
Diagnostics includes :
* Oveload
* Open Wire
* Over current
* Short to VDD
* Thermal Shutdown
* VDD Warn
* Watch Dog Error
* Communication Error
* VDD under voltage
Add app.overlay for MAX14916 driver.
Tested with adopted basic/blinky example.
Signed-off-by: Stoyan Bogdanov <sbogdanov@baylibre.com>
MAX14906 industrial 4 channel Input/Ouput GPIO expander with diagnostics.
Per channel diagnostics for open wire, over current.
Global diagnostic for power supply, communication and various fault
conditions.
Signed-off-by: Stoyan Bogdanov <sbogdanov@baylibre.com>
MAX14906 in 4 channel I/O with advanced diagnostic.
In SPI communication diagnostic status transmitted on every
READ/WRITE which includes generic status of chip.
Configuration both on global level and on per channel bases.
Diagnostics includes :
* Thermal overload
* current limit
* open wire detection
* short to VDD
* Above VDD
* Safe DEmagnitization fault
* VDD warning
* VDD low
* SPI/CRC Error
* WDog Error
* Loss GND
Add app.overlay for MAX14906 driver.
Tested with adopted basic/button and basic/blinky sample.
Signed-off-by: Stoyan Bogdanov <sbogdanov@baylibre.com>
The Modbus protocol object types are either single-bit or 16-bit word.
Other types are not defined in the specification. Types such as float
are typically mapped to two 16-bit registers. Current implementaiton
does not maps correctly to the 16-bit word addresses. On the client
side, the implementation must take into account that the number of
requested registers (Quantity of Registers) is double that of a "float"
register. The server side should not treat "Quantity of Registers" and
"Byte count" differently for addresses reserved for floating values,
only in the user callback the two 16-bit registers are mapped to a float
value but still aligned to 16-bit register addresses.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Adds a signing page under build, which contains information on
how to sign images from the build system, this removes the old
details for using west sign with imgtool from the west sign page
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Uses imgtool directly to sign images instead of calling west sign,
this also removes the MCUBOOT_CMAKE_WEST_SIGN_PARAMS Kconfig option
as this has no effect
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Adds a Kconfig which can be selected when building for firmware
updater mode to select if this is the application or the firmware
updater image that is being built
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Save information regarding SVD file in use in vendor-specific section
of the build info file.
Information is stored under Nordic section.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Store informations regarding the current Zephyr build.
The following informations are stored during CMake configure:
- Board information
- Application source directory
- Application configuration directory
- Toolchain information
- Devicetree files
- Kconfig config files
- Zephyr version
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
For pristine builds 'west build' will now create a build_info.yml file
containing the west build command including arguments.
This is done to help users and external tools to recreate builds.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
The build_info function provides a generic and stable way of dumping
build information to the <build>/build_info.yml file.
The build info file is in YAML format and the keys in the file are
intended to be stable, as to allow external tools to retrieve
information regarding the build.
The main differences to the CMakeCache.txt are:
- Settings in the CMakeCache.txt are user controlled, whereas the
information in the build info file is intended to be those values
which are used by the build system regardless if those are specified
by the developer or picked up automatically.
- Internal build system variables are not present in the CMake cache
and should not be, because their values are calculated when CMake
runs.
This also has the benefits of decoupling CMake variable names from
build info keys. Several CMake variables has internal build system
names, and the build system is free to rename those at its own
discretion.
Having dedicated key names ensures a stable API that external tools can
rely upon.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Move Zephyr CMake script mode handling from package_helper.cmake into
extensions.cmake.
This ensures that all Zephyr CMake script which includes
extensions.cmake will have the same functions stubbed or mocked and thus
does not need to replicate this behavior.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Other toolchains uses <toolchain>_TOOLCHAIN_PATH, align Zephyr SDK
by setting ZEPHYR_TOOLCHAIN_PATH to be identical to the
ZEPHYR_SDK_INSTALL_DIR.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
IPv6 MLD API was so far defined in an internal header. This does not
seem correct though, as application code should be able to join/leave
multicast groups, hence the API should be exposed in a public header,
just as it is done for its IPv4 countepart - IGMP.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
When building an LLEXT-enabled kernel, 62b19ef65c added weak aliases
of all syscall implementation functions to a pointer to NULL, with the
assumption that LLEXT would check the required symbols at link time and
fail if any of them were found.
This check, however, is ineffective in the current implementation: the
actual address that is exported is the rather normal-looking location of
the variable containing the NULL pointer. This defeats the NULL symbol
validity checks in llext_link.c and causes the extension to crash at
runtime by jumping to a location containing a few zeroes in read-only
data memory.
This commit makes sure the alias target is actually placed at address 0
using the llext-sections.ld linker fragment, so that undefined syscall
implementations are exported as NULLs and as such properly flagged at
link time.
The test for this functionality is also updated to reflect the change.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Whenever FW blobs are updated manually, we need to tell cmake to
auto-build the source files to use the latest firmware without doing a
pristine build.
This adds a custom target to be run with nRF Wi-Fi driver and updates
timestamp of fw_load.c to rebuild whenevr the blob is updated.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
This script is needed only when external flash is used to store nRF70
firmware patches. This also uses PM which is supported only in NCS.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
For using external flash the tooling is only available in NCS, so, use
the existing Kconfig option to override the FW loading.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Building the net logger backend with IPv4 only gives the following
warning:
log_backend_net.c:116:31: warning: array subscript 'struct sockaddr[0]'
is partly outside array bounds of 'struct sockaddr_in[1]'
[-Warray-bounds] local_addr->sa_family = server_addr.sa_family;
hence assign the address family directly to sockaddr_in/6 structs.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
The sample uses net_config library, so there's no need for the sample to
configure unicast IP addresses manually.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
In case CONFIG_DNS_RESOLVER_MAX_SERVERS is larger than the actual number
of DNS servers configured, some server entries may be left
uninitialized. The dispatcher needs to take this into account, otherwise
it may cause memory corruptions.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Refactor the code to comply with:
Violation to rule 5.7 (Tag name should be unique) tag: data
Rename the structure to avoid excessive refactoring.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Building the sample with IPv4 only gives the following warning:
tcp.c:99:37: warning: array subscript 'struct sockaddr[0]' is partly
outside array bounds of 'struct sockaddr_in[1]' [-Warray-bounds]
data->tcp.sock = socket(addr->sa_family, SOCK_STREAM, IPPROTO_TCP);
This doesn't really seem like a valid one, but to get rid of it
workaround by specifying address family explicitly.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
The checks did not properly take into account
that the pref_pd_min and pref_pd_max could have valid
0 values.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
There are many places where source_id is retrieved and it
depends on runtime filtering being enabled. So far it was
all exposed but lets encapsulate that into a helper function.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Streamline the `rc` return logic in `nvs_flash_wrt_entry()`, `nvs_gc()`
by directly returning `rc`, as the redundant conditional check and
explicit return of 0 were unnecessary.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Full name or description of a board is something we are missing in
HWVv2. It is right now being added to yaml files parsed by twister. This
should be generically available to tooling and documentation
independently from twister.
As we rework how twister parses board meta-data (#77250) and how we
generate board documentation (#79160), this becomes neceassry.
Moving the board full name/description from the twister yaml files to
the board.yaml is something we can automate once the schema is agreed
upon.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Change log level to fixed value coherent with macros used in the
test (LOG_INF). Use context struct to better organize global
variables and improve code readability.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
The host-based adv auto-resume function has both a problematic
implementation and disagreement in the community around how it should
behave. See the issue linked resolved below for details.
This patch makes the deprecation visible to the user. The user will be
better served by a auto-resume tailored their applications use case,
based on more primitive host API like `conn_cb.recycled`, which has
obvious behavior that is unlikely to change.
Resolves: https://github.com/zephyrproject-rtos/zephyr/issues/72567
Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
Disable CDC ACM logging in the configuration overlays used to select the
CDC ACM UART as the shell backend.
The build warning was introduced by the commit e8c4867806
("usb: cdc_acm: disable logging if used for shell with logging")
to prevent recursive logging when using the CDC ACM UART as shell or
logging backend
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Add a flash copy command, capable of copying a region in one
flash device to a region on the same or another flash device. The
destination is erased prior to copying.
This is useful for evaluating mcuboot on devices with little
on-chip resources, or devices that are incapable of running more
elaborate image management services (e.g. via bluetooth or
networking).
Additionally, it's useful for evaluating mcuboot on devices with
one or more images stored on external spi flash.
The command syntax is
flash copy <src_dev> <dst_dev> <src_offs> <dest_offs> <size>
E.g.
flash copy flash@0 flash-controller@abcd1234 0x1234 0x5678 21012
Copied 21012 bytes from flash@0:1234 to \
flash-controller@abcd1234:5678
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
test_flash_erase() requires that the expected[] array contains
pseudo-random data. However, the expected[] array would only
be initialized once before all tests are run using the setup
callback.
Instead, use the before() callback to randomize data before
each test in the suite, since there is otherwise no guarantee
that test_flash_erase() will be run directly after the
expected[] array has been randomized.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Provide a generic flash_copy() algorithm that is capable of
copying from one flash device to another or within different
regions of the same flash device.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Some counter drivers do not support alarms, so I added testcase which
starts the counter, checks if the value is in range after certain time and
stops the counter, to check if the counter is running correctly.
Signed-off-by: Krystof Sadlik <krystof.sadlik@nxp.com>
Co-authored-by: Michal Smola <michal.smola@nxp.com>
Adding the macros `RA_CGC_CLK_SRC` and `RA_CGC_CLK_DIV` that derive
the BSP clock settings from the DeviceTree node settings.
I also define some aliases to fill in the gaps with the BSP
naming conventions.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Move the process of replacing numerical values with macros to
the header, and set the division ratio in a numeric without
using macros in the device tree.
Change `clk-div` defined in `renesas,ra-cgc-pclk.yaml` to `div`.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
DeviceTree typically references the clock source using the `clocks`
property defined in `base.yaml`, so we'll change it to this.
Also delete the custom clock source definitions in
`renesas,ra-cgc-pclk-block.yaml`, `renesas,ra-cgc-pclk.yaml`, and
`renesas,ra-cgc-pll.yaml`.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Changes the path name of a DTS node so that it can be used
as the stem of a BSP macro.
All nodes to be changed are referenced via labels,
so only the name is changed.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Like some other string properties, I will add a derived form
to FULL_NAME to make it easier to reference from macros.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Extend the `coap_transmission_parameters` struct with the field
`ack_random_percent`. This was the last remaining CoAP transmission
parameter that was not configurable at runtime.
Signed-off-by: Adrian Friedli <adrian.friedli@husqvarnagroup.com>
The ztest.c calls atoi, which is provided by the C standard library.
Remove the conditional inclusion of the C standard library with the
definition of CONFIG_ZTEST_SHUFFLE.
Signed-off-by: Firas Sammoura <fsammoura@google.com>
dcache-alignement needs to be defined for ipc to have
consistent memory organization on both endpoints, when
shared memory is cacheable. nrf54h20 and nrf9280 are
using cacheable shared memory.
This is applied for ipc with icmsg backend.
Signed-off-by: Lukasz Stepnicki <lukasz.stepnicki@nordicsemi.no>
Verbatim from USB 2.0 specification:
The Remote Wakeup field indicates whether the device is currently enabled
to request remote wakeup. The default mode for devices that support
remote wakeup is disabled. If D1 is reset to zero, the ability of the
device to signal remote wakeup is disabled. If D1 is set to one,
the ability of the device to signal remote wakeup is enabled.
The Remote Wakeup field can be modified by the SetFeature() and
ClearFeature() requests using the DEVICE_REMOTE_WAKEUP feature selector.
This field is reset to zero when the device is reset.
Signed-off-by: Benedek Kupper <kupper.benedek@gmail.com>
When building with `MBEDTLS_PSA_CRYPTO_C` enabled, compile in the
PAKE (Password-authenticated key exchange) implementation.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Disable CDC ACM logging in configuraton overlay used in test case
bluetooth.shell.cdc_acm.
The build warning was introduced by the commit e8c4867806
("usb: cdc_acm: disable logging if used for shell with logging")
to preven recursive logging when using the CDC ACM UART as shell or
logging backend
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Implements a set of tests designed to show how the performance of the
three scheduler queue implementations (DUMB, SCALABLE and MULTIQ)
varies with respect to the number of threads in the ready queue.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
Implements a set of tests designed to show how the performance of the two
wait queue implementations (DUMB and SCALABLE) change as the number of
threads in the wait queue varies.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
To reduce lint warnings during code review, it is best
to keep clang-format happy
This commit makes a lint pass to this driver
Signed-off-by: Rafael Laya <rafael_laya97@hotmail.com>
Adds the right clock settings for Fast Plus Mode
in the i2c Designware driver which the original author
left as a TODO. Similarly, I lack the hardware to test
high-speed mode, and so that mode remains not well
supported.
Signed-off-by: Rafael Laya <rafael_laya97@hotmail.com>
Commit b73c5578e3 ("soc: ti: move init code from SYS_INIT to hooks")
changed SYS_INIT to init hooks. For AM6x M4 target soc_prep_hook()
was added by mistake instead of soc_early_init_hook(), the platform needs
RAT translation initialized before any other operation and the platform
failed to boot with this change, fix this by replacing with
soc_early_init_hook()
Signed-off-by: Vaishnav Achath <vaishnav.a@ti.com>
Having the lowest possible interrupt priority is causing the
tests\arch\arm\arm_irq_zero_latency_levels test to fail.
This test reserves 2 priority levels for the low latency interrupts.
Since CYW20829 supports 3 interrupt bits, 6 becomes an invalid
value when 2 levels are reserved for the low latency interrupts.
Signed-off-by: Sreeram Tatapudi <sreeram.praveen@infineon.com>
Follow-up: #78320
Create linker_libraries.cmake for the Cadence Xtensa xt-ld linker to
ensure correct linking of runtime and C libraries as well as correct
link order.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Updating PhyBOARD Polis docs after enabling ECSPI
and CAN support on that board.
Add additional information what to do if
using Linux and Zephyr simultaneously.
Signed-off-by: Peter Fecher <p.fecher@phytec.de>
Configures ECSPI devices in devicetree including connected
mcp2518 (CAN FD).
Configures pinctrl for board.
Enables spi support in board files.
Signed-off-by: Peter Fecher <p.fecher@phytec.de>
Some imx8 socs have cpu cluster entries for cores that
are not currently supported. Remove them.
Fixes#79027.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
The TPM max channel number was got from register array size.
However some platforms TPM instance may begin from TPM1 rather
than TPM0. This should be handled in driver.
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Property "block-cycles" is required for node "zephyr,fstab,littlefs",
but source code did not get the value from dts file, now add it.
Additionally correct the wrong description of property "block-cycles"
in binding file.
Signed-off-by: Paul He <pawpawhe@gmail.com>
For code clarity, this commit adjusts the use of `return` statements
in functions with a void return type by:
- Remove unnecessary `return` statements when
they don't affect control flow.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Unified switch-case usage in `uart_ra_sci_b_callback_adapter` to use
`break` instead of `return`.
Typically, a `break` is used in switch-case statements unless an early
return is necessary, in which case `return` is appropriate.
For this case, using a `break` statement is the more suitable choice.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
nRF54H HAL is not compatible with C++98, add new board revisions to the
list so that they are skipped.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Add a new revision for nRF54H20 DK: 0.9.0. This new hardware spin contains
the final nRF54H20 SoC. Treat it as the default, including twister.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The current DK is labeled as revision 0.8.0. Until now, no revisions were
needed, but a new hardware spin is coming, so we'll need to keep at least
two revisions in the near future until the final one becomes the default.
Prepare the board for that scenario. Note that the "old" nRF54H20 SoC is
now nRF54H20 EngB.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
nRF54H20 EngB is a re-label to the existing hardware revision for the
nRF54H20. nRF54H20 (whithout EngX) is becoming the final revision of the
SoC.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The new GRTC reading manner of the SYSCOUNTER uses hardware mechanism which
allows to keep it alive when any of CPUs is not sleeping. Otherwise
the SYSCOUNTER goes into sleep mode. Thus there is no
longer need to maintain the `CONFIG_NRF_GRTC_SLEEP_ALLOWED` symbol, however
if the user wants to have the SYSCOUNTER enabled all the time the
`CONFIG_NRF_GRTC_ALWAYS_ON` can be used instead.
The nrfx_grtc driver no longer provides the `wakeup-read-sleep` reading
manner.
Also setting the GRTC clock source is performed by the nrfx_grtc driver so
it has been removed from the `sys_clock_driver_init()` function.
Signed-off-by: Adam Kondraciuk <adam.kondraciuk@nordicsemi.no>
Some enums have been renamed:
- NRF_CCM_EVENT_ENDCRYPT -> NRF_CCM_EVENT_END
- NRF_CCM_TASK_CRYPT -> NRF_CCM_TASK_START
Also adjust some TX power level settings (26/28dBm not always available
depending on the SoC revision).
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
This is required if boards make use of such definition in their Kconfig
files. In Kconfig.board.v2, only `boards/Kconfig.v2` is loaded, but
BOARD_REVISION is part of `boards/Kconfig`, which can't be loaded in this
context.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The goal of this commit is to reduce the overall test time by optimizing
the time spent sleeping.
However while doing so, a few glitches became apparent and those have
been fixed as well.
1. The way the ZSOCK_POLLIN event is managed has been modified
In most tests, the event would stick for the whole test and this would
sometimes results in the client receiving more data than intended which
in turn would results in various unexpected warnings and errors.
The management of the ZSOCK_POLLIN event has now been mostly moved to
the send/receive overrides which better represent how things would
happen outside of the test scenario.
For example, when sending data, if this send would normally result in
receiving some response, the send function sets the ZSOCK_POLLIN event.
Then when receiving, we clear the event as the data has been received.
There are a few exceptions to this for cases where we need to simulate
some specific abnormal behavior.
2. The `messages_needing_response` queue now includes a valid bit
The test manages a queue of messages id to be able to respond to the
correct id in the receive hooks.
It was built in a way that the id 0 would be treated as invalid
although it is a valid id.
In practice, it would not be an issue in most cases however, it would
result in an unexpected behavior if the `test_multiple_requests` test
would be run first.
To fix this issue in the simplest way, the queue has been changed to
uint32_t which gives us 16 extra bits for the management of the queue,
1 of which is used to tell if the entry is valid or not.
Signed-off-by: Francois Gervais <francoisgervais@gmail.com>
Since CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC is tied to the slow RTC clock
for the nRF53, use the default SYSCLK of 64MHz instead.
Signed-off-by: Maximilian Deubel <maximilian.deubel@nordicsemi.no>
Fixes MCUBoot Serial Recovery compilation error
"Serial recovery/USB DFU button must be declared
in device tree as 'mcuboot_button0'"
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
PHYTEC currently supports five boards in Zephyr, with another in
development. Given the growing interest from our customers and our
commitment to expanding support for PHYTEC platforms, I am
volunteering to take over the maintenance of these boards.
This will help streamline contributions and reduce the workload on
the silicon vendor maintainers.
Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
Front picture was listed twice, despite the back picture
(max32666fthr_img2.jpg) actually being checked into the repo, so switch
to that one.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
A response returned after a request times out would increment the
semaphore and stay until the next request is made which will immediately
return when k_sem_take is called even before a response is returned. This
will once again have the same problem when the actual response arrives.
So the wait semaphore just needs to be reset before transmitting.
Signed-off-by: Abram Early <abram.early@gmail.com>
Correct several inconsistent parameter names in the following functions:
- stm32_gpio_intc_select_line_trigger: rename `trigger` to `trg`
to match the header file.
- stm32_gpio_intc_set_irq_callback: rename the callback argument to `user`
to match the `stm32_gpio_irq_cb_t` type.
- stm32_exti_get_line_src_port: rename `pin` to `line` to align with
the Doxygen comment and implementation.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Using a separate workqueue causes issues without any special locking to
synchronize with networking threads e.g., interface being removed while
the workqueue is trying to synchronize with WPA supplicant.
It's easier to use the net_mgmt thread which is in better sync with
networking.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In case of error conditions post successfully sending the message, the
event is already freed but we attempt to free it again.
Rejig the labels to easily reflect thier purpose.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
When an event is sent the receiver gets is asynchronously and hence is
responsible for free the event, the sender should only free in case of
error conditions i.e., unable to send.
Else, this causes a tough to debug double-free.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
In case WPA supplicant disabled DPP, we need to compile out the
corresponding DPP code in Wi-Fi shell too.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
These priorities can be resolved automatically with the sub-priority
mechanism, so set them to the same value.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
This prevents recursive logging loop when USB CDC ACM is used for shell
with logging.
Change affects both USB stacks.
Signed-off-by: Xudong Zheng <7pkvm5aw@slicealias.com>
Update the migration guide to indicate that the STM32 ADC that selects an
asynchronous clock also need to set a domain clock.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Update ADC bindings documentation to state that a domain clock is now
necessary if asynchronous clock is selected.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Add a compile-time check to verify that a domain clock is explicitly
defined if a STM32 ADC is configured to use an asynchronous clock.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
For all STM32 boards that define an asynchronous clock for ADC, specify
which clock is to be used in the clock node.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
For STM32L1, U5 and WBA, the ADC always uses an asynchronous clock source,
so we add the default clock source in the clock node.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Fix assertion when enabling simultaneous multiple Extended
Advertising chain reception that is enabled by increasing
supported auxiliary scan contexts.
ULL sets the association of aux context to scan and sync
context, and LLL resets the association; this is safer
compared to earlier implementation where ULL did both the
association and reset which caused aux context memory
leak.
Supported auxiliary scan contexts can be increased using
CONFIG_BT_CTLR_SCAN_AUX_SET value.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Adds a semaphor to make sure the stream has properly been stopped by the
controller before returning from btp_bap_broadcast_source_stop.
Signed-off-by: Frode van der Meeren <frode.vandermeeren@nordicsemi.no>
One needs the 32bit version of the SDL development library when
building for 32bit native_sim, and for the 64bit native_sim the
64bit version. Let's clarify this.
Also fix the SDL2 link.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
It includes both the high-level documentation of the subsystem and
that of APIs defined in code (PSA Secure Storage and internal APIs of
the subsystem).
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Add a sample to demonstrate use of persistent keys in the PSA Crypto API.
The implementation of the PSA ITS API that allows storage of persistent
keys is provided either by the just-introduced secure storage subsystem
or by TF-M.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Add a sample to demonstrate direct use of the PSA ITS API.
The implementation of the API is provided either by the just-introduced
secure storage subsystem or by TF-M.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Add one suite to test the PSA ITS API directly, and another to test it
through the PSA Crypto API.
The PSA ITS API test suite is run with different configurations to also
test customization possibilities that the secure storage subsystem offers.
Both test suites also have a test scenario with TF-M instead of the
secure storage subsystem.
This serves as compatibility testing to ensure that the PSA Secure
Storage API behaves the same from the user's point of view regardless
of the underlying implementation provider.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
With the secure storage subsystem now providing an implementation of
the PSA ITS API, let Mbed TLS use it when it's enabled.
This allows the use of persistent keys in the PSA Crypto API.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Fixes the systemview tracing backend for soc families, such as max32,
that don't subdivide into soc series and therefore don't define
CONFIG_SOC_SERIES. Use CONFIG_SOC_FAMILY instead in the system
description since it should always be defined.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
Sets CONFIG_HAS_SEGGER_RTT on the max32 soc family to allow using RTT
backends in the logging, shell, and tracing subsystems.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
x86 architectures require a dynamic stack size that is a multiple
of 4096 bytes due to mmu restrictions.
For example, this test would previously fail when using the
default dynamic stack size of 1024 bytes for 32-bit
platforms.
```
west build -p auto -b qemu_x86/atom/nopae -t run \
tests/posix/common/ -- -DCONFIG_USERSPACE=y
```
It would pass with an additional argument
```
west build -p auto -b qemu_x86/atom/nopae -t run \
tests/posix/common/ -- -DCONFIG_USERSPACE=y \
-DCONFIG_DYNAMIC_THREAD_STACK_SIZE=4096
```
Add a special default for x86 when using dynamic thread stacks.
The x86 default removes the need for `boards/qemu_x86*.conf`,
with the exception of `qemu_x86_tiny`.
qemu_x86_tiny did not have sufficient memory (or configuration)
to run the non-userspace tests, so bump up the available ram
from 256k to 512k for this test and clone the .conf from the
demand paging tests.
Eventually, the common posix test should be split into more
concise functional categories.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The `cmd_wifi_dpp_ap_auth_init` function was added but is not yet
aligned with others.
This update enhances consistency with the following changes:
- Unified the order of declaration for `opt`, `opt_index`,
`state`, and `long_options`.
- Wrapped lines in the `long_options` declaration to prevent them
from extending too far to the right.
- Applied `struct option` as `static const`
- Unified the wrapping of `getopt_long` calls, regardless of
the length of the `options` string.
- Using `getopt_state` to access `optarg` and also `optopt` offers
a better alternative to direct global access.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
The `ident` of L2CAP BR connection req will be cleared if
function l2cap_br_conn_req_reply called to send L2CAP BR
connection rsp with result `BT_L2CAP_BR_PENDING`.
Then the invalid `ident` (it is zero) will be filled in
the L2CAP BR connection rsp after the ACL connection is
encrypted.
Recover `ident` if the result of the connection rsp is
`BT_L2CAP_BR_PENDING`.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Currently, error code `-ENOTSUP` will be
returned if start security with security
level 4.
For SC supported case, level 4 for ssp
should be supported.
Remove the code limitation to support
security level 4.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
The flags of L2CAP_CONFIGURATION_REQ are set.
But in L2CAP_CONFIGURATION_RSP, all bits of
flags are cleared.
When used in the L2CAP_CONFIGURATION_RSP
packet, the continuation flag shall be set
to one if the flag is set to one in the
Request.
Copy flags from Request to Response if it
is a successful result.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Currently, Only configuration opt MTU is handled.
For opt `Flush timeout`, `QOS`, `Retransmission
and Flow Control`, and `FCS`, response wilt
result `BT_L2CAP_CONF_UNACCEPT`.
For opt `extended flow specification` and
`extended windows size`, response wilt result
`BT_L2CAP_CONF_REJECT`.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
The `BT_L2CAP_CONF_SUCCESS` is returned as result for the config
req with supported opt.
Result `BT_L2CAP_CONF_UNKNOWN_OPT` should be returned for this case.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
PR #78645 replaced uses of the GNU keyword `__thread` with a new macro
`Z_THREAD_LOCAL` which expands to correspond C/C++ standard keyword if
applicable, else it falls back to `__thread`.
This PR addresses some missed replacements in headers files for #78645.
Signed-off-by: Daniel Flodin <daniel.flodin@iar.com>
The sample currently doesn't build for non-secure nRF platforms due to
mbed TLS misconfiguration - TFM enforces PSA crypto API, while the
default configuration for supplicant uses legacy crypto configuration.
In result, build fails due to unsatisfied dependencies. Therefore,
disable this variant from building temporarily to unblock the CI, until
the issue is resolved.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Introduce support for 'uint64_t' type, so that unsigned numbers
can be serialized into JSON payloads.
Signed-off-by: Mykhailo Lohvynenko <Mykhailo_Lohvynenko@epam.com>
Some IBI TIR packets can be larger than the ibi data fifo size
which can prevent it from receiving the full packet. This adds
a data struct in to the driver data where data can be pushed
to as data is being transfered.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
HEAP_MEM_POOL_ADD_SIZE_BOARD is not a zephyr-defined entry and
should be placed into Kconfig instead of Kconfig.defconfig.
This PR moves that entry for all ESP32-based boards accordingly.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
This reverts commit 88f6851a3d.
This is being reverted because it is redundant with the capabilities of
zephyr,memory-region and zephyr,memory-attr properties.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Added other nxp boards as test targets:
frdm_ke17z, frdm_ke17z, frdm_ke17z512,
rddrone_fmuk66, twr_ke18f,
twr_kv58f220m, frdm_mcxn947/mcxn947/cpu0,
mimxrt1062_fmurt6, vmu_rt1170.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
Add documentation about supported displays on this board, as the list is
getting rather long and each display has its own bespoke connection
requirements.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Enable the rd_rw612_bga board with the LCD_PAR_S035 shield. This shield
cannot be connected directly to the board, but the connection can be
made with a set of jumper wires.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
The LCD_PAR_S035 display module shares the reset pin between the display
module and the touchscreen controller. The touchscreen controller needs
the reset pin to be toggled low during boot in order to select the
expected I2C address. However, the reset sequence must occur before the
display is initialized. To enable this, set a custom INPUT driver init
priority when using this display module, so that INPUT drivers start
after MIPI DBI drivers but before DISPLAY drivers.
Since the reset sequence is now operating as expected, we no longer need
to use the alt-addr probing method. This method was previously only
working correctly because boards using this display were configuring
the display INT pin using the pin control API prior to resetting the
display, so when the display was reset it would select the alt-addr
I2C address.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Enable support for 8 bit 8080 mode in the NXP LCDIC driver. Support
for programming the minimum duration of the write active/inactive signal
is also added, since this will be required to support high display
clocks in 8080 mode.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Update ST7796s display driver to respect the setting of rgb_is_inverted
in 8080 8 bit mode, as it was previously not applied for this mode.
Also, simplify the logic check for 16 bit mode- the new check is
functionally equivalent, but no longer inverts both boolean values.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Although the parallel mipi dbi mode pinout used for the LCD PAR S035
display is specific to NXP boards, the definition of the display is
generic, and does not require NXP-specific parallel mipi dbi IP.
Therefore, rename the MIPI DBI node for this display from
`nxp_flexio_lcd` to `zephyr_mipi_dbi_parallel`. The gpio-nexus node name
is unchanged, as the pinout it describes is specific to NXP.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Fixed escaping of double quotes, backslashes, and new line characters
so they can be used in string properties.
Previously, double quotes and backslashes were escaped in gen_defines.py
but not in gen_dts_cmake.py, and new lines were not escaped in either,
so using any of these characters would break the build.
Signed-off-by: Joel Spadin <joelspadin@gmail.com>
GCC 12.2.0 can give this warning (version 11.4.0 did not), when
CONFIG_SPEED_OPTIMIZATIONS=y
subsys/net/lib/http/http_client.c: In function 'http_send_data.constprop':
subsys/net/lib/http/http_client.c:114:33: warning: 'strncpy' specified
bound depends on the length of the source argument [-Wstringop-truncation]
114 | strncpy(send_buf + end_of_send,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
115 | data + end_of_data,
| ~~~~~~~~~~~~~~~~~~~
116 | remaining);
| ~~~~~~~~~~
subsys/net/lib/http/http_client.c:87:41: note: length computed here
87 | remaining_len = strlen(data + end_of_data);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
The code properly checks that we do not overwrite the destination
buffer even if we use the source buffer length to determine how much
to copy. One possible fix is to use memcpy() or strcpy(), I opted
to use memcpy() because it has the length option which feels more
natural.
Fixes#79326
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
`arcmwdt`` and `clang` both have
`-Wno-missing-field-initializers` in `warning_dw_1` and
`-Wmissing-field-initializers` in `warning_dw_2` while `gcc`
has `-Wmissing-field-initializers` in `warning_dw_1`, so
update it to match.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
When CONFIG_LLEXT_EXPORT_DEVICES is not enabled, the DEVICE_DT_DEFINE
macro ends with the contents of the Z_DEVICE_DEFINE macro, which always
includes a terminating semicolon.
When CONFIG_LLEXT_EXPORT_DEVICES is enabled, the macro ends with
Z_DEVICE_EXPORT, which does _not_ include a terminating semicolon. This
leads to a syntax error in places where the DEVICE_DT_DEFINE macro is
used without it.
Fix this by adjusting the added code when CONFIG_LLEXT_EXPORT_DEVICES is
enabled to include a semicolon after the Z_DEVICE_EXPORT macro; also use
the opportunity to remove a stray backslash.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Include EXPERIMENTAL tag in the kconfig text and remove the word
"support" to align with other options
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
Makes it easier to make sure the CS test code is removed if desired.
It should hopefully allow for a clean split in general.
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
Adds support for:
- LE CS Subevent Result event
- LE CS Test End Complete event
For now, recombination of subevent results with more steps than could
fit within a single HCI event is not supported, and such events
are discarded.
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
Update zephyr-lang-rust module to include commit for linking the
runtime library before the librustapp.a.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Newlib or Picolibc libraries for LLVM may be compiled or installed from
pre-built sources independently of LLVM itself.
This means that always indicating that TOOLCHAIN_HAS_NEWLIB=OFF and
TOOLCHAIN_HAS_PICOLIBC=OFF are wrong. But it could be just as wrong to
always indicate suport for newlib or picolibc.
Some pre-built LLVM toolchains are provided with default picolibc
support, such as LLVM for Arm embedded, but can also be used with newlib
be installing newlib add-on package.
Unfortunately it's not possible to query LLVM regarding newlib or
picolibc support.
Developers have the option of `-DTOOLCHAIN_HAS_<NEWLIB|PICOLIBC>=ON`,
but this is not widely known and cumbersome to do for each build.
An indication of newlib or picolibc support is the presence of library
specific headers, so to improve current situation we check for library
specific headers, and if those are present we assume support for the
library.
This commit improves the current support for LLVM in Zephyr when
cross-compiling, especially for users of LLVM for Arm embedded.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
This commit updates picolibc module to remove the need for hard-coding
linking with `-lgcc`.
Instead it sets the c_library linker property and thereby allows the
Zephyr toolchain infrastructure to properly handle the linking of
C and runtime libraries.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Moving specs argument to compiler and linker properties so that the
compiler and linker in use can decide how the flags are mapped / handled
for the compiler and linker in use.
This avoids specifying `--specs=spec.picolibc` for clang which prints a
warning about an unused argument.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
The `check_set_linker_property()` and `set_linker_property()` takes a
target argument. Make the target argument optional and use the target
`linker` as default target.
The function name `set_linker_property()` already implies that we are
setting a property and the linker target.
Remove the need to specify `TARGET linker` when using the default linker
property target.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Extend zephyr_link_libraries to allow an optional value together with
the `zephyr_link_libraries(PROPERTY <property> [<value>])`.
This allow setting linker property combined with a value when linking
Zephyr. The value will only be applied if the property is defined.
Extend zephyr_compile_options to support the same PROPERTY flag that
has been introduced for zephyr_link_libraries().
This remove the need for developers to write complex generator
expressions for compiler flags and thus minimizes mistakes.
The following syntax is now supported in addition to the existing
syntax: `zephyr_compile_options(PROPERTY <property> [<value>])`
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Zephyr is a bare metal build where standard libs are disabled.
This means that c and runtime libraries must manually be linked in.
This has generally been handled by using CMake's link libraries handling
but the issue with that is both de-duplication but also library link
order.
Standard libraries must be linked at last location to ensure symbols
are always available, however this is not optimal with
target_link_libraries() because this would ultimately require every
library to know the c library to link with, which is not desired.
Therefore, setup standard C and runtime library linking in linker
CMake files for toolchains where this is required.
This commit expands the principle introduced with toolchain abstraction,
see PR#24851.
This means that a toolchain implementation may specify standard C,
runtime, C++, etc libraries, as well as their link order.
Because a property approach is used, then Zephyr modules, such as the
Picolibc module can adjust such properties.
An optional `zephyr_linker_finalize()` macro is called at the end of
Zephyr's CMakeList process and can be used by the toolchain
implementation to define the final linker invocation.
This aligns the linker handling flow to the principle introduced in
PR#24851 and improves the flexibility and robustness of Zephyr build
system.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Currently, the linker that is used when performing various cmake checks
(check_c_compiler_flag, for example) may be different than the linker that
will be used during the actual build. This happens as we currently specify
'-fuse-ld' to force the appropriate linker a) after many such checks have
already happened and b) in a way which is not automatically propagated to
check_c_compiler_flag (and friends). As a result, the toolchain's default
linker will generally be used for such checks regardless of which linker
was selected in Zephyr.
This can lead to a number of surprises when building Zephyr, particularly
when building with clang. For example:
- If the linker is misconfigured, where the build will fail can vary
depending on whether the linker is the toolchain's default. When the
configured linker happens to be the toolchain's default, the build
(helpfully) fails quickly on the checks for a basic working toochain.
When the configured linker isn't the default, the build won't fail until
the final link steps.
- The build can fail due to issues with a linker other than the one
configured by the user in Zephyr. For example, LLVM toolchains without
lld will generally fail to build Zephyr (the checks for a basic
working toochain will fail) for targets where lld is the default in LLVM
even if GNU ld is configured in Zephyr and would otherwise be used in the
final build.
- Flags which are only added if check_c_compiler_flag (or similar) succeeds
may be unexpectedly omitted during the final build if the flag is
supported in the configured linker but is unsupported in the toolchain's
default linker (as check_c_compiler_flag will test using the default
one).
Note that this isn't limited to clang--even when we are building with
Zephyr's SDK and force ld.bfd, we seem to use the 'ld' variant during the
cmake checks (though this generally seems fairly harmless compared to
mixing ld/lld or other proprietary linkers).
To fix this, ensure the appropriate 'fuse-ld' is set early enough and in
such a way that the same linker will be used throughout the entire build.
Signed-off-by: Jonathon Penix <jpenix@quicinc.com>
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
The QoS structure is not related to a codec, but rather a
stream, and should thus not use the "Codec" name.
The BAP and ASCS specs refer to the QoS as
"QoS configuration" several places, so it is an obvious
choice for a name.
Since the structure is defined and used by BAP, the prefix
was changed from bt_audio to bt_bap.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The size of the output array for the find call in resolver
is invalid: expected array size while overall memory size
provided. As the latter is bigger there is a high probability
of memory overwrite occurring on the stack.
Signed-off-by: Krzysztof Bartnicki <krzysztof.bartnicki@embevity.com>
The `CONFIG_PLIC_IRQ_AFFINITY` depends on `CONFIG_SMP` in the
Kconfig layer, nested #ifdef can be avoided for readability.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The functions to obtain the address are hardcoded to return
the address of the first core when `CONFIG_SMP != y`, this
causes an issue with enabling an IRQ when there are more than
one core in the system (`CONFIG_MP_MAX_NUM_CPUS > 1`), as the
driver would first enable the IRQ on the first core, and when
it tries to obtain the address for the following cores and
disable the IRQ on them, the functions continue to return the
address of the first core, causing the IRQ to be disabled
on the first core.
Fix this by determine if `CONFIG_MP_MAX_NUM_CPUS > 1` instead
of `CONFIG_SMP=y` when returning the address.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
mbed TLS MD operations, used by IPv6 Privacy Extensions, require access
to heap. This may vary depending on platform/mbed TLS variant used,
hence enable CONFIG_MBEDTLS_ENABLE_HEAP in tests to ensure mbed TLS has
always access to some heap memory.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Use the CMake variable for iterable section's subalignment instead of a
global defined macro.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add missing entry to the documentation to also support CMake linker
generator with CoAP services.
Update hard coded value with linker script defined value.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
When PM_DEVICE_SYSTEM_MANAGED is enabled (and that's the default) all
devices are suspended when device go to idle state (through pm
subsystem and not through just cpu_idle). In this test we are manually
controlling PM of the DUT so we don't want that.
Additionally, suspend action is taking a semaphore and it is illegal
in idle thread (where system managment operates) which causes assert
in kernel scheduler.
Removed for nrf54h20 as it applies only there.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
TBS registration was changed from static to dynamic
and the BT Tester application need to be updated to use
the dynamic registration.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Asynchronous API is recommended to be used by ETR buffer handler but
polling is also supported. Imply UART_ASYNC_API so that it is possible
to disable it in project config and fall back to polling if needed. For
example to reduce memory footprint.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
UART asynchronous API will ensure highest throughput but it is not
necessary as polling API is also supported as a fallback. Do not
enforce use of asynchronous API as there might be cases when polling
might be used (e.g. to reduce memory footprint).
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
If a connection update (from central) overlaps a peripheral initiated
conneection param request, then central rejects peripheral request
and continues central procedure. This lead to an assert in peripheral
On instant there would not be an rx_node for notification, as this
would have been discarded by the reception of the REJECT.
This fix ensures that once an rx_node has been 'accepted' for retention
it will not be discarded/overwritten by future rx_nodes
The test will trigger the assert without the fix in.
Signed-off-by: Erik Brockhoff <erbr@oticon.com>
Asserts are by default enabled for tests but flpr and ppr are
small cores (<64k) and many tests does not fit in memory with
asserts enabled.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add dedicated interrupt lines for nrf54h20_cpuppr. Similar exception
was already added to nrf54l15_flpr: 8742e2476.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
LLEXT tests currently fail on platforms where a console was chosen but
its underlying device is not enabled. This might happen for example on
multicore SoCs, where the console is only enabled on the most powerful
CPU.
Fix this by only allowing testing the device API if the console device
is both chosen and enabled in the final DT.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
This needs special treatment because the TEST_MEM_MAP section
is placed at the end. Since there is code in TEST_MEM_MAP,
rimage thinks the whole text section spans from .text to
end of TEST_MEM_MAP, which overlaps .data and others, so
it complains. Skip the execution test to avoid this issue.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The board has been renamed from intel_adsp/ace30_ptl to
intel_adsp/ace30/ptl. So the corresponding board only configs
for tests also need to renamed.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Add debug_slot_offset_by_type() for getting debug window slot offset
by type identifier. How to find the correct slot and what types there
are is documented here:
soc/intel/intel_adsp/common/include/adsp_debug_window.h
In a normal situation a client program would try to find a specific
slot right after DSP boot. Because of that the we can not expect it to
be there immediately. Instead we need to try multiple times and give
firmware some time to update the debug slot descriptor table.
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
This commit introduces architecture-specific ELF relocations for RISC-V,
in accordance with the RISC-V PSABI specification:
https://github.com/riscv-non-isa/riscv-elf-psabi-doc/blob/master/riscv-elf.adoc
Also, the necessary compiler configurations for compiling LLEXT
extensions on RISC-V are added, and the llext tests are executed on
RISC-V targets.
Calling llext extensions from user threads in RISC-V is still
unsupported as of this commit.
Signed-off-by: Eric Ackermann <eric.ackermann@cispa.de>
Use security mode (PSK or X509) to detect if we should
set the socket option to verify hostname.
PSK security mode cannot verify hostnames as this information
is coming in the certificate, so don't set the options.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
The stm32h7 nucleo 144 boards (ref MB1364)
have the LD2 on PE1 pin (not PB7). This commit change this
in the doc. Board DTS are correct.
Signed-off-by: Francois Ramu <francois.ramu@st.com>
The TBS and GTBS shall now be registered at runtime and can
no longer be registered statically. This requires a change in
the applications using this.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
This board just don't have enough RAM for all tests
so it is just a maintenance headache without any
benefits.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
* Wait for update when new object is created
Sometimes our blockwise transfer starts before server have
received an LwM2M Update. This causes Leshan to reject the SEND
because is was not aware of object /19/0
* Wait "registered" message already in conftest.py.
Sometimes Qemu boots faster, and the testcase don't see the
log.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
When generating the documentation pages for the devicetree bindings, add
a link to the .c file implementing the corresponding driver, or folder
likely to contain the driver implementation, using heuristics to
determine the most likely location of the driver sources.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Peripherals are required to support the suspend state whenever VBUS
is powered, even if bus reset has not occurred (Mandate: Required,
Effective Date: February, 2010).
Remove the stale suspend check that essentially prevented the device
from hibernating when connected to already suspended bus.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Macros with flow control are discouraged and generate compliance error,
hence remove it and replace the corresponding code with simple errno
assignments.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Net offloading doesn't need net TC threads to be enabled as they're used
by the native stack. This fixes build if CONFIG_NET_OFFLOAD is enabled
but native stack is disabled.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
In case NET_NATIVE is disabled, certain network stack components do not
need to be compiled. Otherwise, they could throw errors if
--no-gc-sections compiler options is enabled.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Native IP socket implementation need only be build if native IP stack is
enabled. Therefore, split the native IP sockets from the common socket
syscalls shared across all socket implementations.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Fix the following compilation warning given when using newlibc:
warning: 'response_truncated' may be used
uninitialized [-Wmaybe-uninitialized]
Issue is not seen with picolibc.
The variable was introduced as part of PR #76257
Signed-off-by: Tommi Rantanen <tommi.rantanen@nordicsemi.no>
To avoid killing the QEMU process w/o also ending the 802.15.4
monitoring tool, we reassign the terminal's interrupt shortcut from ^C
to ^D. This change resets the shortcut to ^C after ending the QEMU
session.
Fixes#79131
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
MAX32662EVKIT board has CFAF128128B1-0145T display which
is 128x128 graphic display.
This commit enable mpi dbi display support with LVGL graphic library.
Pin connection of display is 3wire mode
SRAM size increased to be fit with lvgl example.
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Based on Andy's talk at eoss 2024, use the sys/sem.h api instead
of the spinlock.h api to synchronize pooled elements since it
has minimal overhead like semaphores but also works from
userspace.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
SYS_SEM_LOCK() is a for-loop-like macro similar inspired by
K_SPINLOCK().
Add an entry to .clang-format so that autoformatting works as
expected.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Add SYS_SEM_LOCK() and SYS_SEM_LOCK_BREAK which are mostly the
same as K_SPINLOCK() and K_SPINLOCK_BREAK.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
We already have `DT_HAS_COMPAT_STATUS_OKAY` and
`DT_NUM_INST_STATUS_OKAY`, it seems intuitive to assume that
`DT_NODE_HAS_STATUS_OKAY` exists, so much so that it was used
before it's implemented.
This patch implements `DT_NODE_HAS_STATUS_OKAY`, which is
equivalent to: `DT_NODE_HAS_STATUS(<node_id>, okay)`
Added test for it in `tests/lib/devicetree/api`
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
"in behave of" -> "on behalf of", which is more accurate of
what is actually happening in the code.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Become the maintainer for the IPC code.
Additionally carlocaione becomes collaborator now.
Signed-off-by: Dominik Kilian <Dominik.Kilian@nordicsemi.no>
Add unsigned integer support to the log parser.
This does not change the underlying log format,
it only allows the log parser to more accurately
read the log format.
Signed-off-by: Georges Oates_Larsen <georges.larsen@nordicsemi.no>
The stack size for the event_mon_stack task may need to be larger than the
default 1024 to avoid crashes. It should be configurable through Kconfig
so that source code doesn't need to be modified to increase it.
Signed-off-by: Dave Rensberger <davidr@beechwoods.com>
The fw_is_alive() depends on 'dsp' global variable which is assigned
from map_regs() return value. To make fw_is_alive() and
wait_fw_entered(), that calls fw_is_alive(), callable from another
module, the 'dsp' variable needs to be passed as an argument.
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
map_reg() depends on args global variable for knowing it should
load a new firmware or just stand by for logging or Zephyr
shell. The map_regs() code is the very first step to access the
DSP memory, it nees to be shareable if the code is to be accessed
from another python module.
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
Do not force argsparse code to all modules importing cavstool.py. The
commit moves argparse code into a separate function, and calls it from
'if __name__ == "__main__":'. Also adds the argsparse call to to
acetool.py that shares cavstool code with the argument parsing.
Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
- Implement irq-set-affinity in RISCV PLIC.
- Added new affinity shell command to get/set the irq(s)
affinity in runtime, when `0` is sent as the `local_irq`, it
means set/get all IRQs affinity.
- Some minor optimizations
Updated the build_all test to build this new configuration.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Add rimage support for the i.MX95 EVK M7-based DDR board
variant. This is only required when running SOF.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Fixes an issue with HWMv2 boards whereby the specified board
revision was not applied at the correct place, which would cause
the target image to fail configuration
Fixes#79208
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
The code that handles passing events to and from the controller
resided in the hal_silabs module. This is an integral part of the
HCI driver that it can't work without, and logically belongs in
the driver.
Signed-off-by: Jori Rintahaka <jori.rintahaka@silabs.com>
This manifest update points open-amp to include a fix for unsafe use
of strncpy by by replacing it with internal strlcpy.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Update the HW models module to:
bf8e45bd1f870e49cc15392e045c28d54ea12285
Including the following:
* bf8e45b (52) CCM HAL: Support nrfx 3.7.0 with renamed TASK_CRYPT
* 14c14d7 HW_models/NHW_GRTC: Support MDK not exposing SYSCOUNTERVALID
* 6d66801 RADIO: Improve RSSISTART behaviour
* ceb6a80 hal grtc: Add replacements for new int group functions
* 838aa38 docs/README_HW_models: Add reference to Bsim HW models descr
* 0ff34d7 docs: Several updates and fixes
* 2972a93 AES_CCM: Avoid UBSAN pointer align warnwhen reading CNFPTR
* f8cd477 UART: Minor bugfix: Set rx status to off during ENABLE
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Fixes a bug that results in double RX buffer read from ADIN
when generic SPI protocol is used.
Actual frame size to be read must be RX_FSIZE - HEADER.
If we read less amount of bytes, then ADIN raises an IRQ or
signals via Pn_RX_RDY that there is another frame available, as
we fail to read the whole frame.
The fix for "Still some length to go 2" is still present, we drop
the CRC32 bytes from the frame prior allocation and network
stack pass.
Signed-off-by: Georgij Cernysiov <geo.cgv@gmail.com>
Add the dts and config overlay for the two boards in order
to have the openamp_rsc_table sample working on
HiFi4 DSP from i.MX8QM and i.MX8QXP.
Since these two are similar, use a snippet.
Therefore, to compile the sample we use:
west build -p -b imx8qm_mek/mimx8qm6/adsp -S nxp-openamp-imx8-adsp
-s samples/subsys/ipc/openamp_rsc_table/
Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
Add mailbox node used for inter-process communication.
For DSP, we have a direct interrupt line to the core.
Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
Add resource_table section in linker script for i.MX8QXP and
i.MX8QM, for inter-process communication.
Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
Not all offloaded network stacks support this socket option so
control it using a Kconfig CONFIG_COAP_CLIENT_TRUNCATE_MSGS,
and enable it by default.
Signed-off-by: Pete Skeggs <peter.skeggs@nordicsemi.no>
The `bonded` flag of the callback `pairing_complete` is always true,
event if the SSP pairing is non-bondable.
Check the bonding status in SSP complete event instead of in link key
notify event.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
In current, the bondable flag cannot be configured for each specific
BR connection.
But for LE conn, there is a function `bt_conn_set_bondable` for this
purpose.
Improve `bt_conn_set_bondable` to support BR conn.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
If the return value of function bt_get_bondable is false, clear the
bonding flag when controller requiring `Authentication_Requirements`.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Removes duplicate declaration of the bridging direction, keeping the
one in the public header file.
Signed-off-by: Håvard Reierstad <haavard.reierstad@nordicsemi.no>
Adds the `bt_mesh_brg_cfg` prefix to the public Subnet Bridge API, and
aligns the function and callback naming with the rest of the Bluetooth
Mesh API.
Signed-off-by: Håvard Reierstad <haavard.reierstad@nordicsemi.no>
Only the device operating at high speed has bMaxPacketSize0 set to 64
bytes, the device operating at other speeds may have a different value.
For full speed, use the value from the full speed descriptor.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
strncasecmp()'s prototype is provided in strings.h
let's include it to avoid a build warning.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Do not override the cmake_args parameter, but instead use the
cmake_extra_args one.
Otherwise we lose the default -DCONFIG_COMPILER_WARNINGS_AS_ERRORS=y
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Several samples used K_FOREVER when allocating buffers in the
system workqueue thread, which is prohibited.
The samples should rather retry later if TX fails.
This is not the ideal solution for the samples, but
fixes a bug. Ideally the samples would use a dedicated thread
to handle TX, instead of the system workqueue.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The SPI stm32 H7 driver always suspends the SPI transaction
when finishing the transceive operation. This, according to
the stm32 H7 datasheet, must only be done when the SPI master
is configured as receive-only, and the driver always
configures it as full-duplex.
Hence, remove this unnecessary operation for clarify and for
a potential reduction in the minimum time between SPI
transceive operations.
Signed-off-by: Daniel Gaston Ochoa <dgastonochoa@gmail.com>
This patch renames the identifiers for the structs in the LLEXT symbol
tables to have a prefix of "__llext_sym_". This is done so existing
scripts like gen_device_deps.py do not confuse them with the object
they are referring to.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Add an option that links in the underlying file system libraries as
usual, but doesn't compile in the Zephyr file system abstraction layer.
This can be useful to avoid linking in the entire filesystem
implementation through the `fs_file_system_t` API struct if only a
subset of the functions are used.
Signed-off-by: Jordan Yates <jordan@embeint.com>
The check for the device being configured or suspended in the fifo_fill
implementation can starve other threads, because the early return does
not change the state of the TX path, and fifo_fill is called again
from the callback loop. The ringbuffer that emulates the TX FIFO can be
filled and marked ready as long as the space is available.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Use delayable work to reduce CPU load when there is no transfer flow in
the host direction. This also improves the performance of poll out, as
introduced in commit commit fed6bde788
("usb: device: cdc_acm: send more than 1 byte in poll out")
for the legacy CDC ACM implementation.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
When the controller is connected to a full speed bus, regardless of
whether the controller supports high speed or not, the transfer size for
the bulk OUT endpoint should be equal to the MPS in the current
configuration.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
As it is still accepted practice, allow fifo_fill and poll_out to be
used simultaneously. The lock around fifo_fill was already in place.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Apply changes in commit c152e0980c
("usb: device: cdc_acm: block in uart_poll_out() routine")
to the new CDC ACM UART poll_out implementation.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
In general, it mirrors what is described in Interrupt-driven API
documentation, but here a little more explicitly and with a simplified
example, so that we can finally chisel it into the stone.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Align CDC ACM UART with Interrupt-driven UART API behavior description.
Use the same flags in uart_irq_rx_ready(), uart_irq_tx_ready(), and
uart_irq_is_pending(), which are updated after each uart_irq_update()
call. Allow TX FIFO to be filled if there is space.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
`DT_..._REG_ADDR` macros do not always return an unsigned value. This
commit adds and unsigned 32bit prefix to ensure the value is always
unsigned.
Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
As this is a header, let's explicitly initialize all members of the
struct to avoid a "missing initializer for member" warning in case the
file is built with -Wmissing-field-initializers, or worse, that warning
set to be an error.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Add `OPENTHREAD_STORE_FRAME_COUNTER_AHEAD` Kconfig option
and set it to 100000, as after calculations it appears to
be a more suitable value.
Signed-off-by: Maciej Baczmanski <maciej.baczmanski@nordicsemi.no>
Add a function bt_l2cap_br_get_remote_fixed_chan to get the remote fixed
channels.
If the fixed channel CID 0x0007 is unsupported, skip the LTK derivation.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
The flash simulator assumes that flash is being addressed with absolute
addresses by clients. But this is not the case. Given addresses are
relative to the flash base address.
The existing code only worked because the base address was always zero.
Testing with non-zero base addresses caused a mem fault/page fault.
(Reproducible e.g. when using the NVS settings subsystem on QEMU x86
with a non-zero base address in the soc-nv-flash node.)
Fixes#79082
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
When pbuf_rx_init() was added, this caller did not check for a possibly
returned error to not have more overhead than before using this
function.
Although unlikely let's check for a possible error (not configured Rx
pbuf cfg).
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Current, the callback `pairing_complete` is called
when the pairing is filed. But there is a callback
`pairing_failed` for pairing failed case.
Correct the callback calling if pairing failed.
Call `pairing_failed` instead of `pairing_complete`
if the pairing failed.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Due to the BT_CONN_BR_PAIRING is cleared when
receiving ssp pairing complete event. The LTK
key cannot be derived after the BR connection
encrypted.
Add a flag BT_CONN_BR_PAIRED that the pairing
has been done.
Use this flag to indicate whether the LTK
derivation needs to be applied if the BR ACL
connection is encrypted.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
When the ssp pairing event is notified, clear the pairing
flag.
It is used to support case that the authentication is
started by peer, the link will not be encrypted after
the pairing is completed without any err.
If the local device want to encrypt the link, it could
call `bt_conn_set_security` to start encrypt the link
after the pairing complete callback triggered.
In original implementation, the `bt_conn_set_security`
cannot be called if the authentication has been started.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Unlike a normal IRQ, a multilevel IRQ can't be incremented by
simply `irq++`, as that would always increment the L1 of a IRQ,
regardless of its level. A function that understands the level
for which the IRQ operates in is required.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Use a union struct to partition the bits in a
multilevel-encoded interrupt number instead of manipulating
the bits manually, which is tedious and error prone.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Test multilevel-irq APIs with interrupt number generated from
the devicetree to make sure that they work in sync.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The following Kconfigs are always enabled on `qemu_riscv32`:
- CONFIG_MULTI_LEVEL_INTERRUPTS
- CONFIG_2ND_LEVEL_INTERRUPTS
- CONFIG_RISCV_PRIVILEGED
No need to enable/filter for them in the testcase.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The multilevel IRQ APIs tests are currently cordoned off by
`CONFIG_MULTI_LEVEL_INTERRUPTS` compiler switch, do this more
cleanly by moving it to another file and use cmake for that
instead.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
When `CONFIG_MULTI_LEVEL_INTERRUPTS` is enabled, bits in a
`uint32_t` is always partitioned into 3 levels, we can safely
remove the `CONFIG_*_LEVEL_INTERRUPTS` checks so that the
APIs always works.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The IRQ for level 1 and above is incremented by 1 when encoded
with Zephyr's multilevel IRQ scheme, so it should be
decremented by 1.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Currently, the bonding type of Authentication
_Requirements parameter is always `Dedicated
Bonding` if the device is pairing initiator.
But if the bonding is performed during
connection setup or channel establishment as
a precursor to accessing a service, the
bonding type should be `General bonding`.
Add a flag BT_CONN_BR_GENERAL_BONDING.
Set the flag if the bonding is performed in
the L2CAP_BR/RFCOMM channel establishment.
Set bonding type depends on the flag when
receiving IO cap request.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Because MC3419's TRIGGER's Kconfig was different from the typical
configuration, the `build_all` test settings were not correctly
applied.
The Kconfig configuration has been revised to be set in conjunction
with MC3419_TRIGGER_OWN_THREAD, even if MC3419_TRIGGER is not
explicitly specified.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
The `resolving` is used to flag the status that the stack is requesting
remote device name.
It is better to use the type `bool` instead of the original type
`uint8_t`.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Move `struct discovery_priv` to classic.h
Rename `struct discovery_priv` to `struct bt_br_discovery_priv`.
Modify the structure `struct bt_br_discovery_priv` with `@private`.
Change field `_priv` of `struct bt_br_discovery_result` from
`uint8_t _priv[4]` to `struct bt_br_discovery_priv _priv`.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Due to the update of function bt_br_discovery_start,
register discovery callback by calling
bt_br_discovery_cb_register.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Due to the update of function bt_br_discovery_start,
register discovery callback by calling
bt_br_discovery_cb_register.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Remove BR discovery callback from bt_br_discovery_start.
All discovery results will be notified through callback
registered by bt_br_discovery_cb_register.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
The results of inquiry and extended inquiry
are only reported from application level
after the inquiry complete event notified.
While the event of inquiry result is notified
by controller in real time.
It is not a good user experience.
Just like scanning of LE, add a listener
cb for discovery.
When the event of inquiry result, extended
inquiry result, or remote name request
complete notified, call listener `recv`
cb to notify the upper layer.
When the event of inquiry complete
notified or no pending of remote name
request , call listener `timeout`
cb to notify the upper layer.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
Currently metal_init() is called as part of libmetal_setup() which is
called after libmetal has already started being used (metal_io_init
called before). Same for metal_finish() but in reverse (metal_io_finish
called after). To fix this inline the content of libmetal_{setup,teardown}
into their one call-sites and move the init/finish calls to the correct
spot before/after all uses of the lib.
Signed-off-by: Andrew Davis <afd@ti.com>
A libmetal "generic" device is created, then opened and used for its IO
regions. Since we are adding these IO regions in the first place there
is no reason for this layer of indirection.
Signed-off-by: Andrew Davis <afd@ti.com>
A virtual metal_device is created, next the needed IO regions are created
and added to this device. Immediately we extract these regions back out
and make use of them. There is no reason to create the metal_device and
add the IO regions to it, instead simply use the IO regions directly.
This is similar to what was already done to the openamp_rsc_table sample.
Signed-off-by: Andrew Davis <afd@ti.com>
A virtual metal_device is created, next the needed IO regions are created
and added to this device. Immediately we extract these regions back out
and make use of them. There is no reason to create the metal_device and
add the IO regions to it, instead simply use the IO regions directly.
This is similar to what was already done to the openamp_rsc_table sample.
Signed-off-by: Andrew Davis <afd@ti.com>
Currently, OpenOCD doesn't support the cc1352p7.
There are two open PR adding its support to Zephyr's OpenOCD[1]
and upstream OpenOCD[2].
Until this gets merged, we need to use a downstream version of OpenOCD.
This updates the documentation to explain where to find it and how to
use it.
[1] https://github.com/zephyrproject-rtos/openocd/pull/65
[2] https://review.openocd.org/q/owner:abailon%2540baylibre.com
Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
Change the STM32 Temperature Sensor bindings to accept the average slope
value in string form instead of integer. With this change, it is possible
to use the raw decimal value found in each MCU's datasheet instead of
needing to scale it (differently depending on series!). This also allows
regrouping the property in a single file to reduce duplication.
Also update all DTSI files affected by this change and the dietemp driver
to accept the property's new format.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Improve the STM32 dietemp sensor bindings by rewording the descriptions
of bindings and properties.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Reduce duplication in STM32 dietemp bindings by regrouping the 'ntc'
property declared in both "st,stm32-temp" and "st,stm32c0-temp-cal"
to the shared "st,stm32-temp-common" binding.
"st,stm32-temp-cal" is also modified to block 'ntc' property on include as
no dual-calibration sensors to date require it (this could be changed later
when need arises).
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Update all the conversion code in the STM32 dietemp sensor driver to be
more readable and match the Reference Manuals. Additionally, comment all
the code to make it easy to understand.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Move the reading of calibration data from manufacturing flash to a
dedicated function. This makes introduction of new STM32 series easier.
Additionally, use the sys_read16 primitive to read data instead of
manipulating and dereferencing raw manufacturing flash pointers.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Rename the fields of the STM32 dietemp sensor driver data structure to
match the names in Reference Manual more closely, and add documentation
comments to all of them.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Factor out the ADC-sample-to-temperature conversion logic from the sensor
subsystem API implementation, and move it to a dedicated function.
This makes the driver more readable.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Moves the temperature sensor channel enable and selection to separate
functions. This improves the driver's readability and makes introduction
of new STM32 series easier.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Set the 'avgslope' property of 'st,stm32c0-temp-cal' to required, and
remove its default value, to ensure new series cannot be introduced without
setting the property to the correct value explicitly.
This change does not require any DTSI modification, because there are only
two files using this compatible (stm32f030.dtsi / stm32c0.dtsi), and both
of these already set 'avgslope' explicitly.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Set the 'avgslope' property of 'st,stm32-temp' to required, and remove its
default value, to ensure new series cannot be introduced without setting
the property to the correct value explicitly.
This change does not require any DTSI modification, because there are only
two files using this compatible (stm32f1.dtsi / stm32f2.dtsi), and both of
these already set 'avgslope' explicitly.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Set the 'v25' property of 'st,stm32-temp' to required, and remove its
default value, to ensure new series cannot be introduced without setting
the property to the correct value explicitly.
This change does not require any DTSI modification, because there are only
two files using this compatible (stm32f1.dtsi / stm32f2.dtsi), and both of
these already set 'v25' explicitly.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
The typical value for V25 is different on the STM32F100 line compared
to other STM32F1 MCUs. Update the DTS property to the correct value.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Add the missing 'avgslope' property to the DTSI for STM32F030/STM32F070.
This fixes improper results being returned by the driver: the correct
value for the average slope is 4.3mV/°C (4300 µV/°C), but the binding's
default value of 2.53mV/°C was used instead, since property was missing.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Remove the "Negative Temperature Coefficient" attribute from the STM32F2
die temperature sensor node, as it does not correspond to the hardware.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Once panic mode is entered, the log write functions are called from an ISR,
so must not try to acquire locks.
Signed-off-by: Armin Brauns <armin.brauns@embedded-solutions.at>
Add more parameter checking for the unittests for the
CAP procedure 'broadcast reception stop'
Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
This is in preparation for adding another SoC where qemu_xtensa
is no longer valid choice. So use qemu_xtensa/dc233c as it is
the same as the old qemu_xtensa.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Update nrfx drivers with the minimum number of bytes that can be sent
in a single call to `uart_fifo_fill`.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Update the interrupt driver UART drivers that use `struct ring_buf`
internally to report the number of bytes that can be pushed in
`uart_fifo_fill` without fragmentation.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Update the documented value range that `uart_irq_tx_ready` returns in
order to provide more information to the callers about the number of
bytes that could be writted with `uart_fifo_fill` without fragmentation.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Fixes issue #78815
Specifies explicitly the location of the generated .config file
relative to the build directory.
Signed-off-by: Arrel Neumiller <rlneumiller@gmail.com>
Moves all Renesas sensor drivers into a vendor specific subdirectory
matching the organization used for other drivers.
Signed-off-by: Ian Morris <ian.d.morris@outlook.com>
The argument of INPUT_SBUS_INIT is named `n,` but there are some places
where it references `id.` Correcting these.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
For the parts of the simulator which are dedicated for the native
platforms (POSIX arch based):
* Refactor the parts that interacts with the host, so it is possible to
use it also with embedded libCs
* Enhance it with more options to allow:
* Keeping the content just in RAM
* Erasing the EEPROM file at exit
* Clearing the file at boot
* Also show in the command line help the default file name.
As part of this:
* Update the kconfig dependencies, so we allow building it with other
C libraries in the native targets
* Update the table in the native_sim docs to indicate all C libraries
are supproted now
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Restore the s0 we saved early in ISR entry so it shows up
properly in the CSF.
Signed-off-by: David Reiss <dreiss@meta.com>
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
This is a bug fix for adxl372_get_status function.
This function is used to get STATUS1, STATUS2, FIFO_ENTRIES2
and FIFO_ENTRIES1 registers (they are continuously present
in the memory in this order). User can choose if it wants
STATUS2 and/or FIFO registers by passing pointers where
to store received values. Bug was when user doesn't want
STATUS2 and want FIFO regs. In that case calculated length
would be 3 which will result in reading of STATUS1, STATUS2
and FIFO_ENTRIES2 regs and not expected STATUS1, FIFO_ENTRIES2
and FIFO_ENTRIES1.
Signed-off-by: Vladislav Pejic <vladislav.pejic@orioninc.com>
Upgrade to accel_polling sample application to support
RTIO streaming functionality. This mode is enabled when
CONFIG_SENSOR_ASYNC_API is defined. NUM_SENSORS must be
set to the correct number of sensors used.
Signed-off-by: Vladislav Pejic <vladislav.pejic@orioninc.com>
The RT1170 MIPI DPHY requires a faster clock frequency setting for
the MIPI DPHY, or the pixel packet counts for the HFP, HBP, and HSA will
be incorrect, and the DSI transfers will stall. Raise the target DPHY
clock frequency to resolve this.
Fixes#78299
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
This commit updates the FLASHRXBUF parsing functionality of eSPI TAF.
It ensures that data can be read correctly from FLASHRXBUF[0].
And, the eSPI TAF request can be parsed correctly.
Signed-off-by: Tom Chang <CHChang19@nuvoton.com>
This test works both with native_posix and native_sim.
native_sim will eventually not set NATIVE_SIM_NATIVE_POSIX_COMPAT
(i.e. not pretend to be native_posix) so let's correct this ifdef
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This driver works both with native_posix and native_sim.
native_sim will eventually not set NATIVE_SIM_NATIVE_POSIX_COMPAT
(i.e. not pretend to be native_posix) so let's correct the
dependencies.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Move the `Z_THREAD_LOCAL` macro from
`include/zephyr/toolchain/common.h` to `include/zephyr/types.h`.
This is needed since some `syscall.h` files are using TLS but aren't
including `zephyr/toolchain.h` (but they are including
`zephyr/types.h`).
Signed-off-by: Daniel Flodin <daniel.flodin@iar.com>
Current clocks configuration for the platform makes it impossible
to pass the IDLE_EVENT_STATS_PRECISION check. This is to be addressed
in the future.
Signed-off-by: Mateusz Hołenko <mholenko@antmicro.com>
Cortex-R8 emulated in Renode doesn't trigger exceptions on divide by zero.
We only skip the virtual SoC, so the test will still apply on a physical
target.
Signed-off-by: Marek Slowinski <mslowinski@antmicro.com>
Signed-off-by: Mateusz Hołenko <mholenko@antmicro.com>
Enable kernel dynamic object allocation.
Otherwise the following error is printed:
E: 0xa138 is not a valid sample driver
E: address is not a known kernel object
E: syscall z_vrfy_sample_driver_state_set failed check: access denied
E: couldn't start driver interrupts
Signed-off-by: Marek Slowinski <mslowinski@antmicro.com>
Signed-off-by: Mateusz Hołenko <mholenko@antmicro.com>
This commit adds a virtual target using the `cortex_r8_virtual` SoC.
It can be used for testing purposes and a starting point to add new R8
platforms.
Signed-off-by: Krzysztof Sychla <ksychla@antmicro.com>
Signed-off-by: Marek Slowinski <mslowinski@antmicro.com>
Signed-off-by: Piotr Zierhoffer <pzierhoffer@antmicro.com>
Signed-off-by: Mateusz Hołenko <mholenko@antmicro.com>
Add virtual Cortex R8 SoC. This target does not represent a real SoC,
but can be easily run in Renode.
This will allow to easily test basic architecture support.
Signed-off-by: Krzysztof Sychla <ksychla@antmicro.com>
Signed-off-by: Marek Slowinski <mslowinski@antmicro.com>
Signed-off-by: Piotr Zierhoffer <pzierhoffer@antmicro.com>
Signed-off-by: Mateusz Hołenko <mholenko@antmicro.com>
Enable Cortex R8 support, similar to Cortex-R5.
Signed-off-by: Krzysztof Sychla <ksychla@antmicro.com>
Signed-off-by: Marek Slowinski <mslowinski@antmicro.com>
Signed-off-by: Piotr Zierhoffer <pzierhoffer@antmicro.com>
Signed-off-by: Mateusz Hołenko <mholenko@antmicro.com>
The unicast_stop function is changed to primarily do a
BAP disable instead of a release, with optional
support for releasing the streams once they have been disabled.
This also adds unittests for the procedure which also
allow us to remove the invalid param testing from the BSIM tests.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add the write_unprotect command to the stm32 qspi flash driver
to un protect flash before any write operation to the external quad-NOR
Signed-off-by: Francois Ramu <francois.ramu@st.com>
Add the support of the requires_ulbpr property when a Microchip
quad-spi flash is mounted.
Set the CONFIG_USE_MICROCHIP_QSPI_FLASH_WITH_STM32=y flag to access
the command
Signed-off-by: Francois Ramu <francois.ramu@st.com>
Add the <requires-ulbpr> property from the "jedec,spi-nor-common.yaml"
to the existing st,stm32-qspi-nor.yaml. So that external quad-NOR with
unlock the Global Block Protection (BPR) (opcode 0x98) is accepted.
Signed-off-by: Francois Ramu <francois.ramu@st.com>
Generating sections via DT memory attributes did not work for the
platform as only the memory region was created so far.
This change adds the DT_LINKER_SECTION() macro to the linker script so
that the appropriate sections will be generated, too.
Fixes#79085
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
Updated overlay files to test using nocache.
and run outside of usersapce mode to avoid
inaccessible memory regions when using nocache on RT parts.
Also updated testcase file to reflect nocache testing.
Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
- A lot of zephyr networking samples (zperf, http_server, etc) will
complain if both 2.4g and subg ieee802154 are enabled simultaneously.
- This leads to a lot of new people getting confused with the network code
not working without any clear errors.
- As we already set the alias `zephyr,ieee802154 = &ieee802154g`, I think
it would be best to enable only subg by default.
Signed-off-by: Ayush Singh <ayush@beagleboard.org>
Checks blobs presence as dependency to allow driver build.
Goal is to avoid building in environment where blobs won't
be present (e.g GitHub CI environment).
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Both #78823 and #78807 merged at around the same time. This made it so
the shell didn't compile when #78823 was stacked on top as it did not run
with the test build. This fixes the compile issues.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
The User LED for the mimxrt1060_evkb is inverted from the
mimxrt1060_evk, this commit updates the ACTIVE_STATE to be
HIGH rather than LOW.
Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
Fixes:
/__w/zephyr/zephyr/include/zephyr/drivers/stepper.h:429:16: error:
'direction' may be used uninitialized [-Werror=maybe-uninitialized]
found with:
west build -p -b esp32s3_touch_lcd_1_28/esp32s3/appcpu -T
tests/drivers/stepper/shell/drivers.stepper.shell
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
The previous code used casts of address of int to float pointer.
This is undefined behavior in C and may cause a compiler to
optimize code incorrectly.
I have replaced it with a union of int and float types,
eliminating the cast problem.
Signed-off-by: Lars-Ove Karlsson <lars-ove.karlsson@iar.com>
Increasing the number of max tx segments to be able to fit composition
page 0 into composition data status message.
After the subnet bridge config client and server are added to the
tester, the size needed to report composition data page 0 increased.
Current behaviour of the tester is correct, dropping the element when
there is not enough space in data field, however the PTS application
does not handle the composition data status message without element.
Signed-off-by: alperen sener <alperen.sener@nordicsemi.no>
Fixes: #79052
The yaml CMake tests overwrites `message()` in order to verify correct
error handling. This was original done in a function and then using
a return call when an expected error has been raised.
Using a function() means the `return()` only returns the `message()`
and thus wrongly continue processing rest of the yaml file.
Change `message()` to macro so the return call correctly returns from
the calling yaml functions.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Make sure that CONFIG_ZVFS_OPEN_MAX in the tests and samples is at
least the same value as CONFIG_NET_SOCKETS_POLL_MAX so that we
cannot have more polled sockets than there are available file
descriptors.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
The dispatcher table needs to be large enough to have support
for all file descriptor values.
Fixes#79042
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
This region is only required if certain fast peripherals make use of such
region for DMAing. It was now enabled on all builds, often resulting in:
```
[134/134] Linking C executable zephyr/zephyr.elf
Memory region Used Size Region Size %age Used
FLASH: 24372 B 248 KB 9.60%
RAM: 4448 B 256 KB 1.70%
DMA_RAM21: 0 GB 16 KB 0.00% <~~ Not used!
DMA_RAM3x_APP: 40 B 4 KB 0.98%
IDT_LIST: 0 GB 32 KB 0.00%
```
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Move FIELD_* macros from zephyr/sys/util.h to zephyr/sys/util_macro.h,
as zephyr/sys/util.h cannot be used from device tree.
Device tree uses zephyr/dt-bindings/dt-util.h, which includes
zephyr/sys/util_macro.h.
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
Update glob patterns to include files using "silabs" naming
in addition to "gecko".
Also include the oddly named BT HCI driver.
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
- Driver always initializes the device in the suspended state
- If CONFIG_PM_DEVICE_RUNTIME=n, device PM callback will be called with
RESUME action, thus setting up pins to default state and enabling the
peripheral
NOTE: when CONFIG_PM_DEVICE=n, the pinctrl sleep state will not be
available (-ENOENT) and so never applied, thus avoiding a pin
suspended->active transition.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Some devices, e.g. SoC level devices like I2C peripheral, can never be
powerd off as they are always energized. Such devices can only go from an
active state or to a low power state (suspended). Allow them to simply
return -ENOTSUP when called with TURN_ON (or TURN_OFF).
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Adds custom overlay and config allowing the fs_sample to run on
the stm32f746g_disco with DMA enabled.
Signed-off-by: Maciej Sobkowski <msobkowski@antmicro.com>
This enables the usage of DMA for stm32f7x in the sdmmc driver.
Co-authored-by: Maciej Sobkowski <msobkowski@antmicro.com>
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
For DMA channels overridden by HAL DMA, there was no way of
resetting stream busy variable.
Co-authored-by: Maciej Sobkowski <msobkowski@antmicro.com>
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Due to deinitialization not happening, reinitialization
of the disk did not happen as the streams were marked busy.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Reading superblock didn't work with DMAs that only support aligned reads
(e.g. STM32 DMA).
Co-authored-by: Maciej Sobkowski <msobkowski@antmicro.com>
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
This will calibrate the HSI's PLLX clocks if enabled
The value rcc_hsicalibartion_default is 0x40U for h7/h7rs.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Hotfix for two compilation warning issues for
wpa_drv_zep_event_dfs_cac_finished() and
wpa_drv_zep_event_dfs_cac_started(),
and for hmac_prf256() in hostap project.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
This allows downstream modules to overwrite the default log level choice
using Kconfig.defconfig files.
For example, this becomes possible:
```
choice LWM2M_LOG_LEVEL_CHOICE
default LWM2M_LOG_LEVEL_WRN
endchoice
```
In contrast to the configuration method, this then has an effect on all
applications stored in the downstream module.
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
The kscan input callback does not use an instance specific name, so we
can only ever have one instance of this type.
Signed-off-by: Gero Schwäricke <gero.schwaericke@posteo.de>
Using INPUT_CALLBACK_DEFINE_NAMED would not add the _input_callback__
prefix to the given callback name. This can result in namespace clashes.
Signed-off-by: Gero Schwäricke <gero.schwaericke@posteo.de>
The LVGL input callback does not use an instance specific name, so we
can only ever have one instance of this type. This issue was evident by
a build error, e.g., when using "zephyr,lvgl-keypad-input" nodes twice:
error: redefinition of '_input_callback__lvgl_keypad_process_event'
Signed-off-by: Gero Schwäricke <gero.schwaericke@posteo.de>
There's no reason to send these async, and since the reply isn't waited for
anywhere, this can cause the HCI buffer pool to be exhausted and
`bt_enable()` to fail.
Signed-off-by: Armin Brauns <armin.brauns@embedded-solutions.at>
frdm_mcxc242 board does not have adc configured and enabled. Configure
and enable it. Update documentation.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Since UDC buffers are allocated with `UDC_BUF_GRANULARITY` granularity,
the `net_buf_tailroom` may no longer be equal to the HID report size.
Use `setup->wLength` instead to ensure that proper HID report size is
passed to the application's callback.
Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
This pulls in PRF-256 wrapper API based on PSA APIs. This implements
PRF-256 as per section 11.6.1.7.2 in 802.11ac using PSA APIs.
Signed-off-by: Vivekananda Uppunda <vivekananda.uppunda@nordicsemi.no>
This commit updates revision of hal_nordic to bring the latest changes
in the nRF IEEE 802.15.4 driver.
Signed-off-by: Andrzej Kuroś <andrzej.kuros@nordicsemi.no>
- Exclude `app.overlay` from DTC_OVERLAY_FILES in
`drivers.gpio.build.adc_ads1145s0x_gpio` tests to avoid duplicate builds.
- Modified so that adc_ads1145s0x_gpio.overlay can be tested alone.
- Delete the conffile and move its contents to extra_configs.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Since the log module entity is not defined anywhere,
LOG_MODULE_REGISTER should be used here instead of LOG_MODULE_DECLARE.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
A null check for the TCP connection `conn` was added at the start of
the function, but the previous checks were not removed, leading to
a redundant null check, which is unnecessary.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add support for BeaglePlay, a TI AM6254 SoC based development board with a
CC1352P7 wireless microcontroller for supporting software defined 2.4GHz
and SubGHz wireless protocols. Support for running Zephyr on the
quad-A53 SoC or the programmable M4 on the SoC would be provided
separately.
See https://beagleplay.org for details.
Signed-off-by: Jason Kridner <jkridner@beagleboard.org>
Signed-off-by: Ayush Singh <ayush@beagleboard.org>
The fix 25173f71cd created
`struct pm_device_base` and moved `usage` to it.
This has been overlooked so that I fixed it.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
This commit makes the rom_start relocation introduced in
commit 8ef8e8b497 available for Cortex-A/R CPUs.
Signed-off-by: Simon Maurer <mail@maurer.systems>
Add timers that have been enabled to board doc table
Add timers that have been enabled to board twister yaml
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Add nodes for LPTMR. This is sufficient to enable their use as counter
devices when set to status okay.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Add DT node and clocking of TPM peripherals, which are used for PWM.
Also change the soc clock enable code to not use preprocessor
conditionals.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Add peripheral bridge definitions to DT, this also fixes the base
address of the GPIO peripherals which were faulting in the driver due to
the wrong reg address.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Base enablement of MCXW merged while z_arm_platform_init was being
deprecated, resulting situation is now that no platform init is
happening, fix by converting to use soc_reset_hook.
Also fix a comment that said the core was being set to 40 MHz, when it
is actually being set up to 96 MHz.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Some LLEXT objects can include sections, that should not be merged
with other sections of the same type. E.g. when such sections should
be placed into locations, other than the default. Add support for
such sections.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
To simplify LLEXT loader parameter extension pass the whole
struct llext_load_param to final consumers instead of extracting
individual fields from it in the caller function.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
When building LLEXT for Xtensa with custom sections the compiler
can leave unresolved references in them. Then this has to be done by
the LLEXT core during linking. This commit adds linking support for
the L32R Xtensa instruction.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
It's more common in the LLEXT code base to call elf_sym_t instances
"sym" and not "sym_tbl." Convert llext_link_plt() to follow this
convention.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Make llext_loaded_sect_ptr() a proper function to be able to call it
from platform LLEXT code.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
The http_client_req() function's timeout parameter is allowed
to be SYS_FOREVER_MS. However, K_MSEC() does not convert this
to a proper k_timeout_t, so sys_timepoint_calc() ends up
returning 0, which is causes immediate timeouts.
Check for this case specifically and force value passed to
sys_timepoint_calc() to be correct.
Signed-off-by: Pete Skeggs <peter.skeggs@nordicsemi.no>
This aims to make the code more linear by having the for loop
validates the input format rather than search for a match.
Signed-off-by: Josuah Demangeon <me@josuah.net>
After the error code is checked to be zero, it is possible to return 0
explicitly to help with readability. Also, when available, forward the
return code from the failing function instead of a locally chosen error
code like -EIO.
Signed-off-by: Josuah Demangeon <me@josuah.net>
While applying the format, the pixel format and drv_data->fmt were set
immediately, and the resolution was set only if it had a matching
entry on the "caps".
This commit makes sure the requested format matches the caps before
applying the format as well as drv_data->fmt. This does not guards
against partial failure (i.e. only pixelformat set and not
resolution).
Signed-off-by: Josuah Demangeon <me@josuah.net>
The following devices enable TRIGGER in a way that is different from the
template definition, so add these settings to sensos_no_default.conf.
- bosch,bmc150
- bosch,bmm150
- bosch,bmp150
- ti,ina230
- we,wsen-itds
- lm77
- st,lsm9ds0-gyro
- ti,tmag5170
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
This commit adds C++20 onwards support for the
PINCTRL_DT_STATE_INIT macro. Since C++20, support was
added for designated initializers but with the restriction that
they're ordered. PINCTRL_DT_STATE_INIT initializes a
pinctrl_state struct but the current initializer list is un-ordered,
this PR resolves that for >= C++20 compat
Signed-off-by: Chandler Keep <chandlersamkeep@gmail.com>
Since fc007eeef5 TLS sockets support
timeout based on CONFIG_NET_SOCKETS_CONNECT_TIMEOUT value. The TLS test
suite reduced this config value to speed up the tests, however it turns
out the 100ms timeout is too low to finalize the handshake on slower
platforms (nrf52840 specifically). Therefore increase the timeout value
to 200ms to prevent test failures on those.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
All the board.cmake contains more or less the same data. This patch
applies the cosmetics changes to align the structure of all these files.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
It is a good practice to add a comment after #endif when the condition
is not obvious. However, when the condition is well known, "Don't Repeat
Yourself" rule applies and no comment should be added.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Most of the Kconfig files in soc/silabs start with a comment describing
the chip. This comment is redundant with the help message in associated
to the chip. Let's don't repeat ourselves.
This patch also ensure the Kconfig help message the full name the chip.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Most of the Kconfig files in boards/silabs start with a comment
describing the board. This comment is redundant with the content of
board.yaml. Let's don't repeat ourselves.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Usually commercial names mention the chipset included on the board.
"Thunderboard Sense 2" is the only exception in the Silabs boards.
This information is probably useful, so add it to the description of
this board.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Yaml files allows the user to find the internal name for their board
using the "name" field.
In addition of the commercial names/references, Silabs boards have
internal board references. These references are not advertised, but can
be found printed on (every) boards.
It makes sense to add this reference to the Yaml file in case a user
would have the idea to grep it.
This patch also fixes some commercial names of very old boards.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
The entry listed in the docs does not exist. The correct entry
(dt_compat_enabled) is present.
Fixes#79081
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
The security check case statements were in frequency band
setting checks. This is totally wrong and will cause compiler
warnings. Moving the checks to correct function.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Add flpr and ppr core to the sample.
Since there are only 2 UARTs available on DK, local UART configuration
is using only cpuapp and cpurad.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add interrupt locking during test to ensure that main thread is not
interrupts which would impact the test.
Add longer sleep time between tests to ensure that all logs are
processed on time and not dropped.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Currently we can assume that flpr and ppr cores are always owned by
cpuapp. In that case, cpuapp (which processes ETR buffer content) has
access to the memory where logging strings from ppr and flpr are
located. Those strings do not need to be appended to the message
which is written to the STM (in case of standalone configuration).
This approach reduced logging time, e.g. logging a message with
one argument takes 1.8us on cpuapp and 6.3us on cpurad.
This setting applies only to the case when cpuapp is the owner
of those co-oprocessors and shall be updated if that becomes
configurable but currently there are no means to detect core
owner.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
The architecture description was quite out of date in some parts,
specially those which changed with the introduction of the native
simulator.
Let's update it.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Fix trailing `\\r\\n` (escaped CR/LF) didn't cut off because of rstrip()
removed by #58338, so the CR/LF suffix was never found as the actual line
end was `\\r\\n\n`.
Add ANSI code sequence to `test_handlers` Twister unit test.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
This fixes the following warnings:
> unit address and first address in 'reg' (0xa080000) don't match for
> /mram@a080400
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Some applications may require the SPI NOR driver to be initialized
earlier. This commit enables the user to change the default
initialization priority.
Signed-off-by: Vidar Berg <vidar.berg@nordicsemi.no>
-add nucleo_u083rc and stm32u083c_dk overlays files
for testbench purpose.
- add platform_exclude property to skip test on boards
with little ram size.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
tests: drivers: adc: adc_api: update adc_api test
-enable adc in nucleo_u031r8, stm32u083c_dk and nucleo_u083rc
- add adc as new supported interface in docs
- update yaml files
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Because timing of the pause/resume for peripheral/sync is based on
central/broadcaster active clock, the sleep-clock jitter shall not be
added.
Signed-off-by: Morten Priess <mtpr@oticon.com>
- Add next pointer to node_rx_iso_meta for pre-transmission linked
list (does not increase memory usage as union is larger).
- Fix broadcaster not setting PTC with test configuration
- Refactor stopping of sync ISO tickers to separate function
Signed-off-by: Morten Priess <mtpr@oticon.com>
Share pause/resume functionality by moving resume ticker handling to
ull_iso. Rename interface function to ull_conn_iso_resume_ticker_start,
and provide handles instead of instance pointer.
Signed-off-by: Morten Priess <mtpr@oticon.com>
Currently NXP MPU depends on "cpu" command in uboot to kick Zephyr to
Cortex-A Core, added U-Boot version which support "cpu" command in the
board documents.
Refined boot commands.
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
Adds a new command that will return information on slots
themselves, listing the slot sizes, without any internal
information about the slot data. Will also return the maximum size
of an image for a set of slots if built using sysbuild.
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
In order to be able to ifdef based on `CONFIG_RUST`, the config must be
defined in the main repo (because the rust module is optional). Add
this as a placeholder. If the module is not availabe, the symbol will
be present, and always disabled. The module will provide a full
definition for the Kconfig.
Signed-off-by: David Brown <david.brown@linaro.org>
This is a little complicated. We currently just jump directly to rust's
panic, so we aren't likely to actually need these unwind tables. But, they
would be needed if we ever reall paniced. As of the time of this change,
the tables seem to just be 24 bytes of ROM space.
Signed-off-by: David Brown <david.brown@linaro.org>
Although the Cmake rules to build Rust applications keeps the target
directory inside of the build directory, some IDE tools may generate a
target directory while editing the code. Ignore these so they never get
checked in.
Signed-off-by: David Brown <david.brown@linaro.org>
Although the Cmake rules for Rust leave all build files in the build
directory, sometimes tools such as IDEs can leave a few files in the
source tree. Ignore these to make sure they don't get committed.
Signed-off-by: David Brown <david.brown@linaro.org>
Add zephyr-lang-rust as an optional module. This module brings in
support for writing applications in Zephyr using the Rust programming
language.
At this point, the integration supports:
- Building applications with Rust support.
- CI testing of samples and tests from the rust module (twister
functionality already present).
Still to do is adding documentation to the Zephyr docs with an overview
of Rust support as well as the generation of the rustdoc docs.
Signed-off-by: David Brown <david.brown@linaro.org>
Add several examples for `upload_test_results_es.py` script usage
with ElasticSearch index map files for the following use cases:
* Twister test results.
* Twister test results with recordings.
* Memory Footprint data (`twister-footprint.json`).
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
The `default y`, which is coupled with
depends on DT_HAS_TI_ADS1112_ENABLED to link the settings with DeviceTree,
which was missing, so I added it.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Remove unused nRF21 FEM SPI CSN control as the Zephyr
Controller does not implementation SPI control for Tx/Rx
nor for Tx gain settings.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Add CI coverage for nRF5340 plus nRF21540 FEM usage in
hci_uart plus hci_ipc samples.
The overlay values are inspired from:
https://github.com/nrfconnect/sdk-nrf/tree/
85307a9ca0fb6ba8c61f4bd05b7f866cde42612f/boards/shields/nrf21540ek
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Allows selecting the forward GPIO pins to network core Kconfig
option and enables it by default if the node exists in devicetree
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Added support for dynamic registration and unregistration of the
Broadcast Audio Scan Service (BASS) within the scan delegator.
This enables both scan delegator and BASS to be registered or
unregistered dynamically at runtime.
Signed-off-by: Babak Arisian <bbaa@demant.com>
Fixes an issue with structure which was previously raised in a
comment, and adds a new bool to the structure to enable this
restructure to work
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
If an involuntary disconnection happened it could set default_conn to NULL
while it was still being used in the main while loop.
Signed-off-by: Hakan Jansson <hakan.jansson@infineon.com>
Fix the calculation of the response slot that is assigned to the
temporarily connected responding device.
Signed-off-by: Hakan Jansson <hakan.jansson@infineon.com>
One of the first thing one wants to do when reading about a code sample
is checking the code itself. This commit adds a button to directly take
the user to the code sample' source code on GitHub.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
This file uses something that is defined in the toolchain files,
fix a build error by including that header
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Test did not support PPR core due to failing GRTC channel allocation.
This change fixes the channel allocation and enables PPR core test.
Signed-off-by: Bartosz Miller <bartosz.miller@nordicsemi.no>
The README HTML has some extra link underscore between spaces due to the
extra newline and space between the <a> and <img> tags. Remove it.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
As confirmable requests will stay allocated for (3 * ACK_TIMEOUT), we
need to adjust the timings so all requests are unallocated by the end
of the test.
Signed-off-by: Francois Gervais <francoisgervais@gmail.com>
This commit makes sure we continue to wait for extra confirmations even
after the request is done so we can handle duplicate confirmations if any.
Detailed description:
rfc7252#section-4.5 specifies that:
"The recipient SHOULD acknowledge each duplicate copy of a
Confirmable message".
So if, for example, the client sends to a multicast destination address,
the server will get multiple requests and will confirm all of them.
Without this commit, the client will set the request to done after
receiving the first answer.
From here the request object will be marked as free and the duplicate
acknowledgements will stay buffered in the network stack.
Once the client tries to send a new request, it will unbuffer those
duplicate acknowledgements but now the request object is unallocated
so the client won't be able to handle those acknowledgements as duplicates.
It will instead treat it as an unexpected ACK.
To work around this issue, rfc7252#section-4.8.2 states that:
"EXCHANGE_LIFETIME is the time from starting to send a Confirmable
message to the time when an acknowledgement is no longer expected,
i.e., message-layer information about the message exchange can be
purged."
Keeping the request object allocated for EXCHANGE_LIFETIME ensures that
duplicate acknowledgements can be handled accordingly.
This commit adds a basic implementation of what is stated in the RFC.
EXCHANGE_LIFETIME has been arbitrarily set to 3 * ACK_TIMEOUT which
seems more reasonable than the 247 seconds stated in the RFC.
Signed-off-by: Francois Gervais <francoisgervais@gmail.com>
Adds NXP platforms to the smp_svr sample allow list,
for overlay-serial.conf and overlay-shell.conf.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
The Multi-Channel Inter-Processor Mailbox (MBOX) framework can be seen
as a more general version of the Inter-Processor Mailbox (IPM) framework.
An MBOX driver provides for multiple channels, where IPM provides for
only a single channel of communication.
Currently many applications are written to use IPM, while some are now
being written to use MBOX. This means if a platform wants to support both
types of apps a given it must have a driver for both frameworks. As MBOX
is the newer and more generic framework, new drivers are being added for
this framework only and older IPM drivers are being migrated to MBOX.
This leads to the situation where applications need to be written twice,
once for each framework, to run across all platforms.
The solution is to add a gasket driver that exposes the IPM interface
while using a MBOX driver in the back-end. This shim driver allows
platforms to only need an MBOX driver to support both types of
application. This IPM driver can be used when an application only
supports IPM but the platform only supports MBOX.
This will allow platforms and applications to be ported over to MBOX
independently of each other. Add this driver here.
Signed-off-by: Andrew Davis <afd@ti.com>
This commit makes the device tree configuration decide
which link layer is compiled in. We do this to avoid
hard-to-understand linker errors referencing device tree nodes.
The following configuration creates a difficult to parse
linker error:
* BT_LL_CHOICE contains multiple entries, BT_LL_SW_SPLIT
is selected.
* Each BT_LL_CHOICE has its own unique device tree node with its
own "compatible".
* Only one of the link layer device tree nodes has status "okay",
but not the one corresponding to BT_LL_SW_SPLIT.
The linker error indicates that code using the HCI driver fails
to link with the controller. This because the HCI driver device
tree node references the link layer selected in devicetree which
is not compiled in.
By adding a dependendency to the device tree node, this can no longer
happen. Instead, if BT_LL_SW_SPLIT is now selected in a configuration
file, a Kconfig warning will be issued:
```
warning: The choice symbol BT_LL_SW_SPLIT
(defined at subsys/bluetooth/controller/Kconfig:129) was
selected (set =y), but BT_LL_SOFTDEVICE (defined at
/home/ruge/ncs/nrf/subsys/bluetooth/controller/Kconfig:11)
ended up as the choice selection.
```
This should be easier to understand than:
```
...(hci_core.c.obj):(.data.bt_dev+0x16c):
undefined reference to `__device_dts_ord_132'
```
After this commit we should consider getting rid of link layer
selection from Kconfig completely as the link layer is in practice
selected through device tree.
Unit tests have been updated to satisfy the dts dependency.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
Resetting the connect semaphore from tcp_conn_unref() prevents the
ref/unref mechanism from being used freely when needed. Therefore, move
the code responsible for resetting pending connection to
tcp_conn_close() (called only when the connection is being closed on
behalf of the TCP stack, for instance due to RST being received) and to
net_tcp_put() (connection closed on behalf of the application).
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
It is possible that TCP connect() will fail if for example network
interface does not have IP address set. In this case we close
the connection during net_tcp_connect() but do not set the return
code properly. This looks in the application like the connection
succeeded even if it was not.
As the tcp_in() call in net_tcp_connect() might close the connection,
we just take extra ref count while calling tcp_in(). Otherwise we
might access already freed connection.
Before the fix:
net_tcp_connect: context: 0x80757c0, local: 0.0.0.0, remote: 192.0.2.2
net_tcp_connect: conn: 0x8087320 src: 0.0.0.0, dst: 192.0.2.2
tcp_in: [LISTEN Seq=1604170158 Ack=0]
tcp_conn_close_debug: conn: 0x8087320 closed by TCP stack (tcp_in():3626)
tcp_conn_close_debug: LISTEN->CLOSED
tcp_conn_unref: conn: 0x8087320, ref_count=1
net_tcp_connect: conn: 0x8087320, ret=0
After the fix:
net_tcp_connect: context: 0x80757c0, local: 0.0.0.0, remote: 192.0.2.2
net_tcp_connect: conn: 0x8087320 src: 0.0.0.0, dst: 192.0.2.2
tcp_conn_ref: conn: 0x8087320, ref_count: 2
tcp_in: [LISTEN Seq=1604170158 Ack=0]
tcp_conn_close_debug: conn: 0x8087320 closed by TCP stack (tcp_in():3626)
tcp_conn_close_debug: LISTEN->CLOSED
tcp_conn_unref: conn: 0x8087320, ref_count=2
net_tcp: tcp_conn_unref: conn: 0x8087320, ref_count=1
net_tcp: net_tcp_connect: conn: 0x8087320, ret=-128
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Add sample application to capture an image frame from a camera
and send it for display on LCD via the LVGL library.
Signed-off-by: Charles Dias <charlesdias.cd@outlook.com>
By default, TFM enables hardware rollback protection, which requires a
security counter to be embedded in the image trailer. The default
behaviour of constructing this counter from the image version breaks the
TFM `boot_nv_security_counter_update` implementation once the version
number is greater than `0.0.1024`. As such, explicitly specify the
desired security counter value. As per the MCUboot docs, this does not
need to be incremented on every firmware update.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Add support in this IPC backends for POSIX arch targets in general,
and ensure the nrf5340bsim defines the buffer which will be used.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Provide a new function for initializing the Rx side,
so users do not need to initialize the pointers by hand
if they did not use PBUF_DEFINE().
Let's also rename pbuf_init() to pbuf_tx_init() to clearly
signify the previous function was only meant to be used
by the Tx side.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Add a function which can be used to remap embedded device address,
into addresses which can be used in the simulated native boards.
For the nrf_bsim boards we provide an actual implementation.
For other boards, we provide an optional dummy version which does
nothing.
It is up to each board implementation to decide if they want to
provide one or use the dummy.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Update the HW models module to:
85944c64f224406e4d781aa382c5f1f71ed307fd
Including the following:
* 5340: Allocate a buffer for the APP core RAM (2nd version)
* 82ca90c Add NCS test-spec.yml to trigger downstream CI job
* a05d7a6 docs: top README: Mention nrf54l15 support and minor fixes
* cd64524 54 ECB/CCM tests: Remove comment which does not apply
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
ssize_t is not part of the C library ISO standard subset, and as such
one cannot expect a C library to expose the type by default.
Some libraries like glibc do not expose this type in general, and
trying to build using them results in build errors.
There is 3 possible options:
1. Continue using ssize_t and:
1.a define _POSIX_C_SOURCE before including any header
1.b include sys/types.h directly (A bit uglier)
3. Not use ssize_t, and instead rely on ISO standard types
Let's just go with 1.a assuming we want to keep using this type,
as that is the correct way of getting this type defined.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
struct i3c_ccc_address is intended to match the output where the address
is left shifted by 1 for SETDASA and SETNEWDA. Require the operations
calling it to shift the data.
add an additional parameter for the setdasa function which will allow for
the da to be configured rather than being hard coded.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Extend the safety overview with information about the IEC 61508 standard
and why it was chosen for zephyr.
Add a new diagram which shows relations between the IEC 61508
and other standards.
Signed-off-by: Simon Hein <Shein@baumer.com>
Use the quirk to keep only the necessary clocks running when the core is
hibernated. The quirk is necessary to bring the USB suspend current
below the USB 2.0 suspend current limit.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Make it possible to have vendor quirks after hibernation entry sequence
and before hibernation exit sequence.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Initialize PHY as part of controller init sequence.
Disable 2M and coded PHYs for now, as they cause issues on devices
that don't support them. This should be made configurable in the future.
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
Update HAL for Series 2 devices to Simplicity SDK 2024.6.
This HAL deprecates sl_device_init_emu(). Equivalent functions
are now performed by sl_power_manager_init().
For now, soc.c remains compatible with both the Gecko SDK based
HAL for Series 0 and 1, and the Simplicity SDK based HAL for
Series 2. In a future commit, soc.c will be split between the
two platforms.
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
Fix the chip select when using the synchronous API with DMA path.
Note need to use TxDataRequest flag instead of ModuleBusy flag now
because module busy flag will not deassert until PCS deasserts.
This does not fix CS for the non-DMA path, because that would require a
large driver rework.
Do not skip configuration when calling transceive with the same spi_cfg
because we need to write a new command word.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Fixes 78713
Add instructions to the "Git Setup" section to ensure that the user's
GitHub profile name is their full name (first and last) and that the
GitHub profile name and email address match the git config user.name
and user.email.
Page: contribute/guidelines
Tested with:
ninja html
python3 -m http.server 8000
Signed-off-by: Arrel Neumiller <rlneumiller@gmail.com>
The IPv6 branch of net_tcp_endpoint_copy() was accidentally made
conditional on CONFIG_NET_IPV4 rather than CONFIG_NET_IPV6.
Signed-off-by: Ben Wolsieffer <benwolsieffer@gmail.com>
Update the GPIO driver to use PDL API instead of HAL API to fix the
issue with configuring interrupts on both edges
Signed-off-by: Sreeram Tatapudi <sreeram.praveen@infineon.com>
- Added `cs-supported` property to nrf-radio devicetree
- Added `HAS_HW_NRF_RADIO_CS` Kconfig option which is set if
`cs-supported` property is enabled
- Enabled `cs-supported` property for nrf54-series devices
- Disabled `cs-supported` on nrf54l15bsim because it is not
yet supported
Signed-off-by: Ivan Iushkov <ivan.iushkov@nordicsemi.no>
The CSIP spec states that the procedures shall only be done
on bonded devices, so a check for that was added.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add note that those Kconfig options were removed from Nordic UART driver
configuration.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Remove Kconfig option that no longer has any use after pinctrl
driver is introduced.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
This is a leftover from pre-pinctrl era and no longer makes sense.
Driver always manages gpio through pinctrl.
Support removed from uart and uarte shims.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Align all existing samples/tests/applications which
contains nrf54l15pdk/nrf54l15/* by adding
nrf54l15dk/nrf54l15/* to enable twister builds.
Signed-off-by: Katarzyna Giądła <katarzyna.giadla@nordicsemi.no>
Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
The suspended flag is checked during SOF and RESUME interrupts, and it
is modified within a delayable work item. To prevent race conditions,
this update ensures that interrupts are disabled (locking IRQs) before
modifying the suspended flag. Additionally, the RESUME interrupt is
enabled only when the USB is suspended.
Signed-off-by: Ren Chen <Ren.Chen@ite.com.tw>
Evaluate CONFIG_LINKER_ITERABLE_SUBALIGN in CMake instead of in the
linker script.
It cannot be assumed that a linker generator implementation is
pre-processed and therefore Kconfig settings cannot be used in those
but must be evaluated in CMake.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Constrained application can require to avoid waiting for response
from a server. CoAP No-response option defined in RFC 7967 allows
to do that by suppressing selected response types.
Signed-off-by: Hubert Miś <hubert.mis@gmail.com>
If DNS statistics is enabled in Kconfig, then start to collect it.
This is useful in order to see how many DNS requests/responses
received or sent, and also see the amount of dropped DNS packets.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Add missing documentation for macro parameters, as `@param ...` is
only expected to be used with a variable argument list.
Signed-off-by: Jordan Yates <jordan@embeint.com>
The `@kconfig{}` pattern does not work properly as the first value in
the `@retval` field, leading to:
```
WARNING: zephyr/include/zephyr/llext/llext.h:296: unexpected token in
comment block while parsing the argument of command retval
```
Signed-off-by: Jordan Yates <jordan@embeint.com>
Pull the output build folder from the environment, instead of hardcoding
the HTML output folder, which is wrong for the latex build.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Current folder name is set to "espressif_esp32" and
might not reflect all kinds of SoCs as such as esp8684.
Rename the folder to "espressif" only.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Separate the pickled EDT generation from the C-Macro header
generation in gen_defines.py to have a more clear responsibility
of the scripts in the DTS parsing process.
Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
Introduces type hints to all functions for improved static type checking
and IDE support.
Also equalizes spacing between functions as the lines are being touched
anyway.
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
According to USB 2.0 Specification the remote wakeup device must hold
the resume signaling for at least 1 ms but for no more than 15 ms. The
DWC2 otg controller requires the software to drive the remote wakeup
signalling for appropriate duration (when LPM is disabled, which is
currently always the case in udc_dwc2). Arbitrarily choose to drive the
resume signalling for 2 ms to have sufficient margin in both directions.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
The PMU is not reset by core reset and therefore it is necessary to exit
hibernation on DWC2 disable to prevent endless PMU interrupt loop when
the driver is enabled again.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Enter hibernation in thread context with the lock held to make sure to
not queue any transfers when the core is hibernated.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
UDC API handlers and DWC2 driver thread share not only software
constructs, but also the underlying hardware. Ensure that any UDC API
call is not preempted by DWC2 driver thread (and vice versa) by
acquiring the lock in thread handler.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
When the queue is full, all messages posted inside interrupt handlers
are simply dropped. This problem can be remedied by having the message
queue large enough, but determining the maximum number of messages that
can ever be posted in the system is really complex task.
Hopefully in DWC2 driver there is finite number of events that have to
be processed inside thread handler. Therefore it is unnecessary to
determine the maximum queue size for the events if the events are posted
to k_event object instead of send to k_msgq object.
Use combination of three k_event structures to handle all possible event
sources. This not only guarantees by design that no event will be lost,
but also slightly reduces the memory usage.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add the necessary entries but keep the usbhs disabled by default on
radio core (it is enabled by default on app core).
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
This commit adds support to dictionary logging to parse binary
data directly from input serial and generate the ascii logs.
Signed-off-by: Kumar Siddaramayya <harish.kumar@nordicsemi.no>
For nrf54h20 a range of combinations exist to configure the test and
debug domains data sources and sinks. Expose them in DTS to allow
configuring them. Also drop the previous style which was too rigid to
extend to cover all cases cleanly. The old style was only used in a
single sample application so far.
Signed-off-by: Karsten Koenig <karsten.koenig@nordicsemi.no>
This fixes the following warning:
> unit address and first address in 'reg' (0x80280000) don't match for
> /soc/sckcr@81280004
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x82000) don't match for
> /soc/flash-controller@38000000/flash@16000000/partitions/partition@80000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x82000) don't match for
> /soc/flash-controller@38000000/flash@16000000/partitions/partition@80000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Add a new test to the simple llext test suite that verifies that DT
devices are properly exported to extensions. This is done by obtaining a
device handle from the DT and then trying to get the same handle at
runtime using the device_get_binding() API.
This test is optional because the current qemu_xtensa platform does not
have any usable DT devices to test with.
The LLEXT heap size is also increased to 64 kbytes to avoid heap
exhaustion when running the new test on mps2_an385.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
This change adds a new configuration option, LLEXT_EXPORT_DEVICES, which
enables exporting all devices defined in the device tree to llext
extensions. When enabled, all devices are made available to extensions
via the standard DT_ / DEVICE_* macros.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
This patch adds an indirection level moving the current code from inside
the EXPORT_SYMBOL and LL_EXTENSION_SYMBOL macros to private Z_* macros.
This is done to allow for the official APIs to properly expand more
complex arguments, such as the DT function-like macros.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
The comment for Z_DEVICE_DT_DEV_ID() is misleading: device_get_binding()
compares its inputs with values generated by the DEVICE_DT_NAME() macro,
which expands to the node's DT label or to the node's full name.
This patch updates the comment to reflect the actual behavior of
Z_DEVICE_DT_DEV_ID().
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
The error message for Z_DEVICE_NAME_CHECK was needlessly calling
DEVICE_NAME_GET() on the "name" string, resulting in a confusing message
being displayed.
Remove the DEVICE_NAME_GET call so that the error message shown by the
compiler contains the actual name.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
These test features are not required and are not used in any USB samples
or tests.
Follow-up on commit 0809b75b42 ("boards: remove test feature usb_cdc")
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
This change adds bt_le_cs prefix to public CS API as well as
adding le_cs prefix to CS related bt_conn callbacks. This is
to ensure consistency within CS API while maintaining the
separation between the Bluetooth LE and Classic features.
Signed-off-by: Burak Gorduk <burak.gorduk@nordicsemi.no>
Adds following HCI support for CS configuration:
- LE CS Create Config command
- LE CS Remove Config command
- LE CS Config Complete event
Two callbacks have been added to notify the application
when a new CS configuration is created or an existing
CS configuration is removed.
Signed-off-by: Burak Gorduk <burak.gorduk@nordicsemi.no>
Added a timeout for active scans (instead of using the host's scan
timeout) in the shell by submitting a k_work that stops the scan
after a specified period.
Fixes#78659
Signed-off-by: Babak Arisian <bbaa@demant.com>
Since the same test might be run in parallel on different platforms,
the one that it's started later will fail due to port re-use for
the OpenSSL server.
Since it's not really required to run the tests on native_sim and
native_sim/native/64, the latter is removed in order to solve this
problem.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
He will be taking over my duties.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
This is my final week at Nordic. My future job will not involve me
maintaining the Bluetooth host.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Added kruithofa as a collaborator as they are familiar
with ISO and we should have at least 2 collaborators
to perform reviews.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
- Add jlink as possible runner for cyw920829m2evk_02 platform in
board.cmake file
Signed-off-by: McAtee Maxwell (CSS ICW SW MTO INT 2) <maxwell.mcatee@infineon.com>
Change the interrupt number of flash in device tree due to duplication
And disable CONFIG_FLASH as default
Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
Channel sounding frequently produces very large events, so the default
of 68 bytes can lead to buffer overruns / memory corruption.
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
The code path for error handling and timestamping in tx path
was meant to be identical in function to old eth_mcux driver,
but there is actually a discrepancy causing no error handling
for timestamped frames, fix it.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Remove unnecessary Kconfig.sysbuild for mimxrt1170_evk
as MCUBOOT_MODE_SWAP_WITHOUT_SCRATCH is set by default without it.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
So let's make sure we test in native_sim instead of native_posix..
Also, building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Note: Some drivers tests for which there is native specific driver
which will or may be built differently in native_sim and native_posix
have been left enabled for native_posix
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these tests in both native_sim and native_posix does not
improve coverage for the tests or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for these.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Also let's remove a few redundant test platform filters
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated. Let's switch the filter and build
checks to native_sim instead.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix does not
improve coverage for the sample or subsystem but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is already filtered in the common
part. No need to remove it also per test.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building these samples in both native_sim and native_posix
does not improve coverage for these samples but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is now deprecated.
Building this sample in both native_sim and native_posix
does not improve coverage for the sample but doubles CI time.
As anyhow native_posix will be removed all together in
2 releases, let's remove it already for this sample.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Make sure to stop timer counter before interrupt is cleared,
otherwise it might re-trigger it due to default interrupt level mode.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
There is a lot of repeated code for parsing arguments. Add a function
to do the same in every place.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Add i3c_bus_for_each_i3cdev and i3c_bus_for_each_i2cdev to more easily
iterate through each i3c or i2c device on the bus.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Some comments were not updated following the change in how uncached
memory regions are defined in devicetree.
Signed-off-by: Abderrahmane Jarmouni <git@jarmouni.me>
In the handler of SMP_Pairing rsp, the encryption key
flag is cleared incorrectly.
It causes the LE LTK cannot be derived.
Do not modify the encryption key flag to fix the
issue.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
The `LOG_ERR` will spam the log if the window is low e.g. 1 ms.
Also the PWM capture callback will be called with an error, which allows
handling and logging the error if desired.
Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
The size_t type may vary from machines. Current snprintk code was
causing below build issue on arm64.
error: format '%x' expects argument of type 'unsigned int', but argument
4 has type 'size_t' {aka 'long unsigned int'} [-Werror=format=].
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
This adds a timestamp format mode, that includes the date, which is
usefull, when using realtime for the logging timestamp.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
this way CONFIG_LOG_OUTPUT_FORMAT_CUSTOM_TIMESTAMP
only uses the custom timestamps for
logs that are not send via syslog.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
DBGMCU clock handling was not optimal.
If it exists, enable it before dealing with debug configuration in one
block, then deactivate it after in another block.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
Similarly to debug in stop mode, enable debug in sleep mode on H7 series,
as initially described by `STM32_ENABLE_DEBUG_SLEEP_STOP` option.
Not extending it further to other series as I won't be able to test.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
# Conflicts:
# soc/st/stm32/common/soc_config.c
HAL_Enable/DisableDBGStopMode() was one of the last usage of HAL
definitions from Legacy HAL APIs.
Use LL instead to harmonize code across series and remove this dependency.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
DTS files for the application core IMX MPUs should
fall under the NXP MPU area, not MCU.
Also, remove myself from NXP MPU area.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
The STM32 DMA driver can provide interrupts for transfers not yet complete.
However, the current implementation will clear the busy flag for all
interrupts when CONFIG_DMAMUX_STM32 is not enabled. The previous fix for
when CONFIG_DMAMUX_STM32 is enabled should also apply when not enabled.
Also if CONFIG_DMAMUX_STM32 is enabled busy flag will not be cleared when
error interrupts occur.
With this change, the busy flag is only cleared when completion interrupts
in non-cyclic mode or error interrupts occur. These are the cases where
transfer will not continue.
Signed-off-by: Carson Green <cgreen@tuta.com>
Add code to get the current frame rate and enumerate all supported frame
rates (frame intervals) of the current format.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
unlike dma v2 binding where bit 15 is reserved, dma v1 binding
needs to configure the the DMA peripheral increment offset.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
The TBS and GTBS instances can now be dynamically registered
and unregistered, which fits better for the use cases of TBS
where specific bearers can come and go depending on the
features of the device.
For example if a SIM card is inserted, then a device can
register a TBS for the provider and remove it again if the
SIM card is removed.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Update the includes for Bluetooth Audio samples so they
properly include what they use.
The includes are then used to determine which relevant APIs
to refer to in the READMEs.
Finally improve the naming and description of the samples
using the Profile names and role.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The clocking code present inside the NXP I3C is SoC specific.
This has been moved to the SoC folder which makes this driver
more flexible to clock architecture variations between SoC's
and SDK driver clock API variations.
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
Update RT5xx and RT6xx clock init to add the code
to set the I3C dividers. This code has been moved
from the I3C driver.
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
Moves around the shell files so that they are placed nearer
to the features they expose access to.
A few changes as possible has been made.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
In order to reduce confusion regarding interface count
the respective warning was adjusted to better reflect
the actual state of the system.
Signed-off-by: Carlo Kirchmeier <carlo.kirchmeier@zuehlke.com>
Add Data Memory Barrier during the extended calibration of STM32U5, as it
is done in STM32Cube HAL, to avoid sporadic errors during calibration that
may result in measures that are offset from real values.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Make sure we check the checksum offloading capabilities correctly
for VLAN interfaces. Use the real Ethernet interface when doing the
check.
Fixes#78724
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Red zone was causing issues in places where inline assembly was pushing
data to stack, like arch_irq_lock, and possibly in other places.
Initially -mno-red-zone was enabled on x86_64, but was later, maybe
accidentially, disabled in https://github.com/zephyrproject-rtos/zephyr/
commit/b7eb04b3007767be9febe677924918d2422a4406
Signed-off-by: Jakub Michalski <jmichalski@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Renamed soc from ace30_ptl to ace30.
We were previously using the wrong soc name.
The correct name is ace30.
There is only one ptl platform, but there can be several ace30 platforms.
Signed-off-by: Grzegorz Bernat <grzegorzx.bernat@intel.com>
No functional changes were made in this update.
Only code formatting issues were corrected.
This commit is necessary to preserve Git history
continuity for future changes involving the switch from ace30_ptl to ace30.
Signed-off-by: Grzegorz Bernat <grzegorzx.bernat@intel.com>
This reverts parts of commit c344771d8b
related to intel_adsp soc.
There is a dependency on device initialization that was missed.
Reverting until we have a proper way for migrating to hooks.
Fixes#78880
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This commit enables the user to choose whether to
allocate the video buffer from the video heap pool
or use a memory region with specific extra capabilities,
such as being cacheable/non-cacheable or using external
memory.
Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
Add pwm yml file.
TIMER0/1/2/3 support pwm, LPTIMER0/1 not.
LPTIMER0/1 provide 16bits out that not meet pwm requirement.
Co-authored-by: Mert Vatansever <mert.vatansever@analog.com>
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Common pwm driver for MAX32xxx MCUs
Co-authored-by: Mert Ekren <mert.ekren@analog.com>
Co-authored-by: Mert Vatansever <mert.vatansever@analog.com>
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Used the SMP_BT_SVC_UUID_VAL define exposed in the smp_bt header
in the smp_svr sample instead of hardcoding its value.
Signed-off-by: Mateusz Kapala <mateusz.kapala@nordicsemi.no>
Added the SMP service and characteristic UUIDs to the smp_bt module
header and used those definitions.
Signed-off-by: Mateusz Kapala <mateusz.kapala@nordicsemi.no>
C++ file compilation is actually missing the warning-as-error handling,
causing warnings in build files to be unnoticed in CI. Add a flag to
handle them as well.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Add an explicit unsigned literal suffix (U) for addresses obtained from
devicetree, this is to work around a specific warning:
zephyrproject/zephyr/include/zephyr/arch/arm/cortex_a_r/timer.h:40:2:
warning: this decimal constant is unsigned only in ISO C90
When compling
west build -p -b qemu_cortex_a9 -T tests/lib/cpp/cxx/cpp.main.cpp98
Argueably all devicetree addresses and sizes should be unsigned but this
is enough to make CI pass, may look into changing the device.h macro as
a followup.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Drop the array dasignators as they generate a
warning: array designators are a C99 extension
warning when compiling with clang. Not too sure if this is an actual
problem or if the warning should be disabled instead but since it's just
a test it should be fine to just drop them.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
On some architecture (qemu_x86) this tests generate an unused reference
warning for the PM device structure, as nothing in the structure macro
definition is referencing itself.
Reference the struct in the device define, keep the compiler happy.
Also change one of the device priority to dodge a
'__device_dts_ord_8' causes a section type conflict with
'__device_dts_ord_9'
error with llvm.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Fix the compiler error:
comparison of integer expressions of different signedness: ‘const int’
and ‘unsigned int’
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Add a dummy byte to struct mspi_timing_cfg, for C++ compatibility, same
as what's done in include/zephyr/arch/structs.h,
include/zephyr/arch/arm/structs.h, include/zephyr/kernel/thread.h and
others.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Fix a type mismatch compiler warning in the c++ tests.
Signed-off-by: Yuval Peress <peress@google.com>
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Common uf2 partition configurations to avoid duplication in boards.
There appears to be a bit of confusion about exactly what a proper
UF2 partition map looks like for the nrf52840, so common dts
configurations should help to avoid confusion.
Configuration for SoftDevice v6 and v7 provided as thats what was
fouond in use in tree already.
Signed-off-by: Jacob Winther <jacob@9.nz>
An issue with some macros is that a space is added to conditional
expansions. Prevent some of these macros to get formatted.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Separating declarations of variables not referenced with #ifdef
when CONFIG_IIS328DQ_THRESHOLD is disabled.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
The bt_gatt_attr_read function did not properly handle cases
where value is NULL and/or value_len is 0, or bad mixes of the
two.
The important part is here is that we do not perform the pointer
arithmetic on NULL and/or call memcpy with a NULL src with a
non-0 length.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
This updates the hal_xtensa commit to latest, including:
* Adds intel_adsp_ace30_ptl SoC
* Adds sample_controller32 for MPU
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The CONFIG_PINCTRL setting is removed from the board
_defconfig files. And "select PINCTRL" is added to
the appropriate driver files.
Signed-off-by: Bill Waters <bill.waters@infineon.com>
Reverts bus clock settings. Follows MCUXpresso SDK clock settings, and
sets to output of SysPLL2 PFD3 at 198 MHz.
Signed-off-by: Derek Snell <derek.snell@nxp.com>
Spi bus controller node names should follow recommended naming
convention from DT spec otherwise DTC will report a warning.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Adds a --download-buffer-size option to the canopen runner to allow
specifying the buffer size of the SDO download.
Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
The buffered and internal options were not assigned in the channel_cfg,
so they would end up at a random state.
The cfg struct is now properly zero-initialized and both options can
be set using optional parameters -b and -i.
Fixes#75884
Signed-off-by: Martin Jäger <martin@libre.solar>
External projects building the documentation may not clone all modules, as
they have manifest filtering. Therefore, not having access to a module
should not produce a fatal documentation build error. Convert the error to
a debug log, so it is at least traced.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The driver enables the clock of a gpio-port if any of the
pins use the port. This is done by calling pm_device_runtime_get
when a pin is used and pm_device_runtime_put when the pin is not
used anymore.
These calls needs to be balanced. But if a single pin was configured
as GPIO_DISCONNECTED multiple times, every time pm_device_runtime_put
was called.
This caused the clock of the port to be stopped and therefore also
other pins on the same port stopped working.
This commit fixes this by keeping track of which pin on a port
has requested the clock and only call pm_device_runtime_get or
pm_device_runtime_put when the clock-request for the specific pin
changes.
Fixes#77698
Signed-off-by: Jeroen Broersen <jbroersen@interact.nl>
This case fails to build on boards having APIC TSC timer enabled.
This change is needed after moving APIC TSC timer support from
apic_timer.c to apic_tsc.c.
Signed-off-by: Dong Wang <dong.d.wang@intel.com>
User can set CONFIG_NET_SHELL_SHOW_DISABLED_COMMANDS=n to prevent
unused net-shell commands from showing. This can save flash as
the disabled commands will not be shown in net-shell listing.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
It is useful to know the currect status of DHCPv6 client when
printing the interface information.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Allow "net virtual" command to attach or detach virtual
interfaces. This is useful for device management.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Add missing NULL check for public API function, so that the
function will return -EINVAL rather than crashing.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
- Add CONFIG_SHELL_PROMPT_UART to the prj.conf file.
- Ensure the ztest_params test is flashed/run only once per Pytest session.
Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
Make sure it's possible to register IPv4/6 addresses on an offloaded
interface. Add an extra build configuration to make sure it's also
possible when native IP stack is disabled.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
It shouldn't be needed to enable native networking to be able to
add/delete IP addresses on network interfaces.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
IPv4 Kconfig options which only affect native IPv4 stack should be
dependent on NET_NATIVE_IPV4, similarly as it's done for IPv6.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Fixes wrongly returning an SMP version 2 error code as an SMP
version 1 error code instead of adding it as an error
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Allows enabling the bootloader info functionality without MCUboot
being enabled, so that other bootloaders can add hooks with their
own responses
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
The I2C transfer API has been recently changed to always automatically
set a STOP on the last message, which was well documented but
implemented only by few drivers.
Unfortunately, while documented, this is a change in the current
behavior and it turns out that some applications depended on it for some
complex operations.
Add a flag to temporarily restore the old behavior, buying time to fix
the application code depending on this.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Update documentation to describe the method of returning response data
to the HTTP server using the response_ctx callback parameter.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
Add test cases for dynamic GET/POST, where the payload is transferred
across more than one call to the dynamic resource callback.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
After introduction of struct http_response_ctx, the dynamic resource
data buffer is no longer needed for transferring data between the
application callback and the server. It is therefore removed to avoid
unnecessary copying of data.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
Add tests covering new method of providing a response for dynamic
resources.
Tests cover the application sending response codes and headers,
overriding "default" headers, and sending various combinations of
headers and body data. Each case is tested for HTTP1 & HTTP2, both POST
and GET methods.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
Allow the application to send headers and response codes from a dynamic
resource callback by filling out a response context structure.
This also allows simple requests to be completed in a single execution
of the callback, by setting the final_chunk flag.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
Running IPv6 on STM32H743 using eth_stm32_hal I had to extend
the timeout between the attempts to send Router Solicitation packets
from 1 second to 2 seconds. Else it looked liked the packet never
got sent (checked using tcpdump).
Signed-off-by: Stefan Petersen <spe@ciellt.se>
This commit uses the new .. zephyr:code-sample-category directive to
categorize code samples across the tree.
Updates existing legacy references to manually defined targets to now
use :zephyr:code-sample-category: role instead.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
This commit adds support for categorizing code samples in the
documentation.
It introduces two new directives:
- `zephyr:code-sample-category::` to create a category and associated
brief description, that implicitly acts as a toctree too.
- `zephyr:code-sample-listing::` to allow dumping a list of samples
corresponding to a category anywhere in the documentation.
Fixes#62453.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
move domain.py to domain/ to make it easier to keep things organized
and e.g. add dedicated css/js resources, etc.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adopt zephyr:code-sample directive to describe the Dining
Philosophers sample and update reference accordingly.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add property which indicates that UARTE support frame timeout
feature. Property is added to nrf54h20, nrf9280, nrf54l20 and
nrf54l15.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Added helper functions to set and get assisted listening
stream values for codec capabilities and codec configs.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add bool value that stores the CC change information received in
the interrupt of TCPC alert line. In sink role when in disconnected
state, polling the CC lines causes the chip to be awaken from sleep
mode increasing the power usage. When partner is connected, or any
other CC lines change happens, the chip informs about it with alert.
It can be cached and used instead of asking the chip directly.
Signed-off-by: Michał Barnaś <barnas@google.com>
Add support for VBUS measuring part of the TCPCI compliant device.
This device should be used as a child-node for the more specific
TCPC driver and referenced by the vbus property in the usb-c
connector node.
Signed-off-by: Michał Barnaś <barnas@google.com>
Add generic functions that will be common to all TCPCI compliant
drivers like registers reading, writing and updating.
Signed-off-by: Michał Barnaś <barnas@google.com>
Add header file with registers and fields definitions compliant
to the Type-C Port Controller Interface Specification
Revision 2.0, Version 1.3.
Signed-off-by: Michał Barnaś <barnas@google.com>
The QoS preference defined by ASCS has some specified
limits and values that we should enforce.
Given the current API we cannot return an error to the
unicast server if it supplies invalid values, so we have
to resort to a LOG_ERR.
For the unicast client we treat invalid QoS preferences
similar to other invalid data in the notifications.
This also adds additional documentation in the
bt_audio_codec_qos_pref struct.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add broadcast support for the CAP acceptor sample.
This adds new sample-specific Kconfig options to help
select the right Kconfig options based on whether
unicast, broadcast or both is being used.
The babblesim implemented for the broadcast has been expanded
to verify that the CAP acceptor receives the broadcast audio.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
This fixes a bug where the shell will reject setting available
context to 0x0. This has now been moved to only affect supported
context instead.
Signed-off-by: Fredrik Danebjer <frdn@demant.com>
In the case that a broadcast sync fails for any reason, we need to
set the BIS_Sync value for all subgroups to 0xFFFFFFFF
(BT_BAP_BIS_SYNC_FAILED) as per the BAP spec.
This commit adds a new define for this and modifies
both the scan delegator and broadcast sink to support this.
The change is validated by a modification to the broadcast
assistant test that verifies that the value is set in the
case of an invalid broadcast code (which indicates a
failed BIG sync).
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Minimize code duplication chances when multiple boards will be added
eventually as supporting this shield.
Define an alias for board i2c node used by on-shield touch controller.
Move H747I-specific LVGL/display optimization options to a dedicated
defconfig file.
Signed-off-by: Abderrahmane Jarmouni <git@jarmouni.me>
Only ADC_REF_INTERNAL reference option is allowed in
adc_mcux_adc16 driver, but the reference is not used
for driver configuration. Internal, external or VDD
can be used in reality depending on SoC type and
its configuration.
Remove the reference option check to allow any reference
option from Devicetree.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Cadence I3C target FIFO width has been increased to 4 bytes in i3c
hardware REV_ID 1.7. Writing 1 byte to 4 byte FIFOs can cause
unintentional padding for bytes written from TX threshold interrupt
handler. Fixed the target callback to handle tx width of i3c target
writes to FIFO, by using run time rev_id check.
Signed-off-by: Naveen Gangadharan <naveeng1001@meta.com>
Up until now, the `__thread` keyword has been used for declaring
variables as Thread local storage. However, `__thread` is a GNU
specific keyword which thus limits compatibility with other
toolchains (for instance IAR).
This PR intoduces a new macro `Z_THREAD_LOCAL` which expands to the
corresponding C11, C23 or C++11 standard keyword based on the standard
that is specified during compilation, else it uses the old `__thread`
keyword.
Signed-off-by: Daniel Flodin <daniel.flodin@iar.com>
Fixed uninitialized return value variable issue, which would cause
functions to wrongly return non-zero value despite a successful
execution.
Signed-off-by: Chew Zeh Yang <zeon.chew@ambiq.com>
Update the string formatter according to the type of the
variables that it is printing to eliminate compilation
warnings.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Was getting compilation error due to `CONFIG_SHELL_CMD_ROOT`
not being defined whe building the sample under certain
configurations.
The `CONFIG_SHELL_CMD_ROOT` is defined and used only when
`CONFIG_SHELL_START_OBSCURED` is enabled, we can simply move
it to another file and rely on CMakeLists.txt to compile.
Run the `login_init` with `SYS_INIT` so that the `main()`
do not need to have knowledge of its existence.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The minimum Python version was bumped for Zephyr LTSv3, but only in the
documentation and CI. The build system would still accept Python 3.8,
yet some scripts in tree have already broken support with that version.
Incompatibility errors should be prevented early.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Package in the requirements-run-test.txt file, bz,
is not package enabling bz2 support.
It is a security concern and must be removed.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
The TLC5971_STRIP config enables if the "ti,tlc5971" node exists.
Also, removing the setting that explicitly enables in the
`tests/drivers/build_all/led_strip` test.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
These static functions in the `pma.c` are used only when
`CONFIG_NOCACHE_MEMORY` is enabled, so guard them accordingly.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Add shell commands to enable/disable, move, set velocity, configure
micro-step resolution, and display stepper motor status. Includes an
`info` command to output all relevant data with graceful handling of
unsupported features.
Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
Remove the system heap override config from the board sample config.
Remove the memory saving restrictions.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
Provide symbols for the creation of dynamic memory pool.
Update the ROM-code SRAM usage according the IDF main.
Fix static allocations size check.
Increase iram_seg memory size for MCUboot.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
Provide symbols for the creation of dynamic memory pool.
Fix the loader ROM buffers start address.
Fix static allocation size check.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
Add the `CONFIG_ESP_RUNTIME_HEAP` kconfig.
This allows the memory pool to be created starting
at `z_mapped_end` ending at `_heap_sentry`.
Added choice symbol ESP_WIFI_HEAP_* to select which
heap to use in the ESP WiFi adapter module.
Add file heap.c with code to initialize the runtime heap.
Size of the pool is checked during the runtime.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
This lets the SoC to select the correct kconfigs to show that
it supports coredump, and with the ability to dump privilege
stack.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Modify the test to spawn a user thread if it is running
with userspace enabled. This allows testing coredump when
the crashing thread is a user thread.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds the bits to call into architecture code to dump
the privileged stack for user threads.
The weak implementation is simply there as a stub until
all architectures have implemented the associated function.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds a interface to allow coredump to dump privileged
stack which is defined in architecture specific way.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Changed the scan option type from uint32_t to
uint8_t.
There are 2 reasons for this:
1) This reduces the size of the struct bt_le_scan_param.
Since we are now storing two copies of scan parameters
statically in the host, this is not insignficant.
2) This fixes a "hole" in the struct. There are no longer
3 empty octets between the `type` and the `options`, which
caused valgrind warnings when using `memcpy` and `memcmp`
of the struct.
Currently we only need 8 bits for the options available.
If additional options are added later, the field need
to be increased. For the above reasons some additional
refactoring my be required to avoid significant size
increases and the valgrind issue.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add cargo's bin to the path, and print out the versioning of the tool to
make it easy to ensure the right version has been installed.
Signed-off-by: David Brown <david.brown@linaro.org>
The Buffer data was being stored in cacheable memory for
the MIMXRT1010_EVK, the caching is not handle in these
test and cause mimxrt1010 to fail, this commit moves the
memory region to DTCM and in some cases lowers the size
of the DATA Buffer since it won't fit in DTCM for MIMXRT1010_EVK
Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
Add VGA and QVGA resolution support to enable
usage of gc2145 sensor by smaller ram capable devices.
Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
Demultiplexer was not ready to handle case when log message was
incomplete which was followed by other log messages. Such scenario
could occur if there was a fault that happen during logging of
a message. In that case incomplete message was followed by valid
messages (fault report) and this fault report was not handled
because processing was blocked waiting for completion of a
message which preceeded fault report.
Since it is expected that some messages may be incomplete a
garbage collection mechanism is added. When start of a message is
received timestamp is logged and list of incomplete messages
is checked for 'old' messages which persist in incomplete state
for long. When message timeouts it is closed and marked as
invalid. It unblocks processing of following messages.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
write_data function which was writing to STMESP data registers was
starting by writing words and tail was written using byte access.
However, RISCV core does not support unaligned access and on Cortex-M33
even if supported it is faster to do aligned access. Reworked
write_data to start first by writing data using byte or half word
access until data pointer is word aligned, then word access is used
and finally tail is written using byte or half word access.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
This fixes the following warning:
> unit address and first address in 'reg' (0x88000) don't match for
> /soc/flash-controller@4001e000/flash@0/partitions/partition@87000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x6a) don't match for
> /soc/sercom@42001800/atecc608a@15
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x1000) don't match for
> /soc/spi@40003800/spi_nor@0/partitions/partition@10000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Introduce GPIO-based driver for MIPI DBI class that allows MIPI DBI
type A and B displays to be used on general platforms.
Since each data pin GPIO can be selected individually, the bus pins are
set in a loop, which has a significant negative impact on performance.
When using 8-bit mode and all the data GPIO pins are on the same port,
a look-up table is generated to set the whole port at once as a
performance optimization. This creates a ROM overhead of about 1 kiB.
Tested 8-bit 8080 mode with ILI9486 display on nRF52840-DK board.
Signed-off-by: Stefan Gloor <code@stefan-gloor.ch>
The MIPI DBI API supports MIPI DBI controllers type A, B, and C
(except with 16 write clocks). Update the documentation accordingly.
Signed-off-by: Stefan Gloor <code@stefan-gloor.ch>
Instead of always using the SPI MIPI DBI mode (type C), look up the
mipi-mode from the device tree and only set the mode to
MIPI_DBI_MODE_SPI_4WIRE as a fallback in case the property is not given.
Signed-off-by: Stefan Gloor <code@stefan-gloor.ch>
Currently the RAM allocated for the bootloader is not
enough to use MCUBoot with crypto signatures.
This commit bumps the #defines accordingly to fix
compile errors with ecdsa_p256 and RSA.
Signed-off-by: Brandon Allen <brandon.allen@exacttechnology.com>
The Linux binding DO's and DONT's about designing DT bindings
pretty much all apply to Zephyr as well, and a lot of these issues
come up in reviews in Zephyr, which is the reason that Linux has
this page in the first place, to list common binding review topics.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Fixed mcuboot slots, needed after MCUBoot added the default
auto calculation max sectors (CONFIG_BOOT_MAX_IMG_SECTORS_AUTO).
Fixed a possible firmware update error.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
This commit removes the y-selection of the `CONFIG_PINCTRL` Kconfig option
in FE310-based boards defconfig files.
It also makes drivers used in FE310 y-select `CONFIG_PINCTRL` if pinmuxing
is needed.
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Infom users about Kconfig options deprecation, and provide code snippets
on what they have to do now.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Devicetree should be used instead. Example DT snippets are provided to
ease with the transition.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
- Only one board tweaked the HFXO configuration (bl5340_dvk)
- LFXO configuration has been added to all boards based on the current
Kconfig defaults: use LFXO with internal 7pF capacitor.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
HFXO is represented as a child of the oscillators node. A new node is
created because it requires its own properties (see the binding for more
details).
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
LFXO is represented as a child of the oscillators node. A new node is
created because it requires its own properties (see the binding for more
details).
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
- Create a new compatible: nordic,nrf53x-oscillators, as other series,
e.g. nRF54LX contain a similar but different IP (with PLL control,
etc.)
- Adjust DT: use recommended node name, remove redundant status okay.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
For add_interface(), only add STA interface when hostapd enabled,
and the Soft-AP interface will be added in zephyr_hostapd_init().
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
bt_aics_client_free_instance_get can be called from multiple threads
and as such the atomic_test_and_set_bit should be used instead
of a atomic_test_bit followed by a atomic_set_bit.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Currently, debug logging in the console and verbosity
are tightly coupled - verbosity of level 2 and higher
enables logging at the debug level.
This change introduces a separate Twister flag
responsible for controlling the debug logging,
while leaving the rest of verbosity unchanged.
This allows for controlling the verbosity on
both logging levels, according to one's needs.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
For code clarity, remove unnecessary `return` statements
in functions with a void return type they don't affect control flow.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
For code clarity, remove unnecessary `return` statements
in functions with a void return type they don't affect control flow.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
For code clarity, remove unnecessary `return` statements
in functions with a void return type they don't affect control flow.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
For code clarity, this commit adjusts the use of `return` statements
in functions with a void return type as follows:
- Transform `return foo();` into separate statements:
`foo();`
`return;`
- Remove unnecessary `return` statements when
they don't affect control flow.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
For code clarity, unified switch-case usage in `dhcpv6_enter_state` to
use `break` instead of `return`.
Typically, a `break` is used in switch-case statements unless an early
return is necessary, in which case `return` is appropriate.
In this scenario, the `break` statement is the more suitable choice.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Replace the busy boolean flag with an atomic value.
This also modifies the order of how this value is
controlled to avoid any race conditions.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Simplifies the k_thread_cpu_pin() implementation to leverage the
existing cpu_mask_mod() infrastructure.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
Currently, dfu_suspended() sets the phase SUSPENDED
directly in the structure, bypassing the dfd_phase_set() function.
This prevents the phase change callback in the bt_mesh_dfd_srv_cb
structure from receiving the SUSPENDED event.
Signed-off-by: Emilio Aguila Escalante <emilio.aguila@hotmail.com>
On some EDMA versions, some TCD registers (e.g: SADDR, DADDR,
SLAST, DLAST, etc...) are extended to 64 bits via adding a new
HIGH register holding the value of bits [63:32]. Since, for now,
the driver doesn't support 64-bit addresses, this scenario is
supported by sign-extending the 32-bit value written to SLAST/DLAST.
SADDR and DADDR are taken care of on HAL side.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Some EDMA versions may have the channel MUX register in the MP
region. To support this scenario, use the `EDMA_HAS_MP_MUX_FLAG`
flag to figure out which channel MUX register to use (TCD or MP).
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Update CONFIG_ESP_SIMPLE_BOOT to exclude if CONFIG_MCUBOOT=y
Fix usage of the config according to actual definition.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
Ensure that the output certificates directory is created, where
generated certificates will be placed. This fixes a build error seen
when using `make` to build samples/net/wifi for the rd_rw612_bga board,
where the output directory for generated certificates did not exist at
build time.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
1. kenistis dspi does support rx and tx with different size,
so skip the tx_bigger test.
2. dspi dma need internal alignment and 8192 bytes are too
many for k64, so reduce to 1440 bytes
fixing: #77010
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
`CONFIG_MP_NUM_CPUS` has been deprecated for more than 2
releases, it's time to remove it.
Updated all usage of `CONFIG_MP_NUM_CPUS` to
`CONFIG_MP_MAX_NUM_CPUS`
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The L2 function `ieee802154_decipher_data_frame()` relied on upper layer
LL address fields which breaks encapsulation.
Also fixes a bug introduced in another fix that went overboard (#53734).
Fixes: #78490
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
Found a few variable declarations that were not yet moved to the top of
the function/block. Doing this before actually fixing #78490 so that the
fix becomes more readable.
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
The current `K_THREAD_STACK_DEFINE` only create a single stack
shared by all the busy threads. This is causing the application
to crash when there are more than 2 cores in the system.
We should use `K_THREAD_STACK_ARRAY_DEFINE` to create an array
of stacks instead.
Updated the testcase to test up to 8 cores using
qemu_riscv64_smp
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
MICP requires support for the bondable mode for both
the MICP microphone device and MICP microphone controller.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
BAP mandates support for bondable mode for all central and
peripheral roles.
Due to Kconfig circular dependencies, some additional
Kconfig changes had to be made.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Removed the experimental status from the BT_GATT_AUTHORIZATION_CUSTOM
Kconfig option used in the Bluetooth Host GATT layer. This feature
has been present in Zephyr for almost a year without any issue reports
or API modifications.
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
Currently a user, or a shield definition, must select a Kconfig to
signal that the iovdd_ctrl and bucken GPIOs are connected to the same
pin. We can instead check this in the driver by simply checking if
the iovdd_ctrl_spec and bucken_spec are the same pin.
Update the nrfwifi driver and remove the redundant
NRF_WIFI_COMBINED_BUCKEN_IOVDD_GPIO config.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Adds HCI support for:
- LE CS Read Remote Supported Capabilities
- LE CS Read Remote FAE Table
Callbacks have been added to the conn object to allow upper layers to
make use of the cache commands, with which it will be possible to store
this information and provide it again in the case of a disconnect
and reconnect to the same device.
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
Add Devicetree overlay for samples basic/blinky_pwm and drivers/led/pwm
for frdm_mcxc242 board to set appropriate tpm clock source and
to enable pwmleds.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
frdm_mcxc242 has tpm ip for pwm generation, but it is not enabled.
Configure and enable it. Add pwmleds definition and disable it,
as leds and pwmleds are mutually exclusive.
Update board documentation.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Timer/PWM Module (TPM) initial clock source is not selected.
Add initial clock source selection based on Devicetree configuration.
Rename clock sources definitions from LPUART specific to general names
usable by several modules on the SoC.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Register all the lpi2c instances.
Add no-power-level property and update driver
to adapt no-power-level property.
Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
In case of problem with parsing hex data from coverage dump,
do not create empty gcda file.
Such empty file will break gcovr parsing.
Signed-off-by: Piotr Kosycarz <piotr.kosycarz@nordicsemi.no>
Add board support for the nrf7002eb shield. This shield uses the
nordic edge-connector to be compatible with multiple boards.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
The native_sim has already been added to the test cases of
`drivers.ieee802154.build.external` is not being appropriately
processed because there is no corresponding overlay.
Create an overlay as an alias of native_posix.overlay.
Also, add the native_sim/native/64 platforms in the same way.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
The mcr20a driver referencing `MCR20Overwrites.h` which is under
`hal/nxp/mcux`.
So, put `depends HAS_MCUX` for clarify the dependency.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
When building with native_sim, We need to specify
```
#define _POSIX_C_SOURCE 200809L
```
to make `gmtime_r` available.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
After rebasing the PR on main, the local copy of the repository may
still contain untracked directories and files (for example, the commits
from the pull request are "git mv"ing files out of directories that are
then left empty). Add a git clean so that we run CI in conditions
that are as close as possible to a fresh clone.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
When an incoming PAN ID does not match or when an error occurs while
sending association requests, then locks were not properly released.
Fixes: #78495
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
gpio_basic_api test configuration drivers.gpio.2pin_arduino expects
arduino pins D2 and D3 to be available but they aren't declared in
arduino connectors for this board as not available by default.
Remove arduino_gpio compatibility declaration for now.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
Since the mkbox board ble f/w upgrade method based on binary
blobs that was proposed in #74255 has been turned down, all
the work done in hal_stm32 module to host blobs is now reverted.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Added new Kconfigs for defining permission level of GATT
characteristics that are part of the Bluetooth SMP service in the
MCUmgr subsys.
Removed the CONFIG_MCUMGR_TRANSPORT_BT_AUTHEN as the new Kconfig
options are mutually exclusive and need to be groupa as the Kconfig
choice option.
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
Let's run tests with security/privacy with the HW models acutually
running the encryptions, so in case of missaligned keys
tests fail.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Let's run tests with security/privacy with the HW models acutually
running the encryptions, so in case of missaligned keys
tests fail.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Let's run tests with security/privacy with the HW models acutually
running the encryption, so in case of missaligned keys
tests fail.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Let's run tests with security/privacy with the HW models acutually
running the encryptions, so in case of missaligned keys
tests fail.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Removed the experimental status from the BT_BONDABLE_PER_CONNECTION
Kconfig option used in the Bluetooth Host SMP layer. This feature
has been present in Zephyr for over a year without any issue reports
or API modifications.
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
Add the "kernel_shell.h" header which is required but missing,
causing build error.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
This commit re-enables the following platforms for the
`kernel.common.stack_sentinel` test:
* `hifive1`
* `m2gl025_miv`
These platforms working correctly after Renode was upgraded to 1.15.2 in
the CI.
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Add new script `pack_as_twister.py` to convert memory footprint
data prepared by `./footprint/scripts/track.py` into JSON files
compatible with Twister report schema. Next, the data can be
transformed and uploaded to ElasticSearch data storage the same
way as memory footprint (and other) reports executed by Twister.
Add to `plan.txt` an optional column with the corresponding
test suite names for 'footprints' as an example for test instance
name composing with `--test-name` command argumnent.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
The STM32 M4 Clicker is a basic development board for the ST STM32F415RG
Microcontroller. The board contains two LEDs and push buttons and several
headers for interfacing with external devices.
Signed-off-by: Ian Morris <ian.d.morris@outlook.com>
- Fixed the MX25UM51245G flash DTS write block size from 16 to a value
used by the flash_mcux_flexspi_mx25um51345g driver.
- Fixed flash partitions.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
Add a section to the docs ellaborating on the relationship between
Zephyr, the native simulator, the nRF HW models and BabbleSim.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
In case peer goes down or we disconnect from the network during the
TLS handshake, the TLS socket may block indefinitely during
connect()/accept(), waiting for data from the peer. This should be
avoided, hence use the preconfigured timeout for the TLS handshake,
same as we use for TCP-level handshake.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
cavs15, cavs18 and cavs20 were removed from Zephyr there is no
need to handle those platforms in the tool.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
Fixes the mailbox notification callback that was not
being called from the ISR when the other side sends
something.
Signed-off-by: Felipe Neves <ryukokki.felipe@gmail.com>
Add the missing #ifndef CONFIG_ZTEST_SHUFFLE in ztest.c file.
This fixes multiple definitions of NUM_ITER_PER_SUITE
and NUM_ITER_PER_TEST.
Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x1a0000000000000000) don't
> match for /soc/peripheral@50000000/i3c@36000/wm8904@1a
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x1a0000000000000000) don't
> match for /soc/peripheral@50000000/i3c@36000/wm8904@1a
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Ethernet board variant was missed in commit 138e9591f8 (tests: net:
wifi: exclude RW612 based boards), but is the sole variant that actually
was running this test. Exclude this variant only, since it cannot build
this test due to requiring binary blobs.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
This small change concerns the following filter functions:
1. `dt_compat_enabled(C)`:
There's a node with compatible `C` and status "okay".
2. `dt_enabled_alias_with_parent_compat(A, C)`:
There's a node with alias `A` and status "okay", and its parent
has compatible `C`.
3. `dt_label_with_parent_compat_enabled(L, C)`:
There's a node with label `L`, and its parent has compatible `C`
and status "okay".
All three functions involve checking whether some node or its parent has
a given compatible, but the way this has been checked is inconsistent.
Function (1) has done it with this Python conditional:
compat in node.compats
while (2) and (3) have used:
parent.matching_compat == compat
The first check works well with nodes that have multiple compatibles,
and it is more aligned with the notion of "has_compat" as seen in the
devicetree macros for C, CMake, and Kconfig.
Arguably, `matching_compat` shouldn't have been used here, because it is
actually a property of a node's binding, moreso than of the node itself.
In practice, it's usually equal to the first compatible for which edtlib
has found a binding, which at first glance is just more constrained than
the `node.compats` check. However, there also exist obscure cases where
the `node.compats` are empty, while the `node.matching_compat` is not.
For now, the three functions can use a combined check, to improve
consistency and utility while avoiding breakage:
node.matching_compat == compat or compat in node.compats
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
It has been deprecated since Zephyr v2.6.0.
The filter that replaced it - `dt_enabled_alias_with_parent_compat` -
had shared code with it, which can now be inlined into `ast_expr()` to
match the parser's overall code structure.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
DVFS medlow oppoint should use trim entry index 2,
this needs to be updated in hal/hal_nordic.
Currently this is not possible because of time
constraints that is why this temporary patch
is applied. This is the only point where
new_f_trim_entry is used.
Signed-off-by: Lukasz Stepnicki <lukasz.stepnicki@nordicsemi.no>
This adds a dt overlay to enable support of cc1352p7 lp
to the openthread coprocessor sample application.
Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
Some examples may require the usage of a second UART.
This adds UART1 to common launchxl.dtsi in order to make it
available for these examples.
Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
Sometime, the radio causes a bus error.
This happens because we cast a struct and access to a member
that doesn't exists in the original struct.
This updates the driver to use the right struct to make the cast safe.
Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
Currently, if we try to write data from a memory mapped flash address
to the flash then we get a -EINVAL error.
This could break the settings subsystem when we use NVS backend.
In order to make it work, add a buffer and use it when we want to
write data that is located in flash address space.
This has been tested using sample/subsys/settings/
Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
- Improved document structure (was *very* flat before) by adding more
meaningful top-level headings and re-ordering some of the existing
sections
- Provide detailed and structured docs for all the custom Sphinx roles
and directives available in Zephyr, including moving the docs for
``.. zephyr-app-commands`` directive and `:dtcompatible:` roles away
from the extensions' source files to align with how Sphinx typically
handles docs for custom roles/directives.
- Added more content regarding diagrams guidelines, images,
cross-referencing of Doxygen documentation, ...
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Increase navigation depth by 1 to enable "local" toc navigation in the
side bar for those pages that are deeper in the documentation tree.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Rather than testing each bit until the lowest set bit is found, we can
massage the input parameter to easily clear all bits except the lowest
set bit. When only one bit is set, both find_lsb_set() and find_msb_set()
return the same value.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
This defines raspberrypi,pico-xosc along with a configurable startup
delay multiplier. On some boards, the XOSC takes longer to stabilize.
Signed-off-by: Xudong Zheng <7pkvm5aw@slicealias.com>
Do not allocate TxFIFO in a way that could corrupt Endpoint Information
Controller data (stored at DFIFO Depth address) or access locations
outside the SPRAM.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add timer device name autocompletion to the commands.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
These callback functions are not used outside of the file, make
them `static`
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x1002c0) don't match for
> /soc/dma@100200
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This reverts commit 311ddf90e2. That
commit breaks firmware boot on both MTL and LNL.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
The script was only looking at the Zephyr base repository and failing to
look for soc roots e.g. in other modules.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
With the requirement in #78316 for Zephyr modules to always define
ZEPHYR_<name>_MODULE Kconfig setting then there is no longer a need
for this commit. Simplify check_compliance by reverting ths commit.
This reverts commit 35e28e6315.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Add missing colon to the entry introduced in #78285.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
When we have coexistence of hostapd and wpa_supplicant,
wpa_msg has different implementation.
So to let them work together, we need to have common implementation
for wpa_msg and dispatch msgs for hostapd and wpa_supplicant.
So add register zephyr_hostap_ctrl_iface_msg_cb,
and judge if ctx is hostapd by the first integer where ctx points to.
Signed-off-by: Fengming Ye <frank.ye@nxp.com>
Hostapd has TODO in hostapd_dpp_handle_config_obj,
to save DPP connector using wpa_msg.
AP DPP needs to use dpp_connector, dpp_netaccesskey and dpp_csign
in DPP Peer Discovery handshake in hostapd_dpp_rx_peer_disc_req.
So add AP DPP wpa_msg event handler to store these info.
Signed-off-by: Fengming Ye <frank.ye@nxp.com>
Add hostapd mgmt ops, some use same api as wpa_supplicant,
and DPP use different ops.
supplicant_dpp_dispatch use wpa_cli and hapd_dpp_dispatch use hostapd_cli.
And use common DPP param parse.
Signed-off-by: Fengming Ye <frank.ye@nxp.com>
Add DDR variant of the i.MX95 EVK board (M7 core). Using this
variant, one can run Zephyr from DDR instead of ITCM/DTCM
as it's the case for the M7 "base" board.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
This prevents an overlap with `storage_partition`
Additionally, it fixes the following warning:
> unit address and first address in 'reg' (0x20000) don't match for
> /soc/flash-controller@4001e000/flash@0/partitions/partition@19000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x60000) don't match for
> /qspi_flash@40890000/flash@60000000/partitions/storage_partition@70000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
For code clarity, this commit adjusts the use of `return` statements
in functions with a void return type as follows:
- Transform `return foo();` into separate statements:
`foo();`
`return;`
- Remove unnecessary `return` statements when
they don't affect control flow.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
By keeping track of run-time ATT MTU of all connected peers, it's
possible to increase the notification payload size; thus increasing
data-throughput sent over Bluetooth.
Note that this assumes the Bluetooth connection is properly configured
(with the corresponding connection parameters) to optimize performance.
This is application-specific and shall be examined on each scenario for
optimal performance.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
Parts related to the thread runtime stats are somewhat
standalone, refactor it out instead of having two #ifdef
and two places.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Split the `kernel_service.c` into multiple subcommand files,
each file would register with the main `kernel` cmd based on
the dependencies in Kconfig/CMakeLists.txt.
This greatly reduces the number of precompiler directives.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Deadloop happens when CONFIG_NET_ROUTING and VLAN are enabled.
In function net_ipv6_prepare_for_send(), pkt->iface will be
updated with net_pkt_set_iface(pkt, iface) in 2 scenarios:
1. ip_hdr->dst is onlink
2. check_route or nbr_lookup
VLAN is virtual-iface which attaches to a physical-iface. Each
time a packet being sent to a VLAN port will invoke twice of
the net_send_data(). The 1st time, pkt->iface is set to virtual
iface and the 2nd time to physical iface.
However in above 2 scenarios, at the 2nd time of calling the
net_send_data(), the pkt-iface will be changed back to virtual
iface. The system runs into a deadloop. This can be proved by
enabling CONFIG_NET_ROUTING with the VLAN sample.
The main purpose for net_ipv6_prepare_for_send() is to set the
right ll_dst address. If the ll_dst address is already set, then
no need to go through it again. If the packet has done with the
forwarding and set the ll_dst, then no need to check_route again.
And, the pkt->iface will not be changed back to virtual iface.
Fixes: #77402
Signed-off-by: Shrek Wang <shrek.wang@nxp.com>
Increased variable to the mandatory amount of commands, since the
comment of SHELL_SUBCMD_ADD states
"Number of mandatory arguments including command name"
but net suspend takes the interface number to suspend
Signed-off-by: Emil Lindqvist <emil@lindq.gr>
This commit removes the preposition "in" from the phrase
"in particularly"in the I2C and I3C Controller API sections
to improve readability.
Signed-off-by: Arrel Neumiller <rlneumiller@gmail.com>
This fixes the following kind of warnings:
> unit address and first address in 'reg' (0xf) don't match for
> /soc/adc@40012400/channel@15
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x3fc70) don't match for
> /soc/peripheral@40000000/flash-controller@34000/flash@9fc70
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warnings:
> unit address and first address in 'reg' (0x40094000) don't match for
> /soc/peripheral@40000000/usbhs@144000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x3fc70) don't match for
> /soc/peripheral@40000000/flash-controller@34000/flash@9fc70
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warnings:
> unit address and first address in 'reg' (0x40094000) don't match for
> /soc/peripheral@40000000/usbhs@144000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> devicetree error: unit address and first address in 'reg' (0x1) don't
> match for /soc/enet@30be0000/mdio/phy@0
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warnings:
> devicetree error: unit address and first address in 'reg' (0x70000)
> don't match for
> /soc/flash-controller@40020000/flash@0/partitions/partition@700000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x88000) don't match for
> <snip>/flash-controller@43000/flash@0/partitions/partition@80000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x70000) don't match for
> /soc/flash-controller@40020000/flash@0/partitions/partition@700000
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x1) don't match for
> /soc/enet@30be0000/mdio/phy@0
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x2) don't match for
> /enet@42890000/mdio/phy@0
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Add the function, i3c_device_is_controller_capable, to determine if
a target is controller capable.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
The Active Controller data struct for static addr is to always be
0x7E. This is so the active controller can be identified according
to section 5.1.9.3.7 of the I3C v1.1.1 Specification.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
The dev argument was missing for the doxygen for the function
i3c_bus_deftgts. Add a comment for it.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Use `test_adc` in io-channels to be consistent in whole
tests/drivers/build_all/sensor/adc.dtsi file.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Do not use SYS_INIT for initializing irq_offload when enabled, instead
using a new interface that is called during the boot process for all
architectures.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add a new call for initializing cache on architectures that need that.
Avoid using SYS_INIT for this and instead call the hook in a fixed place
and run if implemented.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
When at verbosity 1, we print out the status of TestInstances.
This makes it harder to notice changes at TestCase level,
which require perusing the logs.
This adds TestCase status and reason printing
if verbosity level is 2 or more.
Reason printing is suppressed if the reason is empty or None.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
The local function ll_gpio_get_pin_pull() is not always referenced. Add
the __maybe_unused attribute to avoid compiler warnings (which may be
promoted to errors by downstream users).
Signed-off-by: Keith Short <keithshort@google.com>
Since b249535 (sensors: Add channel specifier) the signature of
sensor_reconfigure_read_iodev() changed, but sensor_handlers.c
apparently hasn't been updated.
Fix compile time error by updating sensor_reconfigure_read_iodev()
signature in sensor_handlers.c
Signed-off-by: Andrea Merello <andrea.merello@iit.it>
This adds a kconfig to enable making the interrupts
non-preemptible by other interrupts. Enabling this will set
the INTLEVEL to the max non-debug level before clearing
the EXCM bit.
Signed-off-by: Christopher J. Champagne <christopher.j.champagne@intel.com>
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
All kscan drivers have been moved over to input, Mark the kscan driver
class as deprecated so it can be removed in the 4.2 release.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Replace several bools in volume controller with an atomic value.
Update how these values are modified so that we can better
prevent race conditions.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Rename the volume flag field from the generic "flags"
to "vol_flags" as the generic "flags" will be used for
other values in a future commit.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Fix USB w/ SPEED_OPTIMIZATIONS for LPC55xxx SoCs
Root cause was non-volatile register access,
which could get optimized by the compiler
(by -fschedule-insns, specifically)
Signed-off-by: Maxime Vincent <maxime@veemax.be>
test_dependent() was changed to test_entry() but one location was
missed - in a warning message string. Fix it too.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
namely:
- dt_nodelabel
- dt_alias
- dt_prop
these currently fail quietly.
This can cause some very confusing errors later on.
By adding `REQUIRED` to the function call one can
easily generate a more clear message:
required nodelabel not found: ...
Signed-off-by: David van Rijn <david@refractor.dev>
We don't own the thread that calls the final `bt_conn_unref()`. The
users might not be aware that they are re-using that poor thread's
stack.
Putting it on the system workqueue gives a predictable stack size and
thread priority for the invocation of the recycled handlers.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
More information in the test description.
Why: At the time of writing, this test exposes a bug in the Bluetooth stack
where all the RX buffers are in use, and the controller driver fails to
synchronously allocate a command response buffer.
This is manifested in an assertion failure in `hci_common.c`.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Why is it ok to use the sync pool?
Because command complete/status is processed in prio: that means on the
same stack as the `bt_recv()` call from the driver.
Why does it fix the issue?
Because the complete/status event goes into a pool that is guaranteed to
have one free buffer any time `bt_recv()` is not executing.
Since the driver is the one calling bt_recv(), it (hopefully) will
finish one `bt_recv()` before starting another one.
Fixes#78223
Co-authored-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
For composite operations, we should always check whether the TLV header
is present. Otherwise, all blocks are assigned to one resource.
Signed-off-by: Simon Walz <simon.walz@autosen.com>
The Block1 context for composite operations is not found, as all path
levels are compared. The incoming path level should therefore always be
taken into account.
Signed-off-by: Simon Walz <simon.walz@autosen.com>
Adds an optional hook that allows for appending additional
responses to the bootloader info command
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Imply CONFIG_INIT_AUDIO_PLL on nxp,dmic driver selection on
mimxrt685s/cm33. Make DMIC clock config dependent on the use of the
RT685's audio PLL.
Fixes a regression described in #77851.
Signed-off-by: Vit Stanicek <vit.stanicek@nxp.com>
update die_temp node for some stm32 boards,
need that for run sensor die_temp_polling samples.
don't need to modify sample.yaml
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Add pinctrl for flexcan2
Add EXP_SEL gpio hog for board mux selection during boot.
Add TJA1057 CAN PHY driver.
Update supported features in board document
Signed-off-by: Chekhov Ma <chekhov.ma@nxp.com>
Running sysbuilt tests fails because of missing "run" target.
This adds the default domain context to the command.
Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
Adds coverage for attempting to connect while already connecting
or connecting to a device that already exists.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
There is no reason to use our custom runners for docs build
as it's equally fast on GH default runners and allows doc CI
to be expedited more quickly even when our build farm is
busy.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Fix warnings caught by running west build. Another fix will have to go
in to see why twister was missing these.
#78348
Signed-off-by: Yuval Peress <peress@google.com>
Now that we support internally connected channels we should make the
pinctrl configuration optional.
Signed-off-by: Corey Wharton <xodus7@cwharton.com>
Adds support for configuring the STM32 DAC channel mode for internal
connections. This is only enabled for SOCs that support it.
Signed-off-by: Corey Wharton <xodus7@cwharton.com>
Due to the introduction of `shell_fprintf_normal` in PR #77192, we can
minimize caller overhead by eliminating direct `color` parameter passing.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Aligned the `struct shell *` argument name from `shell_ctx` to `sh`
for consistency with other drivers' usage of `sh`, and to match
the `shell_cmd_handler` argument name.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
The `<id>` argument was included in `cmd_i3c_ccc_getvendor`,
`cmd_i3c_ccc_setvendor`, and `cmd_i3c_ccc_setvendor_bc` but
was not processed.
Utilized `shell_strtoul` for proper parsing of the `<id>` argument
in these functions.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Resolved a compilation error where `maxwr`, `maxrd`, and
`max_read_turnaround` were incorrectly referenced.
The code was updated to correctly access these fields from
the `data_speed` structure.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
When using sendmsg() and if CONFIG_NET_IPV4_MAPPING_TO_IPV6 is
enabled, then the addr4 variable was set too late which was causing
null pointer access.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Removed deprecated native_posix as test platform.
Added unique sim_ids for tests with the psa as a overlay.
Fixed clang-format issues.
Signed-off-by: Ingar Kulbrandstad <ingar.kulbrandstad@nordicsemi.no>
When a message with invalid parameters is received, we must ignore it.
In this commit we check invalid parameters first.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
This commit adds the following tests:
- Simple test for bridging table
- Test bridging table state changes
- Test persistence storage of subnet bridge
- Test IV Index update with subnet bridge
- Test network key removal for subnet bridge
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
If use `IS_ENABLED` macro inside if statements but not as preprocessor
directives, we can always compile the code for settings even if settings
are not used. This allows to reduce amount of firmwares we need to build
in CI to ensure that code compiles.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
We must tcheck if buf has enough tailroom to fit another pair of keys or
pair addresses with direction.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
If relay feature doesn't have own adv set, it should use the main adv
set to send messages.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
When a synchronous API is used, the content of `buf` will not be
valid by the time the thread that called the synchronous API is woken up
again.
Therefore, the simplest way to solve this is when a user allocates the
buffer which will be filled up with the content of the buffer passed to
the model callback.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
When relaying a Network PDU to another subnet, we need to update sub
field of rx structure so that correct credentials are used. We also need
to update NID field of the Network PDU.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
The initial implementation of RPL check for Subnet Bridge wasn't fully
correct. It decides whether to relay or not a PDU based on RPL of only
received messages. However, the spec section 3.9.8 says:
```
In addition, a Subnet Bridge node shall implement replay protection for
all Access and Transport Control messages that are sent to bridged
subnets.
A Subnet Bridge node shall maintain the most recent IVISeq value for
each source address authorized to send messages to bridged subnets.
Messages received by the Subnet Bridge node with the IVISeq value less
than or equal to the last stored value from that source address shall
be discarded immediately upon reception. When a message is retransmitted
to a bridged subnet, the stored IVISeq value shall be updated. In this
way, bridged subnets are protected against replay attacks from other
subnets.
```
This was noticed with MESH/NODE/SBR/NET/BV-02-C test. It passes when
PTS misses the message at step 3 and 4, and fails when PTS manages to
receive the message.
This commit fixes the wrong behavior by removing argument for
`bt_mesh_rpl_check` function making store a new message and bypassing
`local_match` check in case of Subnet Bridge node.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
Though nvs backend checks whether the data passed to it is identical to
the stored one, this isn't guaranteed by other the settings api. We can
also avoid going into the settings subsystem since we know what was
actually changed.
This commit adds 2 flags that allow to control whether Subnet Bridge
or Bridging Table states were changed and skips storing if the certain
state was not changed.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
We store only filled up entries, but want to restore the entire table.
`bt_mesh_setting_set` fails if the restored length didn't match the
provided length.
This commit fixes the restoring of the bridging table by allowing to
restore any size as long as the stored size is less than the allocated
one and it is a multiple of the size of a single entry.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
Added support for the Bridge Configuration client and server
to the tester application.
Signed-off-by: Ingar Kulbrandstad <ingar.kulbrandstad@nordicsemi.no>
Adds subnet bridging functionality to the network layer.
Also fixes brg_cfg_srv for minor issues to get it working.
Signed-off-by: Omkar Kulkarni <omkar.kulkarni@nordicsemi.no>
Adds implementation for the Bridge Configuration Server model.
Updates `brg_cfg` module to add sanity check for
bt_mesh_brg_cfg_tbl_remove() API. Also, updates the unit test
accordingly.
Adds documentation for the Bridge Configuration Server model
Signed-off-by: Omkar Kulkarni <omkar.kulkarni@nordicsemi.no>
Implements the Bridge Configuration Client model.
Adds opcodes for all Bridge messages to `foundation.h`. Adds client-side
support for these messages.
Adds a new Kconfig option for the Bridge Configuration Client model to
configure the waiting time for respones for acked messages.
Signed-off-by: Håvard Reierstad <haavard.reierstad@nordicsemi.no>
Change the parameters of the bridge table add function to take an
entry struct rather than the fields of an entry.
Signed-off-by: Håvard Reierstad <haavard.reierstad@nordicsemi.no>
Changes status type to be status codes defined in Mesh Protocol 4.3.14
as defined for the `BRIDGING_TABLE_STATUS` message.
Signed-off-by: Håvard Reierstad <haavard.reierstad@nordicsemi.no>
The `brg_cfg` module implements the states needed for subnet bridge
feature. It provides two states - enable state, and bridging table
state. APIs are provided to access and modify the states. The module
handles responsibility of persistence of the states.
Signed-off-by: Omkar Kulkarni <omkar.kulkarni@nordicsemi.no>
Adding documentation and function calles for the API's
in Bridge Configuration Client model and Bridge
Configuration Server model.
Signed-off-by: Ingar Kulbrandstad <ingar.kulbrandstad@nordicsemi.no>
Any places that checked for GTBS is now always enabled
as GTBS is mandatory to support, and the Kconfig option
was removed.
Also removed a duplicate Kconfig option for TBS,
BT_TBS_SERVICE_COUNT, as it was unused.
The other Kconfig option BT_TBS_BEARER_COUNT is used
instead exclusively to set it if needed.
Since GTBS can now exist alone, it must also
support having its own calls and other values.
This means that the GTBS and TBS instances now share
the same underlying struct.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Correct used lines based on write opcode
regardless of the data mode.
The write opcode is set during init for all
modes and can be overwritten in DT.
Add lines correction for PP_1_1_2.
Signed-off-by: Georgij Cernysiov <geo.cgv@gmail.com>
nocache ram is usually used by DMA to transfer data between
peripherals and ram. Some chips use isolated nocache ram,
which does not necessarily have to be in RAMABLE-REGION.
By specifying the zephyr,nocache-ram options, users can specify
the region where nocache-ram is located. If the user does not
specify it, it defaults to RAMABLE-REGION.
Signed-off-by: Weiwei Guo <guoweiwei@syriusrobotics.com>
override the default flash driver with MIMXRT1050_SFDP_QSPI.cfx to support
LinkServer runner for qspi board.
Signed-off-by: Paul He <pawpawhe@gmail.com>
Otherwise we can't escape from DEPRECATED being selected, and so getting
build warnings. It doesn't make sense that the option replacing the
deprecated one is used to automatically enable it.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
PLATFORM_SPECIFIC_INIT is deprecated.
Update nxp hal to sha 77815705c465627b8436cbac51f0bf0594bbeba2
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Deprecate support for configuring the MCO source and prescaler from
Kconfig configurations.
This is now done by devicetree and an MCO driver instead, which also
configures the pin to be used by the MCO peripheral.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Add stm32f746g_disco board to MCO sample.
This board has 2 MCO instances so useful to show multiple instances
as well as checking the implementation.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Add MCO device nodes to the STM32 boards.
The set of supported boards are chosen to replace what is currently
supported in Kconfig.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Add device driver for STM32 MCO peripheral which takes configures
the MCO clock source and prescaler, and outputs it on one of the GPIO
pins.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Add macro for encoding MCO bit values into the CFGR register
of RCC. Add macros for decoding and extracting the different fields.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Add MCO select and prescaler macros to set bits in the RCC CFGRx
register.
The set of supported boards are chosen to replace what is currently
supported in Kconfig.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Add clock sources that can be output by the MCO on the stm32f1x and
stm32f10 connectivity line devices.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Add clock sources PLL2CLK, PLL3CLK and EXT_HSE.
Needed to check that these clocks are enabled in MCO code.
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
Extracted common SPI RTIO operations from the spi_mcux_lpspi driver
into spi_rtio, which should be common across RTIO drivers.
Tested with spi_loopback with and without CONFIG_SPI_RTIO. Ran on
mimxrt1010_evk.
Also, verified the other SPI RTIO driver (spi_sam) is not broken by
these changes (tested building for target: robokit1 with the same
conditions as above).
Signed-off-by: Luis Ubieda <luisf@croxel.com>
As a step to make them common code: spi_rtio.c.
Verified this refactorization builds and passes spi_loopback, both with
CONFIG_SPI_RTIO enabled, as well as disabled. Tested on mimxrt1010_evk.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
Add board support for eval board ganymed_bob, which
is a break-out-board for both soc variants.
Variants of the soc are GBM and GEN1.
Signed-off-by: Sven Ginka <s.ginka@sensry.de>
This change will allow users to configure the Ethernet RX thread
according to their specific real-time requirements.
Adding preemptive threading helps to reduce jitter and
the impact of Ethernet traffic on real-time performance.
Signed-off-by: IBEN EL HADJ MESSAOUD Marwa <marwa.ibenelhadjmessaoud-ext@st.com>
Zephyr provides a feature to hook in custom menuconfig implementations
by setting EXTRA_KCONFIG_TARGETS and then defining the corresponding
command to invoke as EXTRA_KCONFIG_TARGET_COMMAND_FOR_<target>.
This feature is broken with sysbuild because sysbuild will try to create
multiple custom targets with identical names.
This commit fix the sysbuild handling of extra kconfig targets.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
-add nucleo_u083rc and stm32u083c_dk boards for testbench purpose.
- add min_ram property to skip test on boards with little ram size.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
-enable dac in nucleo_u031r8, stm32u083c_dk and nucleo_u083rc
- add dac as new supported interface in docs
- update yaml files
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
remove check for system clock frequency in clock_stm32_ll_h7 because of
addition of fracn (difficult to handle)
Signed-off-by: Nathan Olff <nathan@kickmaker.net>
Replace the busy boolean flag with an atomic value.
This prevents any race conditions with the MPL implementation.
Modifies where the new atomic value is set and cleared
so that initialization gets to finish before allowing
any reads.
Due to how the MPL is structured, and how a select cannot
be rejected from OTS, this does not give a perfect solution.
Ideally we need a separate object per OTS object, rather than
a shared one, and/or the OTS implemenation would allow
us to reject a select if the object is not currently
available or ready.
This commit does not fix the above issues, as that is a
larger undertaking.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Follow-up: #77887
The macros:
- toolchain_ld_base
- toolchain_ld_baremetal
- toolchain_ld_cpp
was deprecated in 5db1f1ae8f but no check
was added to FindDeprecated.cmake, meaning toolchains still providing
those macros was not getting a proper deprecation warning.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Some dict.get() calls did not use a TwisterStatus
as a default value, thus using a NoneType where
TwisterStatus should appear.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
Aligns the logging unhandled vs events with the regular ones.
Now it prints out the code and length.
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
The STM32WB06 and STM32WB07 SoCs do not support SMPS output current limit.
This makes the LL_PWR_SetSMPSPrechargeLimitCurrent function and all the
LL_PWR_SMPS_PRECH_LIMIT_CUR_xxx defines not visible when one of these SoCs
is selected, resulting in a build failure.
Fix this by only handling SMPS current limit when the feature is available.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Indicate in the STM32WB0 power controller binding that the SMPS output
current limitation is a feature only available on STM32WB05 and STM32WB09.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Various tests and samples use POSIX-only functions. Define _POSIX_C_SOURCE
to ensure they are visible.
Signed-off-by: Keith Packard <keithp@keithp.com>
These functions requre non-null parameters; passing them NULL
values is undefined. Remove tests which are not valid.
Signed-off-by: Keith Packard <keithp@keithp.com>
We need to add _POSIX_C_SOURCE to this file as it uses POSIX values from
limits.h including IOV_MAX, CHILD_MAX and ARG_MAX.
Signed-off-by: Keith Packard <keithp@keithp.com>
Picolibc's sys/_timeval.h (which Zephyr shouldn't be using) needs
sys/types.h to be included first so that __suseconds_t is defined.
Signed-off-by: Keith Packard <keithp@keithp.com>
Select TC_PROVIDES_POSIX_C_LANG_SUPPORT_R to keep Zephyr from
including the common libc implementation of the various _r APIs.
Signed-off-by: Keith Packard <keithp@keithp.com>
POSIX_THREAD_SAFE_FUNCTIONS already selects POSIX_C_LANG_SUPPORT_R and
POSIX_C_LANG_SUPPORT_R alread selects all of the COMMON_LIBC_*_R values.
That makes the 'default y if POSIX_THREAD_SAFE_FUNCTIONS' clauses in these
symbols redundant.
Signed-off-by: Keith Packard <keithp@keithp.com>
options/fs.c and options/timer.c both use POSIX-only functions. To ensure
those symbols are visible from the underlying C library, define
_POSIX_C_SOURCE.
Signed-off-by: Keith Packard <keithp@keithp.com>
struct itimerspec is only required to be available when building with
_POSIX_C_SOURCE defined. Applications including posix/time.h without
defining _POSIX_C_SOURCE will need to have a forward declaration of struct
itimerspec even if they don't use the functions requiring that type.
Signed-off-by: Keith Packard <keithp@keithp.com>
When _POSIX_C_SOURCE is defined by a source file, a POSIX-conforming C
library will define TZNAME_MAX in limits.h. Avoid redefining this
in Zephyr's posix_features.h.
Signed-off-by: Keith Packard <keithp@keithp.com>
picolibc sets _CLOCKID_T_DECLARED and _TIMER_T_DECLARED, not
__clockid_t_defined and __timer_t_defined.
Signed-off-by: Keith Packard <keithp@keithp.com>
There's no reason for the .exported_sym data to always land at one end of a
data region; the order of sections depends on the whim of the compiler and
assembler.
Ignore overlaps between that region and other data regions.
Signed-off-by: Keith Packard <keithp@keithp.com>
GCC complains about struct sockaddr accesses due to the various
address-family-specific variants being of differing sizes. Let's not
mess with code (which looks correct), just silence the compiler.
Signed-off-by: Keith Packard <keithp@keithp.com>
ctime.c and localtime_r_utc.c may use POSIX-only functions; to ensure those
are visible from a POSIX-conforming C library, define _POSIX_C_SOURCE in
these source files.
Signed-off-by: Keith Packard <keithp@keithp.com>
This board is not currently available for the general public, and the
documentation page adds no value whatsoever. Remove it until the board
is finally available and its features and support can be documented
properly.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
Commit 911abc33e6 did move the samples
from subsys/ to drivers/, and more contribution came in parallel.
This covers extra board configurations added later which also need
moving.
Signed-off-by: Josuah Demangeon <me@josuah.net>
The test_target_position test used a stack allocated `poll_signal` which is
kept as a refrence inside the gpio driver. Since the time for polling the
signal was chosen pretty narrow, the function exited with the driver still
trying to signal the stack allocated value upon movement completion.
Fix by adding the structs to the test fixture and increase the timeout.
Resolves#78466.
Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
This fixes the following warning:
> unit address and first address in 'reg' (0x3e800) don't match for
> /soc/flash-controller@400e0000/flash@0/partitions/partition@fe800
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
When testing these functions with CONFIG_NATIVE_LIBC, force the TZ
environment variable to UTC to ensure they produce the expected results.
Signed-off-by: Keith Packard <keithp@keithp.com>
NATIVE_APPlICATION (old native_posix) does not support bulding with the
any other library than the host libC (EXTERNAL_LIBC).
MINIMAL_LIBC_SUPPORTED defaulted to y always, and instead the depends
was set in the MINIMAL_LIBC choice.
This lead to the right library selected, but an incorrectly set
MINIMAL_LIBC_SUPPORTED.
Many tests filter based on MINIMAL_LIBC_SUPPORTED, so they were
not filtered out appropriately.
Let's place the depends in the right place to avoid this problem.
Also remove a redundant depends on for PICOLIBC and NEWLIB_LIBC
which already have the dependency in their respective _SUPPORTED
option.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
The http_client sample ignored connect() errors and attempted to run
HTTP query even if the connection failed.
Additionally, in case the query failed, the sample called `exit(1)`
directly, causing busy-looping in the sample. This prevented the logger
output from being printed.
Both of those issues made the sample behavior very confusing when it
encountered connection problems. The sample did not print any output at
all (due to busy looping) or printed several connect failures (due to
ignoring connect() results). This commit fixes those problems.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Commit 47187a9ec9 made the `pinctrl` property
of STM32 ADCs optional, to allow usage of internal channels without wasting
GPIO pins. However, the driver was not adapted to support this new usecase.
(The real bug comes from commit 93956b2073,
that transitioned from a custom `stm32_dt_pinctrl_configure` function to
the standard `pinctrl_apply_state`, without accounting for the fact that
the former returns 0 when pinctrl is empty, but the latter returns -ENOENT)
Modify the driver to work even if no `pinctrl` is present on the ADC node.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Few tests with wrongly names platforms. This section is now being
verified for correctness like all others.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Document the recommended practice regarding having default definitions for
module-specific Kconfig symbols.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
There are HCI drivers which reference the module-specific Kconfig symbols
which are auto-generated when the modules are present. Provide default
definitions for these symbols in case the modules are missing, so that
compliance checking doesn't stumble over seemingly non-existent Kconfig
options.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
Refactors the cmake and kconfig bits of the tdk sensor drivers into the
vendor subdirectory to make them consistent with other vendor-sorted
sensor drivers. The tdk driver implementations were previously moved
into the vendor subdirectory in commit
41f1c3a2b7.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
Adds missing code-sample directive to the Hello World sample in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
fixed some ReST/Sphinx lint issues missed in earlier cleanups
prior to introducing Sphinx-linter in compliance check
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
On platforms with enforced memory access modes, .text is read-only.
Move hpsram_mask to a cached data section to fix PTL.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Use a new file and command for this where all CS commands
can live.
Added support for bt_cs_set_default_settings command.
Added test case where shell is built with CS to ensure code
is built in CI.
Signed-off-by: Sean Madigan <sean.madigan@nordicsemi.no>
Added support for a new API for setting default channel
sounding settings, this is mainly a wrapper around the HCI
command.
For this add a new module for channel sounding, where new
channel sounding APIs will go.
Signed-off-by: Sean Madigan <sean.madigan@nordicsemi.no>
Allow IRQs to work on every hart regardless of the mapping
of the contexts.
Add a test to validate the hart-context mapping.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
`-` is preferred over `_` in devicetree property names.
Since, change `clk_src`, `clk_div`, and `clk_out_div` to
`clk-src`, `clk-div`, and `clk-out-div`.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
This new alias provides a handy shortcut for listing the Kconfig options
that are required for a given symbol to be available.
Fixes#76578
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
If adding/removing to the domain of the current running
thread, we need to update the hardware MPU regions or else
the addition or removal would not be reflected to current
running thread.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds a spinlock to make sure writing to hardware MPU
regions is atomic, and cannot be interrupted until all
regions are written to hardware.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Define a macro to validate aux offset value as it is checked
both in LLL and ULL execution contexts.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix Controller hang due to infinite looping caused by
duplicate node_rx enqueued in auxiliary context.
When LLL scheduling is not applied due to invalid aux offset
then ULL scheduling too would skip setting up the reception
after similarly checking the validity of aux offset required
to schedule the reception of auxiliary PDU. This check in
ULL was after the received node_rx being enqueued into the
auxiliary context causing a loop in the list of node_rx.
Dequeue of a list with a loop of node_rx caused an infinite
loop execution in the Controller.
Regression introduced in commit 3590bd648f ("Bluetooth:
Controller: Fix missing invalid aux offset check").
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Add assertion check to catch infinite loop due to incorrect
node_rx release.
If same node_rx is released twice then it can lead to
infinite looping when releaseing link or node_rx buffers.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Adds missing code-sample directive to all the arch samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
tfm_ipc sample is now using the zephyr:code-sample directive so it should
be referenced with the respective role, not :ref: anymore.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
ReStructuredText can sometimes be tricky to get right, especially for
folks that might be more familiar with Markdown.
This adds a Sphinx/RST linter to the compliance check script to help
catch common issues that can easily go unnoticed and cause rendering
issues.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
trivial typo fix where single backticks should be used instead of double
for the sphinx role kconfig:option
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Commit 204860857e (PR #41061) dropped
support for "any" as the default role, so this should be dropped from
the documentation guidelines as well.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Fixes bad usage of single backticks in lieu of double backticks for
rendering inline literals, or simple '*' for italics.
When appropriate, a better construct than double backticks has been
selected (ex. :file:, :kconfig:option:, :c:func:, ...), or proper :ref:
have been used if the original intention was to have a link.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Replace the booleans used by the VOCS client to use
an atomic value instead.
The flags are modified to be used in a way that prevents
race conditions.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Rework how flash is initialized in esp32 SoC.
"esp_flash_app_init()" will make sure proper cache handling
will be set in place.i
Fixes#77551
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Adds missing code-sample directive to all the tfm_integration samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Board samples were listed in a very flat way before.
This commit introduces the appropriate toctrees to fix this.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to all the TI samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Enjoydigital board samples in samples/boards/enjoydigital to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Nuvoton board samples in samples/boards/96boards to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Raspberry Pi board samples in samples/boards/raspberrypi to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Google board samples in samples/boards/google to
keep samples/boards/ organized by vendor
Added zephyr-code-sample directive to twinkie sample
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Phytec board samples in samples/boards/phytec to
keep samples/boards/ organized by vendor
Added zephyr-code-sample directive to mesh badge
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Intel board samples in samples/boards/intel to
keep samples/boards/ organized by vendor
Added missing code-sample directive to the code relocation sample.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Quicklogic board samples in samples/boards/quicklogic to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all STM32 board samples in samples/boards/st to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to all the STM32 samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Microchip board samples in samples/boards/96boards to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to all the 96boards samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all 96boards board samples in samples/boards/96boards to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to all the micro:bit samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Phytec board samples in samples/boards/bbc to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to all the NXP samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all NXP board samples in samples/boards/nxp to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Nordic board samples in samples/boards/nordic to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to all the nRF samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Group all Microchip board samples in samples/boards/espressif to
keep samples/boards/ organized by vendor
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to all the ESP32 samples in
preparation for upcoming changes to the Zephyr documentation that will
be leveraging the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Update Zephyr fork of MCUboot to revision:
e890df7ab975da181a9f3fb3abc470bf935625ab
Brings following Zephyr relevant fixes:
- e890df7a boot: zephyr: Add ESP32C2/ESP8684 support
- 5d5f0492 bootutil: Fix AES and SHA-256 contexts not zeroized
with mbedTLS
- ca06b9fe boot: zephyr: Add fallback to USB DFU
- 43a49a3b bootutil: Add better mode selection checks
- 956311d2 boot: Make boot_enc_valid take slot instead of image
index
- 242db1a9 boot: zephyr: boards: Add nrf54l15dk configuration
- 651775b5 boot: zephyr: board: Fix nrf54l15pdk Kconfig fragment
- a3762626 boot: zephyr: MCXN947 currently only does not support
swap mode
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Ever since 059aae7c91 (cmake: modules:
dts: make Device Tree error messages more visible, PR #76472), warnings
generated by gen_defines.py got only printed when the exit code signaled
an error.
Without this patch, the warning gets swallowed and the build continues:
```
$ west build --pristine --board nrf54l15pdk/nrf54l15/cpuapp \
samples/userspace/hello_world_user
<snip>
-- Found BOARD.dts:
<snip>/boards/nordic/nrf54l15pdk/nrf54l15pdk_nrf54l15_cpuapp.dts
-- Generated zephyr.dts: <snip>/build/zephyr/zephyr.dts
<snip>
```
With this patch, the behavior is back to how it was before
059aae7c91:
```
$ west build --pristine --board nrf54l15pdk/nrf54l15/cpuapp \
samples/userspace/hello_world_user
<snip>
-- Found BOARD.dts: <snip>/nrf54l15pdk/nrf54l15pdk_nrf54l15_cpuapp.dts
unit address and first address in 'reg' (0x5004c000) don't match for
/soc/peripheral@50000000/vpr@4c000/mailbox@1
-- Generated zephyr.dts: <snip>zephyr/build/zephyr/zephyr.dts
<snip>
```
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
The sync timeout is in 10 ms units. The sync_create_timeout_ms variable
already takes into account that we want to have a timeout of at least
7 events.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
Update net-setup script and config to support creation of
multiple network interfaces in the host.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
We do not need promiscuous mode setting in host side when testing
bridging with native-sim, so just ignore errors in this case.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
If you interrupt process() operation, we want Twister
to exit as gracefully as it can. This avoids the
UnboundLocalError that could appear e.g.
when interrupting the operation via SIGINT.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
Add callbacks for setting and getting the sample rate. The callbacks are
optional if all Clock Source entities support only one sample rate.
This commit results in working High-Speed operation with Windows UAC2
driver when the Clock Source is host-programmable. Windows UAC2 driver
won't work if setting sample rate fails even if Clock Source supports
only one sample rate.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Do not schedule isochronous data on current frame. While doing so can
work at Full-Speed, it is pretty much impossible to do it quickly enough
at High-Speed.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Queue explicit feedback write once the previous one finishes in order to
make it possible to cope with 8x faster High-Speed pace. This matches
the originally intended behavior described in comment.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Generate Full-Speed and High-Speed descriptors based on full-speed and
high-speed instance properties. Use appropriate descriptor set based on
active speed.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
This commit introduces the option to place the mbed TLS heap in a custom
memory section. The heap might be quite large depending on concurrent
TLS connections, thus it might be needed to place this manually
Signed-off-by: Emil Lindqvist <emil@lindq.gr>
pickup the change in hal_nxp about add support
the missing features and remove the unsupported bits
Signed-off-by: Tu Nguyen Van <tu.nguyenvan@nxp.com>
Fill the memory of all CPU's IRQ stack with 0xAA on init, so
that `z_stack_space_get` can calculate the remaining space
correctly.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
There is an issue on the SHI hardware peripheral to detect CS
rising/failing with bits CSnFE/CSnRE in the EVSTAT2 register in
npcx9m7fb chip. This commit workarounds it by using MIWU to detect the
CS rising and failing.
Signed-off-by: Tom Chang <CHChang19@nuvoton.com>
Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
The internal flash size of npcx9m7fb is 512KB. Reduce the default
Code RAM size from 320KB to 256KB because the Code RAM size is limited
by FLASH_SIZE/2 in the Chromebook EC application.
Signed-off-by: Tom Chang <CHChang19@nuvoton.com>
Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
Generic hook infrastrucutre was added to Zephyr, but NXP MCXC SoCs
were not updated accordingly.
Use generic hook infrastrucutre for MCXC SoCs.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Add common default flash partition layout for nrf52840 as many boards
have used identical flash layouts.
The default flash layout was updated to remove scrach in 2022 (9a84258)
but almost all boards were still using the previous layout, so this
updates them to the new layout with allows for larger applications.
This commit also incorporates feeedback from @nordicjm in PR #77791 to
change slot0 to 0x00077000 and slot1 to 0x00075000: "If you use swap
using move, you need a sector for the data to be moved up by, and you
need space for the swap status fields, which is about a sector, so by
making the changes here you get the full 0x65000 for an image, without
these changes you get 0x64000.
Signed-off-by: Jacob Winther <jacob@9.nz>
qemu_xtensa_dc233c didn't pan out like I expected, needed to be
qemu_xtensa/dc233c/mmu to be excluded.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
This commit adds a test to showcase how to configure TLS 1.2 and 1.3
socket connections against an OpenSSL server. Only a limited number
of combinations are available for now:
- TLS 1.2
- RSA certificate and key exchange.
- ECDSA certificate and ECDHE key exchange.
- TLS 1.3 only supports ephemeral (ECDHE) key exchange with/without
session tickets.
Since the goal is to test TLS connection and not low level ethernet
functionalities or similar, the only supported platform is "native_sim"
where Linux sockets are used to connect to the OpenSSL server locally.
The idea is that the Zephyr application acts a client and tries to connect
to the OpenSSL server running on the same PC. For sake of simplificity a
bash script is provided to start the OpenSSL server properly.
For completeness a bash script is also provided to re-generate
certificates and keys.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
According to Mbed TLS changelog this feature was set default ON
since 3.1.0 release, so the build symbol is no more available.
This commit removes it from Zephyr.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
Verify NRF GPIO driver with NRFX interrupts disabled.
Verify that driver handles properly 'get' and 'set' api methods.
When calling interrupt enable driver should report
'function not implemented' error.
Signed-off-by: Bartosz Miller <bartosz.miller@nordicsemi.no>
This test uses two LLEXT objects: one of them exports a symbol and
the other one calls the exported function.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
When identifying the size of an extension image we simply need its
size in bytes, not the number of array elements, that contain it.
Both happen to return the same value, because we use arrays of bytes,
but using sizeof() is clearer.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
By enabling debugging information it becomes way much simpler
to find the root cause of a failing unit test as we can simply
run it with a debugger.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
Replace the boolean values for the BAP Broadcast Assistant
with an atomic value. This prevents a rare, but possible,
race condition.
The busy flag has been replaced with 3 atomic values which
provide better granularity in error handling, and allows for
some concurrent write and read requests.
To describe the new behavior, the return values in the documentation
has been updated, and the error handling in the API
functions has improved.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Install the second instance to 0x8(uei), because MSI is installed
to 0x3(msi) when SMP is enabled.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Move the lock out from the `plic_irq_enable_set_state()` function
to cover the entire configuration process, so the whole of
enable/disable is atomic.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Fixing a bug where during the bus_init routine, when a slave is
initialized, the target hardware can get an interrupt, and this can occur
before the target_config structure is assigned; the generic IRQ handler
attempts to use this structure to grab callback function pointers, but
with no target config it attempts to access the structure member from a
null pointer. Fix works by adding ternary operation during IRQ that first
checks if target_config is null or not.
Signed-off-by: Matthew Mulloy Steinborn <mulloystmatthew@meta.com>
Add a bool fn so there is some room for a comment explaining why this is
not guarded by an IS_ENABLED().
Also add an optimization when building with an onboard controller.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
The code was a bit hard to read. From what I understood, the intent is
to not send the PHY update if we are already on 2M symmetric.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Align settings and DFU partition definition with the values, specified
by the design documentation.
Signed-off-by: Tomasz Chyrowicz <tomasz.chyrowicz@nordicsemi.no>
Drop some exclusions for python 3.6, this version is not tested in the
first place anyway so these are redundant.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
"type | None" syntax is only available with Python from version 3.10,
fix building with earlier 3.x Python versions.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
This commit adds a KConfig option and an API to set the interval in
which chunks get send, in milliseconds.
Signed-off-by: Kyra Lengfeld <kyra.lengfeld@nordicsemi.no>
using arduino header to simplify test settings.
arduino_header D2 and D3 can be used by default.
alt: 118 platforms are enabled for this test.
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Add simics as a simulation platform allowing running platforms
supported in simics to be run using west or twister.
Originally authored by: Maureen Helm
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Adds new CMake extension functions that allow setting board-specific
emulator arguments, similar to existing support for setting
board-specific runner arguments.
Originally authored by: Maureen Helm
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Before this change, headings in documentation pages were using the same
font family as the rest of the content, which made them blend in too
much.
This introduces a humanist font stack for the headings as well as some
minor tweaks to make the hierarchy of the document clearer through
better differentiation of the different levels (i.e. not just relying on
font size).
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
added a missing dvh causing footer to be footer to be displayed outside
of the viewport on mobile when browsing "Desktop site" version, and also
added fallback "vh" rules for slightly better browser compatibility.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Include `qemu_cortex_a53` (ARMv8-A ISA) target in intergation platforms
for LLEXT subsys tests.
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
Adds support for all relocation type produced by GCC
on AARCH64 platform using partial linking (-r flag) or
shared link (-fpic and -shared flag).
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
Removed arch-specific symbols that are not used. They should be placed
in arch-specific implementation for LLEXT subsystem that is currently
missing.
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
Replace use of 32-bit architecture macro to macro arch agnostic that
is resolved in compilation.
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
Replace boolean flags with atomic.
This also properly add guards for the multi-device procedures
and reduce the number of places where the busy flag is set.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Replace the busy boolean flag with an atomic value.
This prevents any race conditions with the MICP client implementation.
This also adds a missing check for the discovery procedure.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
TMP variant without combine channel feature is used in some NXP SoCs.
Build error occurs for such socs because of accessing unavailable
struct member in hal.
Fix it by adding #if directive to check the feature presence.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Replace the busy boolean flag with an atomic value.
This prevents any race conditions with the implementation.
The discovery procedure is also now properly guarded with it
so that in case that any procedure is currently in progress
for the specific connection, then a new discovery procedure
cannot happen until all other procedures are finished.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add Zephyr UDC (USB Device Class) and clk_hsi48 (hi-speed
internal 48 MHz) devicetree nodes so that the nucleo_l496zg
board works with other USB DC samples and tests.
Update the board yaml description to indicate usb and usb
device roles are supported.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
this adds the option to have the clock periodically resynced with
the time from the sntp server, instead of just syncing at startup.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
To avoid possible linker warnings, when the linker may end up placing
this section in a segment with text and therefore with execute
permissions, with let's move it next to the .data section.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
To avoid possible linker warnings, when the linker may end up placing
this section in a segment with text and therefore with execute
permissions, with let's move it next to the .data section.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Let's make it possible to use the newly introduced definitions
for separated sub-sections for .data and .text symbols in the
NATIVE_SIMULATOR_IF (symbols visible to the runner and other
images).
Note all symbols anothed like before with just
NATIVE_SIMULATOR_IF will keep next to .text just like before.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Align with native_simulator's upstream main
b4b9791ac822ae300363dc3ebbc7b7ac200632ce
Which includes:
* b4b9791 NATIVE_SIMULATOR_IF macros: Provide version with explicit
section names
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
If a test was written outside 'app_root' the 'app' path may contain
previous directory ('..') which would lead to the compilation file being
written outside the 'WORK_DIR'.
Fix the issue by checking if the 'app' is inside 'app_root', if it's
not, use the absolute path to the app for creating the 'this_dir'
variable.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
The bsim boards, just like the real ones, use the common
nordic DT definitions, but this were not triggering CI.
Some issues got in main due to this. Let's be sure to trigger
this workflow also when the releavnt DT files are changed.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Before unmapping a memory page, the cache is flushed. If the given memory
page is not mapped, this operation ends with a cpu exception on the
ptl platform. Add check if tlb translation is active before flushing.
Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Create a file to be used in CI or locally that lists all enabled/disabled
checks.
Can be passed as a CMake argument or set as environment variable:
CODECHECKER_CONFIG_FILE=$ZEPHYR_BASE/tests/codechecker_config.yaml
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
If we're running in a twister context, use the information as sane
defaults for CodeChecker.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Update the pyocd runner configuration of the nucleo_g0b1re
to use the correct target.
Pyocd had issues only just after the release of the G0B1/C1 line.
This issue has already been fixed a few releases ago.
Signed-off-by: Thomas Stranger <thomas.stranger@outlook.com>
Add kernel reboot support, so can use shell to verify reboot function.
uart:~$ kernel reboot cold
Known issue is imx93 currently can only support cold reboot and doen't
support warm reboot.
Updated board document.
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
If PSCI is enabled, it will leverage psci reset API to achieve system
reboot, otherwise a weak dump reboot API is provided, and platform
can override these APIs if platform specified implementation provided.
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
This changes how some arguments are set in the `Handler`s.
`options`, `generator_cmd` and `suite_name_check` are now passed as
arguments to the constructor rather than injected from an other module.
Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
Python 3.12 warns that
> Testing an element's truth value will raise an exception in future
> versions. Use specific 'len(elem)' or 'elem is not None' test instead.
> if elem_ts := root.find('testsuite'):
Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
CONF_FILE, DTC_OVERLAY_FILE and OVERLAY_CONFIG are deprecated but still
used by the tests causing warnings when running them.
This adds a test_data specific to validate the emission of the warning,
and removes the offending args from the other test_data files.
Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
Space separated lists are deprecated but this notice is not checked for.
extract_fields_from_arg_list also converts lists back to space-separated
lists causing a warning on get_scenario
Signed-off-by: Wilfried Chauveau <wilfried.chauveau@arm.com>
Adds Device Tree include files for all MCUs in the STM32WB0 series.
These DTSI files only contain the supported peripherals for now.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
The existing hwinfo driver for STM32 is incompatible with STM32WB0 series.
Prevent compiling the driver if the target's series is STM32WB0.
This fixes the build failure on the drivers.hwinfo.api test.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Adds a basic driver for the STM32WB0 flash controller (read/erase/write).
Extended operations are not supported by this driver.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Adds a driver for the STM32WB0 series GPIO interrupt controller.
This driver implements the STM32 GPIO INTC API, along with an extension
function used to check if a specific line is available on current board.
This also extends the GPIO INTC API to support level-sensitive interrupts,
as this feature is available on STM32WB0.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
The RADIO and RADIO_TIMER HAL modules will be required to
implement BLE support for STM32WB0 series.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Update the West manifest to point to an updated version of the STM32 HAL
compatible with WB0 series thank to inclusion of STM32CubeWB0 package.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
overhaul sample criteria and what we expect in a sample, especially
overhaul the twister part and what should be provided for good test
coverage.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This patch addresses an issue in the ACE platform power management code
where the HST domain suspend operation was performed after the IMR
context save. This resulted in the power management context being
restored with outdated values upon wake-up from D3 state, leading to a
failure to resume the HST domain correctly.
By moving the `pm_device_runtime_put(INTEL_ADSP_HST_DOMAIN_DEV)` call
before the IMR context save, we ensure that the HST domain is suspended
with the current context, and upon resume, the power management context
has the correct information to restore the HST domain state.
Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
Add testcases for ICBMSG on nRF54L15 with only one endpoint,
including non-multithreading case.
Signed-off-by: Magdalena Pastula <magdalena.pastula@nordicsemi.no>
introduction of O_TRUNC flag has conflict with libc flags,
so realtered posix open flags based on the commit
499a633976 ("posix: device_io: use mode argument correctly in open()")
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Signed-off-by: Karthikeyan Krishnasamy <karthikeyan@linumiz.com>
Rework comment text for FAKE_ENTROPY_NATIVE_POSIX used as
entropy driver for the Controller on BOARD_NRF54L15BSIM.
Relates to commit 34b6b3d9eb ("Bluetooth: Controller:
Support FAKE_ENTROPY_NATIVE_POSIX").
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Mbed TLS automatically sets PSA_WANT_KEY_TYPE_[RSA/ECC]_KEY_PAIR_BASIC
whenever "_IMPORT || _EXPORT || _GENERATE || _DERIVE" operations
are set. Therefore we just set the proper actions where required.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
Adding myself as a collaborator for video driver category.
Add the samples/drivers/video/ to the MAINTAINERS.yml
Signed-off-by: Josuah Demangeon <me@josuah.net>
This sample demonstrates how demand paging can be leveraged to deal with
firmware bigger than the available RAM if XIP is not possible. Select
code can be tagged to be loaded into memory on demand, and also be
automatically evicted for more code to be executed when memory is
exhausted.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Convention is to call k_mem_page_fault() with IRQs enabled if they were
enabled when the fault occurred.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
This has two purposes: maintain the accessed and dirty page states, or
call the generic demand paging fault handler otherwise.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
A page table entry used for demand paging is always from the last level
page table and never completely zeroed. Anything else is considered
ARCH_DATA_PAGE_NOT_MAPPED.
Loaded pages use a PTE_PAGE_DESC table entry type. Paged-out pages use a
PTE_INVALID_DESC table entry type and the physical address field is
reused to hold the backing store location token value.
ARCH_DATA_PAGE_ACCESSED corresponds to the AF flag. It is initially
unset and manually set to catch when pages are being accessed and
eventually do something about it.
ARCH_DATA_PAGE_DIRTY corresponds to the lack of the AP_RO flag.
Similarly to the AF flag, pages are initially made read-only to catch
writes.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Let's consider free entries as being completely zeroed. Future patches
for demand paging support will populate entries and still mark them as
"invalid" which should not be considered free. Current code always clear
entries to be freed so no issues there.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Common counter driver based on timer for MAX32xxx MCUs
To use as wakeup source wakeup-source parameter shall be
defined as below
&lptimer0 {
status = "okay";
clock-source = <ADI_MAX32_PRPH_CLK_SRC_ERTCO>;
wakeup-source;
counter {
status = "okay";
};
};
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Add timer instance in device tree
Add timer yaml file
Timer0/1/2/3 are common for MAX32xxx MCUs
MAX32655 has additional Timer4/5 which are low power timers
Co-authored-by: Mert Vatansever <mert.vatansever@analog.com>
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Add information to the device tree if UARTE instance has a HW feature
which is the ENDTX_STOPTX short.
Add this property to all instances in nrf54hl15, nrf54l20, nrf9280
and nrf54h20.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
There is a regression caused by #76177, which
causes build to fail due to missing includes and others.
This wraps it with proper checks and fixes wifi scan call.
This also remove unused variable present in the same driver.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
The unit tests needed to enable the hidden Kconfig
BT_BAP_BASE. Instead of adding an additional Kconfig for this,
just enable one of the roles that enable it.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add null termination of ssid and psk. If user pass ssid,
psk without null terminator it will add by default.
Signed-off-by: Kapil Bhatt <kapil.bhatt@nordicsemi.no>
There were a couple of controller tests outside the
controller directory which have been moved there to
simplify the structure a bit.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
When running cmake directly (without west, as twister does) on nix the
CMake environment paths are set and thus it does not find the
virtualenv'ed python. Fix this by ignoring the cmake environment
variables nix sets.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
Replace the busy boolean flag with an atomic value.
This prevents any race conditions with the MCC implementation.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Replace the busy boolean flag with an atomic value.
This prevents any race conditions with the GMAP client implementation.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
- add overlays and kconfigs files for nucleo_u083rc and
stm32u083c_dk boards.
- update testcase.yaml for CI
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
- enabled combined interrupt configuration for stm32u0x serie.
- since stm32u0 serie doesn't support SMBUS we need to avoid
use SMBHEN and SMBDEN bits register.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
we have four i2C peripherals .
- three shared between stm32u031/73/83
- One between stm32u073/83
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
check if two or three I2C instances with same irq are enabled
at same time then enable shared_interrupt handler.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Some function pointers were being passed via `%p` to LOG_DBG, and this
was causing the following issues in SOF CI with the `sparse` checker:
subsys/llext/llext.c: error: arithmetics on pointers to functions
subsys/llext/llext.c: error: incompatible types for operation (+)
This patch fixes the issue by casting the function pointers to void*.
Also fix a misleading error message in `llext_get_fn_table()`.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
With this commit, it is now allowed to register any ISR and arg
combination for the same IRQ, except the case when the exact same
ISR-arg combination is already registered.
The previous assert logic had a restriction where the same ISR could not
be registered multiple times with different arguments.
Signed-off-by: Martin Åberg <martin.aberg@gaisler.com>
Added option to set the ASE count through the bap API, making ASE
configuration runtime available. The upper limit of ASEs are still
bound by the Kconfig options set for ASEs.
Signed-off-by: Fredrik Danebjer <frdn@demant.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
If the dispatcher is muxing the connection i.e., so there are two
services for the same port, then mark service socket descriptor
of the service with the socket number so that "net sockets" shell
command can show a proper value for it.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
The socket services API has a limitation where the user data is shared
between file descriptors described in the same service.
This can cause problem in DNS dispatcher where each listened socket
needs to have their own dispatcher struct set as user data so that we
can map between dispatcher context and socket. Solve this by always
have a dispatcher table as user data, and then have the actual mapping
done via the dispatcher table when receiving data to the dispatcher socket.
Fixes#78146
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Dangling hyphens at the end of a line are usually a problem, ie. you
have an "hyphenated-word" and breaking it on two line will render it as
"hyphenated- word".
This commit fixes the few occurences of such dangling hyphens.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
There are numbers of drivers for different PCA(L) series chip. They
share similiar register layout and control logic. This driver intends
to unify these drivers for PCA(L)xxxx series i2c gpio expanders.
Signed-off-by: Chekhov Ma <chekhov.ma@nxp.com>
Implement an option manual reset of the PCAL64XXA to allow the external
implementation of a retention of the port expander state.
Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
Extract method which applies the initial state in the driver
for the port expander PCAL64XXA.
Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
There are 6 Cortex-A55 cores on i.MX95 EVK, this SMP variant will release
all the 6 cores to run Zephyr.
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
The IMX95LPD5EVK-19 board is a platform designed to show the most
commonly used features of the i.MX 95 automotive applications
processor. It is an entry-level development board, which helps
developers to get familiar with the processor before investing a
large amount of resources in more specific designs.
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
The i.MX95 applications processor features advanced graphics and
video cores, powerful vision and machine learning acceleration,
efficient CPU performance, real-time processing, and advanced
security with the integrated EdgeLock® secure enclave to support
energy-efficient edge computing.
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
On some i.MX SoCs, such as i.MX95, the System Manager is running on a
Cortex-M core to manage the hardware resources and provide services for
SCMI requests.
So add the SCMI-based pinctrl driver to support these i.MX SoCs.
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
The MU init should be very early for some platforms. For examples,
i.MX95 is using MU for ARM SCMI. It should be initialzied early
for next power, pinctrl, clock etc. management.
Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
Adds "chosen,uart-mcumgr" for nxp boards that support
the secondary bootloader partitioning.
Fixes the subsys\mgmt\mcumgr\smp_svr sample.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
GRTC needs to use direct clock source path instead of system clock path
to support ELV mode for nRF54L targets.
Signed-off-by: Adam Kondraciuk <adam.kondraciuk@nordicsemi.no>
Add `DT_INST_NUM_IRQS()` to get the number of interrupt lines
of the current `DT_DRV_COMPAT`
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
frmd_mcxc242 supports i2c, but it is not enabled.
Enable i2c and configure it to read accelerometer sensor on the board.
Update board documentation. Test it using sample.sensor.accel_polling.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
This PR updates all Espressif board names to meet its
original value. It also update reference links, re-organize
entries and removes unused content.
This also fixes bootloader information regarding a few boards.
IDF Bootloader was removed and these boards kept that info.
This updated it accordingly with the Simpleboot Bootloader.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
For some systems, the display peripheral or GPU requires that buffers be
aligned on a boundary for optimal performance. We already align display
buffers using CONFIG_LV_ATTRIBUTE_MEM_ALIGN_SIZE, but some applications
will rely on the definition of LV_ATTRIBUTE_MEM_ALIGN. Provide this
definition so those buffers will be aligned as well.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Add support the ccc deftgts. This also includes a function to check if
there is a secondary controller on the bus, and will transmit deftgts
after initialization or a hotjoin event.
This also adds dynamic_addr to the config_target in order to retrieve
the currently configured dynamic address to be used with deftgts.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Fixing the regression caused by 3949873886 ("Allow service to be
created with NULL host"). If the host parameter is null when creating
the HTTP service, the IPv6 socket is created by default. This can cause
issues if both IPv4 and IPv6 are enabled, like in HTTP server sample,
and the HTTP client connection is done by IPv4.
To fix this, we need to enable IPv4-to-IPv6 mapping in order to allow
IPv6 socket to serve a IPv4 connection. Allow also user to override this
if needed.
Fixes#78112
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
The code was checking IPv4 address instead of IPv6.
Print also IPv6 address when rejoining the group.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
This sets initial unpaged mappings for __ondemand_func code and
__ondemand_rodata variables. To achieve this, we have to augment the
backing store API.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
This provides __ondemand_func and __ondemand_rodata tags for annotating
functions and read-only data that should be loaded on demand so not to
exhaust all available RAM. The demand paging mechanism will be leveraged
to load so designated code/data as needed and to evict it from memory
when unused.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Get console baudrate property from device tree to allow
proper configuration for 26 and 40 Mhz devices.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Adds a new DTS prop for i3c devices as support for the CCC SETAASA
requires prior knowledge of the target if it supports it according
to i3c spec v1.1.1 section 5.19.3.23.
This will be used as an optimization for bus initialization.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
This particular qemu platform seems to run into a strange TLB exception
with unclear cause. Disable the test suite on xtensa qemu for the time
being.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
The custom linker script was required because SOF needed
some extra linker sections. Other than that, the custom linker
script was identical to the common architecture script. This
commit removes the custom linker script because:
* keeping the custom linker script in sync with the
common one is troublesome.
* application-specific linker sections shouldn't be
included in the generic soc linker script. Instead,
they should be handled at the application level
(i.e: via cmake commands if additional sections are
needed or via a new, custom linker script if more
changes are needed)
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
It appears some strangeness occurs around the consume semaphore today
that causes a TLB exception on qemu_xtensa_dc233. Unclear *why* just yet
but this fixes things in CI today.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
Moves the telnet client into runners/core.py as well, as this is now shared
between openocd and jlink.
Signed-off-by: Tobias Pisani <mail@topisani.dev>
This was non-trivial, as openocd is a bit weird to work with. Using only
commands passed with '-c' arguments, I couldn't get it to reliably resume
(or just not halt) the target when started. I tried using the 'sleep'
command, and various 'configure -event XX { resume }' events, but nothing
panned out, as it seems to always halt after all `-c` commands have been
run.
To avoid that, this waits for the TCL RPC port to be up, and sends a
resume command there. This works reliably.
Signed-off-by: Tobias Pisani <mail@topisani.dev>
This command runs separately from a debug server, instead of attaching
to a running server. This is both the easiest out of the box experience,
and also should be possible to implement consistently for most runners.
This commit includes an initial implementation for pyocd.
Signed-off-by: Tobias Pisani <mail@topisani.dev>
This allows to run the test 'chan_blen_transfer' and 'loop_transfer' on
the sim3u1xx_dk board.
The functionality tested in `chan_link_transfer` and `scatter_gather` is
not (yet) supported by the Si32 DMA driver, and those tests therefore
not enabled.
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This allows the users to know about the supported features and to run
(some of) the tests/drivers/dma tests on this board.
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This supports the minimum of what is required to allow the AES hardware
to be used (memory to peripheral, peripheral to memory).
In addition, to pass some of the existing unit tests, it also supports
memory to memory operators.
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Move the transfer process codes to work context becuase
it lock the mutex, move bus reset process codes too
because it calls some common udc apis (they may add
mutex lock in future).
Signed-off-by: Mark Wang <yichang.wang@nxp.com>
This was seen in CI
START - test_cycle_ready_CC
Assertion failed at ...tests/net/conn_mgr_monitor/src/main.c:262:
cycle_ready_ifaces: (stats.conn_count_gen not equal to 1)
NET_EVENT_L4_CONNECTED should be fired when connectivity is gained.
FAIL - test_cycle_ready_CC in 0.015 seconds
As the event wait timeout is very short (1ms) by default, increase
it to 10ms so that we will not miss the event.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Add condition for KConfig Renesas FSP hal module
Move the DUAL_BANK_MODE from SOC to flash driver KCONFIG
Signed-off-by: Duy Nguyen <duy.nguyen.xa@renesas.com>
Features enabled by this commit:
* RNG
* Ethernet port (shell sample works without changes)
Also fixed flash addresses in docs and added the default
mapping between inputs and GPIO pins.
Signed-off-by: Federico Di Gregorio <fog@dndg.it>
Fix flexspi xip configuration issue regarding code relocation
due to the order of kconfig defaults being sourced
The flexspi setup was not being relocated to an on chip location
Also remove rt1060 conf file in flash common test which changes the
code relocation location to RAM, just keep as ITCM for all M7 which
as of now all have ITCM from NXP with flexspi.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Set a default value for constant-charge-voltage-max-microvolt, matching
the device hardware default, this ensure compatibility with existing
applications that did not specify the recently introduced property.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Add and verify against reference descriptors a High-Speed only 192 kHz
24-bit stereo headphones with explicit feedback UAC2 instance.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Generate and test both Full-Speed and High-Speed descriptors against
reference values. Verify that IAD, interface and endpoint descriptors
are not shared between Full-Speed and High-Speed descriptor sets because
the number of non-UAC2 interfaces can be different at different speeds
and thus the assigned interface numbers and endpoint numbers can differ.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Generate full and high speed descriptors based on UAC2 instance
properties. Fail the build if an instance does not have speed properties
or if the instance with given speed property exceeds the bandwidth
available at the selected speed.
Remove obsolete no longer used macros to determine offsets inside
complete UAC2 descriptors blob. Only speed-specific descriptors arrays
are supported.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add full-speed property to build all configuration and to UAC2
descriptor tests because this is what the tests were written for
(UAC2 class originally was full-speed only and there were no speed
properties available).
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
The samples were written when UAC2 class supported only full-speed and
it was not clear how the high-speed would be supported.
Add the full-speed property so the samples can work with updated UAC2
implementation.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add a test to check the proper support of ELF init arrays, using
the new llext_bootstrap function in place of llext_entry in the
LLEXT test suite.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
This commit renames the perm_setup callback to test_setup and provides
the extension as an additional parameter. It also adds a test_cleanup
callback that is called after each test completes.
Setup and cleanup functions are now called regardless of whether
CONFIG_USERSPACE is enabled or not.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
This patch refactors the macro for test case definition to simplify the
generic case. By using variable macro arguments and default-0 fields,
the most common case does not require arguments at all and tests that
have special requirements can be defined with only the necessary fields.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Add support for flashing the Adafruit Feather nrf52840 Express
using UF2 over USB.
Also standardise on using the UF2 variant, so add a non UF2 variant
of the Sense board, so it can be flashed using the SWD headers.
Created flash dtsi files for both SWD and UF2. These are actually identical
for many other boards and should probably be moved to common in future.
Signed-off-by: Jacob Winther <jacob@9.nz>
Update both versions of adafruit feather nrf52840 to be variants rather
than separate boards. The aim is to provide a more consistent approach
and to remove some unnecessary Kconfig redundancy.
Signed-off-by: Jacob Winther <jacob@9.nz>
Remove unnecessary Kconfig options.
Simplify configuration by removing custom Kconfig option.
Make Kconfig generic for all boards by moving usb selection to
board_defconfig.
These changes should enable the boards to become variants instead.
Signed-off-by: Jacob Winther <jacob@9.nz>
Define DMA channels for MAX32 boards and add a new test case so that
DMA-based SPI transfers are tested.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Update hal_adi to include the fix for build errors encountered when
building SPI loopback test with DMA enabled on MAX32662.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Taking a cue from `nrfx/templates`, introduce this file so that it can
be overridden out-of-tree to add external nRF product definitions.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Only read the compensation parameters from the chip on first power up,
as they are static on the device.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Support the BME680 being on a power domain, which may not be powered at
boot. For example, Nordic Thingy53.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Due to the introduction of `shell_xxx_impl` wrapper functions in
PR #75340 and rename to `shell_fprintf_xxx` in PR #77192 we can minimize
caller overhead by eliminating direct `color` parameter passing.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Implement shell commands to access the symbol table.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Blanking On/Off calls should not return 0 when there is no panel
controller to forward them to, instead they should return ENOSYS to
signal to the application that they were not actually executed.
"device_is_ready" does check for null, but also for
"dev->state->initialized == false", so we need to isolate the
"dev == NULL" case.
Signed-off-by: Abderrahmane Jarmouni <git@jarmouni.me>
The callee-saved-registers can be helpful to debug the state of
a core upon an exception, however, currently there's no way to
access that information in user-implemented
`k_sys_fatal_error_handler()`, even though the csf is already stored
in the stack.
This patch conditionally add a `csf` member in the `arch_esf` when
`CONFIG_EXTRA_EXCEPTION_INFO=y`*, which the `_isr_wrapper` would update
when a fatal error occurs before invoking `z_riscv_fatal_error_csf()`.
Functions such as `k_sys_fatal_error_handler()` would then be able
to access the callee-saved-registers at the time of exception via
`esf->csf`.
* For SoCs that select `RISCV_SOC_HAS_ISR_STACKING`, the
`SOC_ISR_STACKING_ESF_DECLARE` has to include the `csf` member,
otherwise the build would fail.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Without the IPv6-prefix set, the net_if_ipv6_addr_onlink() check
will always fail. The packets with DIP in the local link will go
to 'try_send' code branch, which is not expected.
Signed-off-by: Shrek Wang <shrek.wang@nxp.com>
LwM2M 1.1 specification mentions that the enabler version format was
specified wrongly in LwM2M 1.0 specification, and servers only "may"
accept the old format, which no longer seems to be the case for Leshan.
The URI reference ("</>;") before the enabler version is now mandatory,
if it's missing the bootstrap discovery fails with Leshan. Another
problem are quotes around the enabler version, which seems to be
conditionally accepted only for LwM2M version 1.0. Therefore, keep the
quotes only for that version, to prevent any potential issues with other
servers.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
The second Security object instance for bootstrap case isn't really
needed, as the bootstrap server creates own Security object instances
anyway. As that object instance had no Short Server ID assigned, it
caused failures during bootstrap discovery.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Update the HW models module to:
d2a119a9c7600ce06033a794de042e0ad9a38702
Including the following:
d2a119a 54 ECB/CCM tests: Add BLE spec examples and more printouts
17692a6 54 CCM: Correct variable names
16629b5 RRAMC: Add backwards compatible command line aliases for flash_*
52cbc36 54 AAR, CCM, ECB: Fix reset values and ECB key endianess
d51acf4 RADIO: Implement TASK_SOFTRESET
8285509 54 ECB: Correct t_ECB
4f70fba 54: AAR/CCM: Route tasks to the appropriate module
895eabb RADIO: Warn only once about TASK_SOFTRESET not being implemented
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Add general purpose partition tables to prevent
putting copied version of the same table into the
every ESP32 board dts.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
`conn_auto_initiate()` starts a bunch of controller procedures (read: HCI
commands) that are fired off right after connection establishment.
Right now, it's called from the RX context, which is the same context where
resources (cmd & acl buffers) are freed. This not ideal.
But the procedures are all async, so it should be fine to schedule this
function on the system workqueue, where we have less risk of deadlocks.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
On 32-bit x86, it was supposed to print the first argument to
the function during stack trace. However, it only works when
code optimizations are totally disabled (i.e. -O0). As such,
printing the args is not meaningful to aid with debugging.
So change it to simply print the function address, the same
as x86 64-bit.
Also, since unwind_stack() has exactly one caller, make it
ALWAYS_INLINE to skip a function call.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The number of modules is different for each soc.
There is a macro in the HAL that should have been used.
Signed-off-by: Richard Wheatley <richard.wheatley@ambiq.com>
Add all the necessary files to add apds9253 Avago sensor driver.
Sensor available at https://docs.broadcom.com/doc/APDS-9253-001-DS
Signed-off-by: Margherita Milani <margherita.milani@amarulasolutions.com>
Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Some events needs to be handled with a very low latency constraint.
If the system is in deep sleep, exit latency from this low level state
exceeds sometimes the maximum latency constraint of these events.
Before suspending the system, select which events is happening sooner,
kernel events or normal events.
CPU will be up just before the next event occurs taking into account the
exit latency of the current power state
Change also the policy event API to take as argument absolute time in HW
cycles instead of time in us
Signed-off-by: Riadh Ghaddab <rghaddab@baylibre.com>
Remove all entries that as not being used.
This also update hal to re-enable warning flags
as such as -Wno-unused-variable.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Since the `_impl` naming convention is intended for internal use only,
renaming these functions to the `shell_fprintf_xxx` variant is
more suitable for calls outside the module:
- `shell_info_impl` to `shell_fprintf_info`
- `shell_print_impl` to `shell_fprintf_normal`
- `shell_warn_impl` to `shell_fprintf_warn`
- `shell_error_impl` to `shell_fprintf_error`
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Currently if initializing one of the registers fails, the return
error gets overwritten by can_set_timing(). Fix by forwarding the
error directly. Also remove unnecessary done label.
Fixes#73586.
Original patch by melvinvdb from #73714.
Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com>
Mcp251xfd devices occasionally fail to initialize after board
resets. It was experimentally found that adding a 5ms delay fixes
the problem.
Fixes#73586.
Original patch by melvinvdb from #73714.
Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com>
Check the remaining buffer length is not less than
required data length before pulling data from the
buffer.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
This reverts commit a2bb323861.
nRF9280 does not suffer from the same bit 28 hardware bug as nRF54H20.
This workaround must be disabled to make the DCACHE function properly.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
VPR addresses are platform-dependent, so let's use a common symbol -
CONFIG_NRF_PLATFORM_HALTIUM - to cover both nRF54H and nRF92 series.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
PMIC service should be supported on Application and Radiocore, whereas
DVFS service is currently unsupported.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Booting VPRs requires changing the default value of CONFIG_RV_BOOT_HART.
This must be reverted (back to zero) for a future nRF9230 SoC revision,
which will align more closely with the RISC-V spec.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Add overlays for booting PPR on the `nrf9280pdk/nrf9280/cpuapp` target.
They are identical to the nRF54H ones because of similar DT structure.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Make actual document take all vertical space available so that footer is
always at the bottom, even when the page has very little content.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
There is likely no need for the footer to be so prominently asking folks
to report issues with a page based on the number of issues that have
been reported in the past year or so.
This change makes the footer less crowded and saves some vertical space.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Production version of the nRF54L15 SoC needs reset reason
to be cleared before going into system off.
Signed-off-by: Karol Lasończyk <karol.lasonczyk@nordicsemi.no>
Assembly in power_down() in power_down.S already defines data and
code to be locked in cache when powering down SRAM. Instead of adding
another such location in power.c, move the hpsram_mask[] array into
power_down.S. This fixes hard to debug failures when shutting down
the ADSP.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Add a check so that we hopefuly keep all zephyr-app-commands free of
references to non-existing paths.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
As there is no check (yet!) in the directive, many
.. zephyr-app-commands:: in the documentation are pointing to
non-existing sample applications, which is problematic for users who
typically expect to just copy-paste the commands and have them work.
This commit fixes all offending references to point to existing samples,
or converts them to simple ":app:" instead of ":zephyr-app:" when the
intent wasn't to refer to in-tree samples.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
STM32CubeProgrammer is now selected as the default runner for all STM32
official boards when 'west flash' is invoked.
Signed-off-by: Abderrahmane Jarmouni <git@jarmouni.me>
Update all STM32 official boards Doc Flashing section.
Correct some typos and remove outdated information.
Signed-off-by: Abderrahmane Jarmouni <git@jarmouni.me>
Add STM32CubeProgrammer where it is not available, & make it
default flashing method by placing it 1st in board.cmake
Before this change, the west runner that's selected when calling
'westflash' without the '--runner ...' option is kind of arbitrary
& depends on which runner is 1st in board.cmake file.
Another reason this change is needed is that STM32CubeProg is the only
available way to check/modify Option Bytes, and to flash code to
external Flash on many STM32 boards.
This change does not affect 'west debug' behavior, which defaults to
the debugger (OpenOCD/JLink) that is included first in board.cmake
Signed-off-by: Abderrahmane Jarmouni <git@jarmouni.me>
Wait until the erase operation triggered by `qspi_erase` completes
before returning. This aligns with the behaviour of other flash drivers
like `spi_nor` and `soc_flash_nrf`.
A delay is added to the `qspi_wait_while_writing` to prevent the check
from monopolising the CPU.
Signed-off-by: Jordan Yates <jordan@embeint.com>
cdc_acm_fifo_fill() logged warnings about dropped data
when they in fact just couldn't be sent (due to connection
of filled buffer). Not being able to send (all) data is
a valid behaviour and data isn't dropped. Return value
shows how many data was accepted (which can be zero).
Logging will now instead only inform data can't be sent
due to the respective issue (connection not ready/ buffer full).
Signed-off-by: Martin Koehler <koehler@metratec.com>
Multiple improvements of the `upload_test_results_es.py` script:
* JSON objects flattening.
This feature allows `twister.json` file preprocessing to simplify
its Elasticsearch index structure for complex hierarhical objects,
for example with memory footprint, or code coverage data.
A new command line option `--flatten` is added to change testsuite data
structure in regard of one of its list objects: either `testcases` or
`recording`, so each item there becomes an independent data record
inheriting all other testsuite properties, whereas the children
object's properties are renamed with the parent object's name
as a prefix: 'testcases_' or 'recording_' respectively.
Only one testsuite property can be flattened this way per index upload.
Other children objects will be treated accorging to the index structure.
Related new command line options (with help text explanations):
`--flatten-dict-name`,
`--flatten-list-names`,
`--flatten-separator`,
`--transpose-separator`,
`--escape-separator`
* A new command line option `--transform` is added to allow regexp group
parsing in string propertites extracting additional derived properties.
* A new command line option `--exclude` is added to exclude testsuite
properties not needed to store at Elasticsearch index.
* Branch name `--run-branch` and Workflow ID `--run-workflow` command
line options as additional key fields to allow data from different
branches, workflows and triggering events in the same index.
* A new command line option `--map-file` is added to apply
an explicit index structure to the `twister.json` input data.
* Add bulk operation timeout parameter for heavy/long uploads.
Other changes:
* batch upload error handling and logging;
* inline documentation improvements;
* some corner case fixes on empty objects.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Add support for running the audio BSIM tests on the
nrf5340bsim board.
This expands the tests we run in CI.
To support all tests with the hci_ipc sample for the netcore,
it is updated to support a bit more while still fitting on the
netcore on the nRF5340 series.
The behavior of advertisement seems to differ a little bit,
which required the bap_unicast_server_test.c to update how it
restarts advertisements.
Two broadcast tests that are passing on the nRF52 BSIM is also
failing due an assert. This should be investigated at a later
time.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Get rid of the switch statement and use an string array
for the cause instead. This saves about ~600 bytes.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Rename `cause_str` to `z_riscv_mcause_str` and make it non-static,
so that it can be used in user-implemented `k_sys_fatal_error_handler`.
Also, this function should return a constant string, so add `const`
to it.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Relocate the logging of mcause & mtval from `_Fault` to
`z_riscv_fatal_error_csf` so that they are always printed
upon exception.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Add a definition for HCI version 6.0, now that the new core specification
version has been released.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
There's a generally available bt_hci_get_ver_str() function, so use that
instead of defining our own.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
Use generic hook infrastrucutre instead of custom Kconfig and hooks for
ARC.
Replace soc_early_asm_init_percpu() with platform_reset()
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Use generic hook infrastrucutre instead of custom Kconfig and hooks for
ARM.
Replace z_arm_platform_init() with platform_reset().
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Introduce soc and board hooks to replace arch specific code
and replace usages of SYS_INIT for platform initialization.
include/zephyr/platform/hooks.h introduces the hooks to be implemented
by boards and SoCs.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Mention that the GNSS periodic config APIs have been removed in the
release notes for 4.0
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
The GNSS device driver API includes an API for setting the periodic
power configuration at runtime. This API is not used in-tree, and is
antithetical to the pm device subsystem.
The periodic config configures the GNSS to search for a fix for a
given amount of time, then suspend itself for a given amount of time,
and repeat this pattern. The issue with this is that both the
application and the GNSS modem itself can be in a conflicting power
state, where the device is resumed (pm device), but actually suspended.
Applications which wish to periodically resume/suspend the modem, even
in more sophisticated ways like suspended after first fix, can simply
implement this logic, using the pm_device calls and the GNSS callbacks.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Status errors previously logged an error, but didn't fail the running test.
This commit changes that
and introduces a new StatusAttributeError to use there.
One test is modified so it follows proper status form.
One test for the new error has been added.
Status errors now will properly mark the Instance as ERROR
and not run TestCases as SKIP.
This necessitated some code layout changes in runner.py
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
Change ensures that `dwc2_handle_xfer_next` would notify upper layer if
`dwc2_tx_fifo_write` fails. This is necessary to ensure that upper layer
is aware of the failed TX for the submitted transfer. It also ensures
that the submitted transfer is removed from the TX queue.
Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
As the allocation is run in system workqueue context, it can
cause problems if waiting forever when allocating net_pkt.
Fixes#77935
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
As the allocation is run in system workqueue context, it can
cause problems if waiting forever when allocating net_pkt.
Fixes#77935
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
It is hard to justify keeping the version admonition/disclaimer eating
up so much real estate on all documentation pages. It was useful when
search engines tended to index old versions of the documentation and
reminding people where they "landed" was a good idea.
Now, it is just taking up space and we can safely assume that people
explicitly interested in older releases will find their way to the right
place, as our version selector is in a very similar spot to how other
projects do it.
Note that the admonition will still be included on "released" versions
of the docs, since the "there might be a more current version of this
page" admonition is actually useful to have.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Move the network buffer tests to tests/lib/net_buf as their implementation
now lives outside of the networking subsystem.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Move the network buffer documentation from networking to services as the
implementation now lives outside of the networking subsystem.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Move the network buffer header file from zephyr/net/buf.h to
zephyr/net_buf.h as the implementation now lives outside of the networking
subsystem.
Add (deprecated) zephyr/net/buf.h header to maintain compatibility with old
file path.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Move the net_buf implementation from the networking subsystem to a library
as they have no dependency on the networking subsystem.
Network buffers are used in subsystems outside of networking
(e.g. Bluetooth, USB).
Fixes: #36374
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
- Add overlay for the FRDM MCXN947 qspi variant
- Fix the overlay file name for the default variant
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
1. Enable CACHE64 block used by FlexSPI.
2. LPCAC cache is already enabled by SystemInit which
is called earlier
3. Configure the FlexSPI clock when running in XIP mode
as we cannot rely on the driver setting this up as it
may not be enabled.
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
1. The boards always boots from internal flash. However it does
have an external QSPI that can be used to store Zephyr.
Add a variant to support running Zephyr from QSPI Flash.
Running Zephyr from QSPI requires a bootloader like MCUboot
to be pogrammed to internal flash.
2. Create a common dts file to add features that are enabled for
CPU 0 that is included by both vairants i.e internal flash (default)
and QSPI variant.
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
Include compile of the flash file when FlexSPI_XIP is enabled
even when the FlexSPI driver is not enabled.
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
When virtual interface is being started or stopped so when the
interface is brought up or down, check the return code and pass
it to net_if_up() or net_if_down() calls.
This helps to avoid printing success status even if the interface
up/down failed at the virtual interface level.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
The legacy bridging code prevented normal IP traffic to the
bridged Ethernet interfaces. This is not intuitive and differs
how bridging setup works in Linux. This commit changes that and
creates a separate virtual interface that is doing the actual
bridging. This enables the bridged Ethernet interfaces to work
normally and provide IP connectivity.
How this works in practice:
* User needs to enable CONFIG_NET_ETHERNET_BRIDGE
* User needs to have a device with more than one Ethernet
interface
* After booting, the net-shell or program API can be used
to add interfaces to the bridge like this.
net bridge addif 1 3 2
where the 1 is the bridge interface index and
2 and 3 are the Ethernet interface indices.
* The bridging is then finally enabled / started when the
bridge interface 1 is taken up
net iface up 1
* If bridged interfaces are removed from the bridge (minimum
of two interfaces are needed there), then the bridging is
disabled automatically. The bridge interface stays up in
this case and can be taken down manually.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
This reverts commit 518de763a6.
This commit switched nrf5340 devices to use the icbmsg
IPC backend.
Unfortunately this backend is not currently supported
in the nrf5340bsim target (it is not properly configured)
which results in a segfault during its initialization.
As this issue is currently blocking CI for all BT development
in Zephyr, let's revert this provisionally while we add
support for it.
See
https://github.com/zephyrproject-rtos/zephyr/issues/78099
for more info.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
The bits allocated for each aggregator level only need to be enough to
encode CONFIG_MAX_IRQ_PER_AGGREGATOR, instead of the combined number of
IRQs from all aggregators in that level.
Add additional check for L3 interrupts as well, if it is enabled.
Updated the assert in `z_get_sw_isr_table_idx()` to be more verbose.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
- Update `MAX_IRQ_PER_AGGREGATOR` to 1024 to match with the
devicetree
- Update `2ND_LEVEL_INTERRUPT_BITS` to 11 bits to
be able to encode the L2 IRQs.
- Update `NUM_IRQS` to 1036 (L1 has 12, L2 has 1024)
Update the `MAX_IRQ_PER_AGGREGATOR` config in testcase
accordingly, so that it won't overflow the configured bits.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Removes constant error logging when parsing IPD headers in active mode and
waiting on remote IP and port. Currently an error message is logged for
every character in the remote IP and port until the full length obtained.
Signed-off-by: Daniel Mangum <georgedanielmangum@gmail.com>
Add the driver of diplay controller ist3931, i2c/spi
128x64 monocolor display driver. Only the i2c mode
driver of the controller is implemented and tested.
Signed-off-by: Shen Xuyang <shenxuyang@shlinyuantech.com>
Minor updates the atomic_test* functions to indicate
that only the get/clear/set part of the functions are
atomic, and not the test part. Also made the wording
and pattern of the functions more similar.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add section which describes how Coresight STM logging works and how
to use it. Currently this feature is supported only on nrf54h20.
However, most parts of the solution is not nrf54h20 specific and
other cores with Coresight can use it.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add standalone STM configuration to the sample.
Add configuration which instead of STM uses local UART for logging.
This configuration can be used to compare performance and flash
usage for various logging modes.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add snippet which allows configuration of logging using STMESP
frontend using standalone mode.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add support for standalone mode where data written to STMESP is
decoded on chip to a human-readable strings.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Extend ETR buffer handler to support standalone mode where data from
ETR buffer is decoded and printed in human readable format on UART.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add test for message demultiplexer from STPv2 data stream generated
by STMESP frontend.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add module which demultiplexes stream of log message which are
encoded into STPv2 stream by log_frontend_stmesp. There are 3 types of
messages that can be present in the stream:
- Log message (starts with DMTS32, followed by Dx and closed by FLAG)
- Tracepoint (FLAGTS or DMTS32)
- STM HW event (DMTS8 on 0x80 master and 0x00 channel)
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add sample that demonstrates logging using Coresight STM and ETR buffer
handled by the application core. Application is using sysbuild and 2
cores: cpuapp and cpurad. cpuapp is logging to STM and handling ETR buffer
where data from STM is collected and cpurad is only logging to STM.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add module which is dumping data from Coresight ETR buffer. Coresight
ETR is a sink for STMESP data. This module is specific to Nordic SoC
because it does not access ETR registers. Instead it is using Nordic
specific module (Trace Buffer Monitor TBM) to monitor amount of data
in the ETR buffer (which is a circular buffer).
Data from that buffer is sent over UART (in future it may be extended
to other transports). In future, module will be extended with option
to process STM data on chip.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add new binding and a node to nrf54h20. Update Kconfig and nrfx_config
to include nrfx_tbm driver when node with that compatible is enabled.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
In order to get all data from STMESP written to ETR and processed
on time we need to write dummy data before sleep.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add header with STMESP register set and set of inline functions
that can be used to write data to STMESP.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
As there are more frontends coming in the future move existing
frontend to the dedicated directory (like backends).
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Change to depend on LOG_DICTIONARY_DB which is broader than
LOG_DICTIONARY_SUPPORT which is set only when log_output
supports dictionary mode. However, it is possible that
log_output is not used when dictionary mode is used. Database
generation is always enabled when dictionary mode is used.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add test which validates behavior of the UART driver when there
are errors on the receiver line.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
When rx_flush() was called with NULL buffer it was an indication to
drop data from the FIFO. However, it is still important to get the
correct amount of dropped data because when PPI+TIMER are used to
count bytes those flushed bytes are also counted (because each
byte generates RXDRDY event). If those bytes are not counted then
total amount of reported bytes is not correctly aligned with bytes
counted by TIMER.
Reworking rx_flush() to correctly count number of dropped bytes and
then add this flushed bytes to the total amount of RX bytes
reported to the user in RXTO event handler.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
When interrupt driven instance is using only TX then low power mode
is automatically enabled and then TXSTOPPED interrupt is disabled in
idle so uarte_nrfx_irq_tx_ready_complete() was returning wrong value.
Adding a dedicate flag which holds information is user enabled TX
interrupt.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Callback was set in uart_async_to_irq_rx_enable() which is only called
when RX is enabled. Callback shall be called in the init function.
uart_async_to_irq_init() signature changed to take device as the
input argument instead of data and config for the adaptation layer
(which can be retrieved from the device). Device is needed when
setting a callback during the initialization.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Adaptation layer was not correctly handling RX error and when error
occured uart_irq_is_pending() was still returning false.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
According to the API specification when RX error occurs receiver
shall be disabled. Adding missing disabling to the error handler.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
The current driver contains assembly code which is specific for the nRF51
SOC which makes it incompatible with other SOC's. This patch adds support
for other nRF SOC's as well. The timing is calucated based on the CPU clock
frequency, but can be configured manually as well if needed.
Changes have been verified on a Adafruit Feather nRF52840 Express board,
which contains a single NeoPixel RGB LED. Timings have been verified using
a scope connected to the WS1812 data line.
Signed-off-by: Chaim Zax <chaim.zax@zaxx.pro>
Currently function `z_nrf_grtc_wakeup_prepare()` should be available
only for the GRTC manager (`CONFIG_NRF_GRTC_START_SYSCOUNTER` is active).
Signed-off-by: Adam Kondraciuk <adam.kondraciuk@nordicsemi.no>
Add functions for local domain suspend to RAM. Add matching resume
procedure. Add pm_s2ram function for determining source of reset.
Add preserving NVIC and MPU state in retained RAM when CPU is powered off
during S2RAM procedure.
Signed-off-by: Adam Kondraciuk <adam.kondraciuk@nordicsemi.no>
If the dynamic address is not the same as the static address during
setdasa, perform the reattachment.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
All I3C v1.1+ devices are required to support GETCAPS. Remove BCR
check as it was the requirement for v1.0.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
The ESP32 Wi-Fi driver previously did not support APSTA mode,
enabling AP mode would disable STA mode and vice versa.
Support for APSTA has been added by introducing additional
network interface: one for STA (Interface 2) and one for
AP (Interface 1). The CONFIG_ESP32_WIFI_AP_STA_MODE option in
Kconfig now allows enabling or disabling this support.
Signed-off-by: Muhammad Haziq <muhammad.haziq@zintechnologies.com>
Allow application to register certain HTTP request headers to be stored
by the server. These stored headers can then be accessed from a dynamic
resource callback.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
The `build_args` argument was not respected when generating west
commands. This led to an error in the documentation of qemu network
setup.
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
Add documentation for the new LLEXT APIs that allow to call the
initialization and cleanup functions of an extension.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
llext_bringup() and llext_teardown() are intended to be used to call the
extension's own initialization and cleanup functions, respectively. They
are meant to be called by the developer after loading an extension and
before unloading it. The list of function pointers to be called is
obtained via the new llext_get_fn_table() syscall, so that they are
compatible with user mode.
llext_bootstrap() is intended to be used as the entry point for a thread
created to run an extension, in either user or kernel contexts. It will
call the extension's own initialization functions and then an additional
entry point in the same context (if desired). The same function can also
be called directly in the main thread, if only initialization is
required.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Load the .preinit_array, .init_array and .fini_array sections in ELF
files. These sections are arrays of function pointers that are filled by
the compiler with the addresses of functions that need to be called at
startup or termination by the loader, such as C++ constructors and
destructors.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
QSPI sleep now set QSPI CS pin to pull-up, decreasing
current consumption.
Co-authored-by: Vidar Berg <vidar.berg@nordicsemi.no>
Signed-off-by: Sigurd Hellesvik <sigurd.hellesvik@nordicsemi.no>
This commit removes the `hifive1` board from the `platform_exclude` list
for the `drivers.gpio.1pin` pin.
The root cause for why this platform was disabled was fixed in the recent
Renode version upgrade in the CI image.
Fixes#69350.
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Add support for use of FAKE_ENTROPY_NATIVE_POSIX as entropy
driver for the Controller on BOARD_NRF54L15BSIM.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Extend tests with case where extension is copied from RAM buffer
into filesystem and then loaded from filesystem.
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
This patch extends LLEXT shell commands with support for loading
LLEXT from a filesystem. Use of the command requires absolute path
to the llext file.
Example use:
`llext load_llext hello_world /lfs/hello_world.llext`
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
Introducing `llext_prepare()` and `llext_finalize()` APIs
that are invoked and the beginning and the end of the `llext_load()`
function.
The purpose of these functions is to bring possibility of initializing
loader before it is used and uninitialize or clean up when
it is no longer needed. Both functions are optional.
The buffer loader has been aligned to methods introduced in the patch.
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
By default, normal memory is set readable+writable and not executable.
Adjust those permissions according to each region:
LLEXT_MEM_TEXT --> K_MEM_PERM_EXEC
LLEXT_MEM_DATA, LLEXT_MEM_BSS --> K_MEM_PERM_RW
LLEXT_MEM_RODATA --> K_MEM_PERM_RO aka 0
This must be done only at the end of an LLEXT load operation as memory
needs to remain RW for reloc processing, etc.
And while at it, flush/invalidate the cache accordingly.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
It is sometimes necessary to modify/update memory permissions on some
pages, especially with LLEXT where some allocated segments have to be
executable.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
`CLOCK_CONTROL` subsystem being selected directly at family level,
remove it from individual board configurations.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
Rather setting the driver default in soc, make it directly at symbol
level rather than soc and clean up redundant `select` occurrences.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
CLOCK_CONTROL subsystem is expected to be enabled systematically on all
STM32 devices.
Make it a series default.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
GT911 driver was reading an additional touch point into the stack
defined touch point array, causing an out-of-bounds write on the stack.
Fix this issue by adjusting the limit on the for loop, and add a note
to the driver as to why we don't need to validate the number of points
reported for future developers
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
The default Max A-MPDU length is 8191 shown in the VHT Cap Info from
SAP's beacon/Assoc response, and this length is read from
hapd->iface->conf->vht_capab. It will lead to the AMPDU only contains
5 packets and the throughput is only 60Mbps for 1x1 HE case in 5GHz.
Change the default vht_capab to VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_MAX
(1048575), and the throughput can be increased to 83Mbps.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
Use the correct define for checking if the DCDC converter shall be
enabled.
This resolves the opposite behavior where boards that enable the DCDC
converter uses the LDO and boards where LDO is used they enable the
DCDC.
Fixes: e189fb0720 ("soc: nordic: nrf52: add support for DT-based
regulators config")
Signed-off-by: Sean Nyekjaer <sean@geanix.com>
Changed NET_CONFIG_CLOCK_SNTP_INIT depends on to require
POSIX_TIMERS instead of the deprecated POSIX_CLOCK
Signed-off-by: Luca Arato <luca.arato@secomind.com>
A connected state was reported as a disconnected state.
This led to wrong reports of the connected state to all systems
relying on it.
Signed-off-by: Lukas Gehreke <lk.gehreke@gmail.com>
Clarify the HTTP service definition so that the host parameter can
be set as NULL in which case the server will listen all addresses.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Without this it is not possible to serve both IPv6 and IPv4
connections if service host is NULL.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Allow NULL host parameter when creating HTTP service. This means
that the socket is created without specifying binding address.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Make lists of code samples more compact (a lot of vertical real estate was
being wasted) and more visually appealing.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The zephyr-app-commands directive can output a helpful hint to the user
when they are trying to build a sample that is in the Zephyr tree,
telling them to ensure they are in the root folder of the Zephyr repo.
Update all doc pages that were using :app: instead of :zephyr-app: so
that the hint is displayed.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds missing code-sample directive to the remaining samples in
`samples/subsys` that didn't use it yet in preparation for upcoming
changes to the Zephyr documentation that will be leveraging the provided
description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
This link probably never worked. This commit fixes the relative
URL to properly point to where Doxygen docs live.
Fixes#78016.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Enabled Network shell and Ethernet L2 interface
with XGMAC driver in CLI application
Enabled MDIO shelll with dwcxgmac mdio driver.
Enabled TCP and UDP over IPV4.
Added intel_socfpga socdk support for echo_client and
echo_server sample applications.
Signed-off-by: Santosh Male <santosh.male@intel.com>
Added XGMAC0, XGMAC1, XGMAC2 device nodes in
intel_socfpga_agilex5 dts file with default
parameter values and default device node status
as 'disabled'.
Signed-off-by: Santosh Male <santosh.male@intel.com>
ethernet driver
This driver is capable of supporting basic features
of synposys dwc-xgmac ethernet MAC IP. Basic features
includes,
1. Tx and Rx, multiple Tx and Rx DMA channels, multiple
Tx and Rx queues
2. Check Sum Offloading on Tx and Rx for IPv4, IPv6,
TCP, UDP and ICMP packets
3. 10M/100M/1G speeds, Autonegotiation, Link speed
configuration, Promiscuous mode, Full/Half
duplex configuration
4. Added source files for synopsys dwc xgmac mdio driver.
synopsys dwc xgmac mdio driver fetures includes:
It supports clause 22 of IEEE 802.3 for ethernet PHY devices
management.
5. Extended mdio shell support for dwcxgmac mdio driver.
Signed-off-by: Santosh Male <santosh.male@intel.com>
Use fallbacks in codec cfg functions in the BAP broadcast
babblesim tests to avoid unnecessary noise in the logs of
the tests.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add to_str functions for context, parental rating, active state,
codec cap freq, codec cap frame duration,
codec cap channel count and location.
The remaining values are just numeric values and does not
need a to_str function.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Fix `k_poll()` loop example by using separate `if` blocks instead of
`if`-`else`-chain to ensure all events are handled, even if multiple are
active at the same time.
Signed-off-by: Cla Mattia Galliard <cla-mattia.galliard@zuehlke.com>
LPUART without modem support is used in some NXP socs. Build error
occurs for such socs because of accessing unavailable register.
Fix it by adding #if directive for checking modem support availability.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Add OSCERCLK, MCGIRCLK, and MCGPCLK clock sources definitions
to the kinetis_sim.h in include dt-bindings.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Devicetree binding for NXP mcxc oscillator is not available.
Add the binding to be able to configure the oscillator in devicetree.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Add configuration settings for the FOPT, FSEC, and flash configuration
offset to the FTFA module binding.
Signed-off-by: Michal Smola <michal.smola@nxp.com>
Charging a battery has three phases (compare Figure 8-2 in
https://www.ti.com/lit/ds/symlink/bq25180.pdf)
First is a pre-charge phase, then a constant current, then a constant
voltage phase.
During the pre-charge phase, the battery is only charged with a very low
current, to not damage the cells, because they are below a threshold,
that is considered healthy for the battery and need to be brought back
up to a healthy voltage.
Signed-off-by: Fabian Pflug <fabian.pflug@grandcentrix.net>
The battery charger will stop charging the battery if it believes,
that is is completely charged. If the battery drops below a certain
voltage threshold, then the battery charger starts charging the
battery again.
For the bq25180 the threshold can only be one of either 100mV or
200mV below the VSET voltage.
See table 8-16 Bit 5 in https://www.ti.com/lit/ds/symlink/bq25180.pdf
Signed-off-by: Fabian Pflug <fabian.pflug@grandcentrix.net>
The linear battery charger will charge the connected battery up
to a specific voltage. This is different depending on the chemistry
of the battery. Most LiPo Batteries have a nominal voltage of 4.2V,
which is why the default voltage of the bq25180 is 4.2V.
Signed-off-by: Fabian Pflug <fabian.pflug@grandcentrix.net>
Features enabled by this commit:
* M7 core available with or without the Arduino MCU-based bootloader by
correctly initializing the external clock source.
* All LEDs, relays and the user button are mapped into the device tree
(samples/common/blinky works out of the box).
* USB can be used in ACM mode (samples/subsys/usb/cdc_acm works without
changes). The default Zephyr console is configured to use cdc_acm_uart0
that in turn is assigned to the only USB port available.
Also enable USB stack to make sure that the console is available by default
and twister builds don't fail with missing device and added the default USB
vendor (0x35d1 Finder SpA) and product (0x0164) numbers to match the ones
used in the original product.
Signed-off-by: Federico Di Gregorio <fog@dndg.it>
Add a sample that presents how the custom nrf2_clock_control API
introduced for nRF54H20 can be used for the various clocks which
are supported by it.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Add custom clock_control API for nRF platforms that allows requesting
clocks with specified minimal required attributes (accuracy, precision,
and frequency). Provide an implementation of this API for FLL16M, HFXO,
HSFLL, and LFCLK controllers in the nRF54H20 SoC.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Add bindings for nrf-fll16m and nrf-lfclk and update in-tree nodes
and boards to use them in place of the fixed-clock binding.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
These parameters will be used by the clock controller drivers.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
The HFXO and LFXO oscillators have properties which need to be
specified in the devicetree. These properties are used by clock
controllers, which get these properties from the devicetree.
The BICR also contains these properties. For now, the properties
are duplicated in the bicr node in the devicetree.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Add references to clock controllers so users can obtain
those for particular peripherals with DT macros like
DT_CLOCK_CTRL()
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
It has been observed that using a CMUX max frame size of 127
causes FCS errors; smaller or larger works. This commit sets the max
frame size to the modem's default value.
Signed-off-by: Emil Lindqvist <emil@lindq.gr>
U-Blox LARA-R6 was added to modem_cellular, and an additional state
was introduced where the UART baudrate is changed if the modem supports
it
Signed-off-by: Emil Lindqvist <emil@lindq.gr>
Describe the samples using code-sample directive in preparation for
upcoming changes to the Zephyr documentation that will be leveraging
the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Move some STM32 drivers related Kconfig symbols from `config`
to `menuconfig` when driver options depends on these symbols.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
This driver is mostly rewritten from scratch, with some parts borrowed
from the usb_dc_rpi_pico driver implemented by Pete Johanson.
This driver does not use any function from RPI PICO HAL and actually
could be furter improved to not use any defines or types from the HAL as
they are confusing and overdo it with volatile qualifiers.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
The STM32 SPI driver, `spi_ll_stm32.c`, reads the clock frequency via
`clock_control_get_rate()`. The first `clocks` index is used as subsystem
argument if there is no second index, but this is not the source clock for
SPI 1, 2, and 3.
This causes the prescaler value calculation to be incorrect, resulting in a
frequency potentially above the `spi-max-frequency` value.
Add clock source for SPI instances 1, 2 and 3, that matches the default
clock configuration register reset value, which resolves the issue.
Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
This commit introduces a new Kconfig option `CONFIG_SRAM_RETENTION_MODE`
that allows the configuration of SRAM retention mode during the
initialization phase of the firmware boot-up process. By default, the
retention mode is enabled to maintain the existing behavior. However,
this option provides the flexibility to disable the retention mode if
needed, without modifying the Zephyr codebase.
The SRAM initialization functions `hp_sram_init` and `lp_sram_init` in
`sram.c` have been updated to conditionally set the retention mode based
on the value of this Kconfig option.
Additionally, an unused macro `DELAY_COUNT` has been removed from
`sram.c` to clean up the code.
Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
There is no clear way for a candidate to assume the role of Maintainer
if the candidate is neither a Contributor nor a Collaborator. To avoid
disputes and confusion, candidates who are neither Contributors nor
Collaborators must be approved by the TSC before they can assume the
role of Maintainer.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Let's disable the default seeding done by the native_posix
entropy driver to allow the normal simulation initialization
of the random number generation to take place.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Provide a new kconfig option which can be used to disable
the default seeding of the host standard library random
generator by this driver.
This allows some other component to do so without this component
default initialization interfering.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Zephyr drivers have typically one log level defined per class. The video
drivers were making exception. This adds the missing log level for video
drivers.
Since all headers had to be modified, this also:
- Update the log initialization to the new syntax from 5e34681
- Sort the #include list to something like #41543
Signed-off-by: Josuah Demangeon <me@josuah.net>
When scanning and connecting in parallel with
CONFIG_BT_SCAN_AND_INITIATE_IN_PARALLEL enabled, a Bluetooth controller
may choose different scheduling approaches based upon the provided
parameters.
Nordic's SoftDevice Controller performs better when both roles
use the same scan window and scan interval. To help customers
choosing the right configuration, this should be documented.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
The function took the uri as a `char *` but is in fact
not a null terminated string so change the type to uint8_t *.
Add a check fro uri_len == 0 before doing uri_len - 1
Changed the found check to just check the first octet rather
than the more costly strlen.
Fixed the type of the iterator
Add a break in the loop as we only need to find one ":"
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
since stm32h7.dtsi is already include in st/h7/stm32h743.dtsi
we don't need to include here again.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
A warning was issued in the build as the rtio tx and tiny_tx buffer
pointers are now labeled const. The internal API expects mutable buffers
so an explicit cast is needed here to avoid the warning.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
Updates references to the net-tools project to refer to the correct
placement of net-tools under tools.
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
Add information about main(int, argc **) in places where the documentation
stated that only parameterless main could be used
Signed-off-by: Jakub Michalski <jmichalski@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Add bootargs support to zefi. This implements
get_bootargs() when both efi and bootargs are
selected in config.
Signed-off-by: Jakub Michalski <jmichalski@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Zefi was only including include/zephyr but not the generated include
directory that contains autoconf.h. This commit fixes that.
Signed-off-by: Jakub Michalski <jmichalski@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Add bootargs support for multiboot. This
implements get_bootargs() when multiboot and
bootargs are selected in config.
Signed-off-by: Jakub Michalski <jmichalski@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Add support for passing args to main(). The
content of bootargs is taken from get_bootargs()
which should be implemented for each loader and
then its split into args and passed to main.
Signed-off-by: Jakub Michalski <jmichalski@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Added links pointing to the Dedicated image build targets
from Optimization tools page for ram_report, rom_report, footprint,
puncover, and pahole.
Reported by @markaj-nordic.
Signed-off-by: Grzegorz Ferenc <Grzegorz.Ferenc@nordicsemi.no>
do a cold reboot by default if no option is provided
for `kernel reboot`, instead of requiring to
type `kernel reboot cold`.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
Move the lower bounds check of the enum value to a BUILD_ASSERT and make
sure the enum type is an unsigned integer.
Signed-off-by: Adrian Friedli <adrian.friedli@husqvarnagroup.com>
Add a description of the feather connector GPIOs. This enables a
featherwing shield to reference the GPIO by its label.
Signed-off-by: Philip-Dylan Gleonec <philip-dylan@gleonec.bzh>
Define the feather_spi SPI bus, which points to the corresponding
SERCOM. This bus label can be used by the featherwing family of
shields.
Signed-off-by: Philip-Dylan Gleonec <philip-dylan@gleonec.bzh>
Fix scan_update() implementation for missing flags clear
that prevented starting scanning after previous attempt to
start failed due to parameters being rejected by the
Controller.
Example, attempting to start coded PHY scanning with a
Controller implementation that does not support it can fail,
but attempting again without coded PHY scanning should
succeed.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
This commit updates revision of hal_nordic to bring the latest changes
in the nRF IEEE 802.15.4 driver.
Signed-off-by: Andrzej Kuroś <andrzej.kuros@nordicsemi.no>
The TBS client callbacks are just informative so we
provide the information to multiple listeners.
To support this for the long strings, the function
handle_string_long_read was refactored.
This also allows for multiple users of the TBS client.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
When the encrypt state was changed via
bt_bap_scan_delegator_mod_src then we didn't set the bad
broadcast code correctly.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add a bsim test that verifies the behavior when the
assistant provides an incorrect code to the broadcast
sink.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The function had marked the type as char *, but it was in fact
not a string but rather a uint8_t array.
Marked the type properly and added a cast when using it with
bt_tbs_remote_incoming.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The CAP commander used bt_audio_valid_ltv which required
BT_BAP_STREAM to be enabled, but the CAP Commander does not
need BT_BAP_STREAM to be enabled.
Moved the function to audio.c which is always compiled for
the CAP Commander, thus removing the requirement for
BT_BAP_STREAM and the accompanying bt_bap_stream.c file.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The UTF8 implementions for both client and server
both use the utf8 API which require CONFIG_UTF8.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The function had marked the type as char *, but it was in fact
not a string but rather a uint8_t array.
Marked the type properly and added a cast when using it with
strings.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Require the presence of the nrf-regtool package as well as its exact
version, failing the build whenever the required version is not found in
the system.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
YD-STM23H750VB board has 128 Kbytes of flash memory, 1 Mbytes of SRAM
and 16 Mbytes onboard SPI norflash.
Signed-off-by: John Sanpe <sanpeqf@gmail.com>
Modify the CAP stream callbacks so that the application
callbacks are called before the CAP initiator.
This allows the application to abort/cancel a procedure
before we send out any future request.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
With over a dozen LED samples, grouping them in a common drivers/led/
folder helps keep things tidy and lays the groundwork for further
improvements in the way samples are showing up in the docs.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The flash controller is nowadays supported on the M4 core.
Add the bank2-flash-size property to the board definitions as required
by the STM32 H7 flash driver.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Currently DMA overrun errors are ignored. Forward the error
to the user using the UART_RX_STOPPED with UART_ERROR_OVERRUN
reason.
Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com>
If an overrun happens the user may decide to stop the dma which
unsets the DMA line. Currently, the line is always re-enabled after the
callback.
Switch the order around to fix the problem. Also, always reset the line
even if the user doesn't provide a callback.
Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com>
Remove parts of the documentation for the nrf9280pdk board
that were copy-pasted and added by mistake.
Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Use the RTIO work queue to fake the i2c submit calls for drivers which
haven't yet implemented the API. Applications can change the size of
the work queue pool depending on how much traffic they have on the buses.
Signed-off-by: Yuval Peress <peress@google.com>
Fixed build warnings of ADC for MAX32662 and MAX32672 SoCs on
hal_adi size, this commit fetches it.
Signed-off-by: Furkan Akkiz <hasanfurkan.akkiz@analog.com>
Right now "lp5562_led_blink" unconditionally find and assign a engine
that is not executing at the moment. This is an issue, if 3 "led" are
already using an engine. That is a call to "lp5562_led_blink" could
terminate with error, even if the "led" is already using an engine.
This commit fixes this issue by adding a check to see if engine is
linked and reuse it, otherwise assign a free engine.
Signed-off-by: Anuj Pathak <anuj@croxel.com>
Remove the toolchain_ld_<base|baremetal|cpp> macro as all the macro
handling is now done through the use of linker properties.
Keep support for calling the old macros for out of tree toolchains
which have not been updated to the new property approach.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Move linker flag setting from toolchain_ld_baremetal() to linker flag
properties as to follow the principle used in previos commits and from
PR#24851.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Transition the linker flag for the toolchain_ld_base and
toolchain_ld_cpp macros to linker flag properties.
This work follows the toolchain abstraction started in PR#24851.
toolchain_ld_base() was intended for base linker flags, but has slowly
become a 'set-any-linker-flag-here' and thus having several
`if(<check>)` or `<func>_ifdef(<check> ...)`.
Move the check to the top-level Zephyr CMakeLists.txt file, so that it
becomes cleaner which part is responsible for setting a value, and then
move the actual value (the linker flag) definition to the linker flag
property location.
It also helps adding support for new linkers, as it becomes clearer
which linker flags Zephyr always expects, for example `base` and
`cpp_base`, as well as those settings which are targeting for a given
purpose, such as linker sort alignment.
It also makes it clearer when those are used, for example in top-level
CMakeLists.txt with CONFIG_LINKER_SORT_BY_ALIGNMENT compared to this
information being buried in a linker support macro.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
To ease the use of linker flag properties and to simplify the use of
generator expression then an optional PROPERTY argument has been added
to the zephyr_link_libraries() function.
This means a call such as:
zephyr_link_libraries($<TARGET_PROPERTY:linker,<property-name>)
can instead be simplified to:
zephyr_link_libraries(PROPERTY <property-name>)
Thus making intention clearer and keeping the complexity and minimizes
the risk of typos when writing generator expressions.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
The selection of the runtime library when using LLVM has already been
done in llvm/target.cmake and passed to the toolchain_ld_base() function
through the global TOOLCHAIN_LD_FLAGS setting.
The only reason this haven't been noticed is because of CMake's built-in
symbol de-duplication feature.
Remove the redundant runtime library handling.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
The support of PROPERTY_LINKER_SCRIPT_DEFINES has been broken since
the transition to CMake in 12f8f76165.
The intention was probably to allow users / projects to adjust
PROPERTY_LINKER_SCRIPT_DEFINES by setting a CMake cache variable.
The implementation tests for the CMake variable (local scope or cache)
PROPERTY_LINKER_SCRIPT_DEFINES, but it never uses such CMake variable.
Instead it uses a CMake global property named
PROPERTY_LINKER_SCRIPT_DEFINES. CMake variables and CMake global
properties are two very different things, and therefore the current
implementation has never worked. The fact that no one has never noticed
this flaw, means that the feature has never been used as intended.
Simplify the code by removing the use of the global CMake property and
instead set the value of the property on the linker script
pre-processing invocation.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
The macro `toolchain_cc_nostdinc` were made obsolete with PR#24851 and
are no longer invoked.
Remove the macro implementations.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Commit 282f77e732f0a4bc859f559bc5a748f953a8140c removed the only place
defining LIBC_INCLUDE_DIR. Remove the corresponding use of
LIBC_INCLUDE_DIR from newlib/CMakeLists.txt as this setting is no longer
being defined anywhere.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Describe the samples using code-sample directive in preparation for
upcoming changes to the Zephyr documentation that will be leveraging
the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
`explorir_m_uart_flush_until_end` terminates immediately if the read
variable is initially equal to `EXPLORIR_M_MAX_RESPONSE_DELAY` and
`uart_poll_in` does not read anything.
Fix this by only checking the read variable if `uart_poll_in` reads a char.
Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
Commit 87f68b4dfe ("arm64: linker: move data section between rodata
and bss") moved .data up a little too far. Keep app_smem in front of it
otherwise user memory partitions end up in general .data with no user
permissions.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Ensure that leading zeros are present in the milliseconds field,
otherwise a milliseconds count of 35 will appear as x.35, i.e. 350
milliseconds. With this fix, it will appear as x.035.
Signed-off-by: Jordan Yates <jordan@embeint.com>
This patch adds bindesc support for the build version values for the
kernel and application - BUILD_VERSION and APP_BUILD_VERSION.
The kernel's BUILD_VERSION can be overridden at build time.
Signed-off-by: Attie Grande <attie.grande@argentum-systems.co.uk>
Modify USBD_DEFINE_MSC_LUN() to take in separate id by which the LUNs
are sorted. Previously the disk name itself was implicitly used as a
sorting key. This is a breaking change to Experimental API.
Another advantage of splitting the sorting id from disk name is the
ability to use KConfig symbols as disk name. Currently the MMC disk
driver uses KConfig symbol CONFIG_MMC_VOLUME_NAME.
Mark LUN definitions as static const because the LUNs are ending up in
ITERABLE_SECTION_ROM().
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
This commit updates the board documentation to match the I2C1 default
peripheral mapping in rpi_pico-pinctrl.dtsi.
Signed-off-by: Thomas Keller <t.tschaler@gmail.com>
The initialization of the UARTE is attempting to handle potential
improper handover from the bootloader. This handling is additional
complexity which should be fixed in the bootloader or whatever
component is failing to deinit the UART properly.
This commit removes the handling of improper handover from the
bootloader, while additionally clearing the ERROR flag when suspending
the UARTE component.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Add default memory partitioning for the nRF53 and nRF91 series devices.
As these partitions refer to TF-M and the TF-M layouts cannot be
modified, use the partitioning scheme from TF-M.
Signed-off-by: Jordan Yates <jordan@embeint.com>
mbox_error_cases tests must be run with the nordic-flpr snippet
to prevent bus fault error while accessing VPR registers.
Signed-off-by: Jakub Zymelka <jakub.zymelka@nordicsemi.no>
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
According to the official MBOX API documentation available at
https://docs.zephyrproject.org/latest/hardware/peripherals/mbox.html
mbox_sen() shall return
-EMSGSIZE – If the supplied data size is unsupported by the driver.
Fix error code returned by the mbox_send().
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
Add negative test cases for the MBOX driver.
Confirm that driver implementation is aligned with
the MBOX API documentation available at
https://docs.zephyrproject.org/latest/hardware/peripherals/mbox.html
Enable test execution on nRF54H20 Application and PPR cores.
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
Add Kconfig option to specify Xen interface version to use. This will
make it easier to switch between different versions of Xen.
Signed-off-by: Mykyta Poturai <mykyta_poturai@epam.com>
Add a line of whitespace between `/* clang-format off */` comments and
the first line of doxygen comment blocks. Some intellisense parsers
will combine all sequential comment blocks when providing code context.
This results in the control comment appearing in the help text for
`ZBUS_CHAN_DEFINE`, for example.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Remove `const` qualifiers on fields in structures that are only created
or instantiated as `const`.
This if primarily for consistency, in the same way that `struct device`
fields and `device->config` struct fields are not additionally marked as
`const`.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Initialise the semaphores in the init function so that a copy of the
data structure does not need to exist in `.data`.
Signed-off-by: Jordan Yates <jordan@embeint.com>
There is asignment from size_t variable to uint8_t variable in
nvs_al_size function that can trigger static analysis error.
The problem is fixed by changing the variable to size_t type
instead of uint8_t.
Signed-off-by: Andrej Trnkóci <andrej.trnkoci@nxp.com>
The table of contents already has a caption so the "Sections"
heading is effectively redundant.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The descriptions of the homepage grid items were too long and often
repetitive (e.g. there's no need to repeat "Zephyr" in almost every
descriptions). This commit shortens them to aim at having them fit on
two lines, three at most.
Also updated the look&feel slightly.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The IEEE 801.15.4 monitor can be started by a parameter to cmake. This
change removes a TODO to kill the monitor after qemu ends.
The change also re-assigns Ctrl-C to Ctrl-D to ensure that QEMU is not
inadvertently sending SIGINT to the surrounding ninja session (which
would leave the monitor sub-process alive).
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
Adds support for settings/getting RTC time and using alarm/update feature.
The alarm option needs all fields to be set due to a hardware limitation.
RTC shares the same interrupt with the watchdog. Thus shared
interrupts must be enabled when WDT and RTC both need to trigger the ISR.
Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com>
A bug was introduced when fb17d0e365 introduced host presence detection.
Panic_mode flag was added which indicates that RTT should work in
synchronous, blocking mode but it was not set when backend was switched
to panic mode.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Commit bb74b4f028 deprecated a few
CBPRINTF_PACKAGE_COPY_* macros. This drops them and calls out the
change in the release notes.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Do not change the default value of `NORDIC_QSPI_NOR`. It resulted in
undefined references to the DT node `/soc/qspi@40029000/mx25r6435f@0`
when enabling the flash driver.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Prevent `warning: orphan section `.note.GNU-stack'` when building using
`west build -b xt-sim samples/hello_world`
Signed-off-by: William Tambe <williamt@cadence.com>
Replace several bools in bt_aics_client with an atomic value.
Update how these values are modified so that we can better
prevent race conditions.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The ringbuffer availability check is subject to race with regards to
update of BF (Buffer Full) and BNE (Buffer Not Empty) bits in DGCS
register, and status of RP (Read Position) and WP (Write Position).
Following sequence is observed without this patch when
calling dma_get_status() on multiple Intel ADSP platforms:
iter 154 pending 1536 RP 768 WP 768, BNE 1, BF 1
-> dma_reload for 384
iter 155 pending 1536 RP 1152 WP 1152, BNE 1, BF 1
-> dma_reload for 384
iter 156 pending 0 RP 0 WP 0, BNE 1, BF 0
Value of pending is not expected to go from 1536 to zero if only 384
bytes have been consumed via dma_reload() since last call to
dma_get_status().
Change the logic to read DGCS register later, after the WP and RP have
been already read, and only check the BNE bit if Read and Write
Positions are equal.
Link: https://github.com/thesofproject/sof/issues/9418
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Co-developed-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Remove myself from the collaborator as there's a maintainer now.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
While it's by definition not possible to check that the "source" for a
redirect entry is a valid path, the "destination" could be checked to be
pointing to an existing resource. This will also help catch potential
errors in the "source" as well since it's common to mess up the paths
for both.
Fixes#77797
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Fixed entries pointing to invalid destinations either due to resource
having been removed or moved once more, or entries being plain broken
from day 1.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Added note about enabled support for the flashing of
.elf files for jlink, pyocd and linkserver runners.
By commits:
- e767ac0703
- c1fe3150e9
- 3f5fc42fba
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
Adds missing checks for get_capabilities method not being NULL.
Fixes crash with netusb and possibly other drivers.
Signed-off-by: Maciej Panek <panekmaciej@outlook.com>
When build with the psa_crypto_driver, it will try to include common.h
of mbedtls, but actually include the common.h from hostap, and causes
build error of undefined symbol. Now link the library of hostap to use
the header file in /utils path, to fix the build error.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
When build with the psa_crypto_driver, it will try to include common.h
of mbedtls, but actually include the common.h from hostap, and causes
build error of undefined symbol. Use zephyr_interface_library_named
to define hostap, and other modules needs to link the library of hostap
when wants to use the header file in /utils path, such as the common.h.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
In corner case, the pending ISR will be triggered immediately
after enable the IRQ, this PR will setting CPU affinity first
to avoid routing the unexpected IRQ to other CPUs.
Signed-off-by: chao an <anchao@lixiang.com>
Update the HW models module to:
4b0b020e25dbf1a11ccccf7b7741d6ca991ba9e4
Including the following:
* 4b0b020 54L CLOCK: Generate XOSTARTED event
* 79287fb hal: RADIO: support also triggering TASK_SOFTRESET from HAL
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
The nrf54l15dk is now avaliable in the tree.
Let's compare the simulated board to this one instead.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
These peripherals are now included. Let's mention them
and remove the warning about them being missing.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This target does not yet support the PSA random generator.
Lets explicitly set it to disabled, to even if the
SOC definition sets it to "okay" it is not built in
by default.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Remove 3 delete-node directives which do not apply to this
SOC.
They made it in originally thru a copy paste mistake
from the nrf5340bsim dts file.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Xtensa toolchains also contain a profile for sample_controller.
So if compiling for it, skip the Xtensa HAL module in Zephyr
tree so the toolchain can use the one included in the toolchain.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Select PINCTRL subsystem by drivers which require it.
Prevent the need from enabling this symbol at board or soc level.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
WIFI_NM_WPA_SUPPLICANT_CRYPTO_MBEDTLS_PSA should not be by default
selected when WIFI_NM_WPA_SUPPLICANT_CRYPTO_ALT is selcted. Enable
PSA APIs if desired separately.
Signed-off-by: Vivekananda Uppunda <vivekananda.uppunda@nordicsemi.no>
Set WIFI_NM_WPA_SUPPLICANT_CRYPTO_ALT as the default crypto
configuration. The crypto ALT implementation contains the necessary
crypto operations and also allows the user to choose PSA or non PSA
crypto operation.
Signed-off-by: Vivekananda Uppunda <vivekananda.uppunda@nordicsemi.no>
In the IT82xx2 chip, the ready bit is automatically cleared by
hardware. When setting other bits, there is a chance that the ready bit
hasn't been cleared yet, leading to unexpected USB transactions. This
change ensures that the ready bit is always set to '0' when setting the
endpoint control value.
Signed-off-by: Ren Chen <Ren.Chen@ite.com.tw>
Save power when the bus is suspended by entering hibernation if
hibernation support is enabled and controller supports hibernation.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add Power and clock gating control register to register map and
appropriate bit macros. Add missing GHWCFG4, GLPMCFG and GPWRDN bits.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add barrier between triggering Capture task and reading CC as otherwise
it is possible that CC read will occur before task is triggered when
bus is busy.
Add barrier between reading previous CC value and writing the new one.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
This reverts commit 331442f059.
Change was introduced because it was failing on slow core
(nrf54h20/cpuppr) however it turned out that there was a bug in the
driver and now test passes without this tweak which make the test
last twice longer.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Having .data after .bss creates a big empty gap in zephyr.bin to provide
proper offset for the data section. Reversing them allows for dropping
.bss from zephyr.bin's output as it is typically done, saving precious
flash memory space.
For demonstration purpose, let's consider those changes:
|--- a/samples/hello_world/src/main.c
|+++ b/samples/hello_world/src/main.c
|@@ -6,9 +6,12 @@
|
| #include <stdio.h>
|
|+int dummybuf[1024 * 1024];
|+
| int main(void)
| {
| printf("Hello World! %s\n", CONFIG_BOARD_TARGET);
|+ dummybuf[0] = 42;
|
| return 0;
| }
Before this commit:
$ ls -l build/zephyr/zephyr.bin
-rwxr-xr-x 1 nico nico 4561908 Aug 2 15:13 build/zephyr/zephyr.bin*
After this commit:
$ ls -l build/zephyr/zephyr.bin
-rwxr-xr-x 1 nico nico 37028 Aug 2 15:17 build/zephyr/zephyr.bin*
While at it, remove some more repetitive comments with no value.
Also defaults CONFIG_LINKER_LAST_SECTION_ID to n as it otherwise screws
everything up for the same reason as above.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
add driver for Monolithic Power Systems MPM54304 with basic
functionality to enable/disable the buck regulators
Signed-off-by: Elias Speinle <e.speinle@vogl-electronic.com>
odroid_go is using ESP32 chip revision (1) that is unsupported,
so we need to enable 'CONFIG_ESP32_USE_UNSUPPORTED_REVISION'
Signed-off-by: Yannis Damigos <giannis.damigos@gmail.com>
This option switches support for multiple volumes on the physical drive. By
default (0), each logical drive number is bound to the same physical drive
number and only a first FAT volume found on the physical drive will be
mounted.
When this function is enabled (1), each logical drive number can be bound
to arbitrary physical drive and partition listed in the VolToPart[].
The VolToPart[] is expected to be provided by Zephyr application.
For example, 2 FAT partition on SD disk ("SD" index 3) in terms of Zephyr:
{3, 1} - mount point "/0:"
{3, 2} - mount point "/1:"
The mount points have to be numbered in this case.
Code example of mounting a second FATFS partition places on SD-card:
static FATFS fat_fs;
static struct fs_mount_t mp = {
.type = FS_FATFS,
.fs_data = &fat_fs,
.mnt_point = "/1:
};
/*
* 2 FAT partition on SD disk
* PARTITION.pd - Physical drive number. "SD" has index 3 in terms of
* Zephyr (see FF_VOLUME_STRS)
* PARTITION.pt - Partition (0:Auto detect, 1-4:Forced partition). So 1 for
* the first FATFS partition and 2 - for second.
*/
PARTITION VolToPart[FF_VOLUMES] = {
[0] = {3, 1}, /* "0:" ==> 1st partition on the pd#0 */
[1] = {3, 2}, /* "1:" ==> 2nd partition on the pd#0 */
[2] = {0, -1}, /* "2:" ==> 3rd partition on the pd#0 */
[3] = {0, -1},
[4] = {0, -1},
[5] = {0, -1},
[6] = {0, -1},
[7] = {0, -1},
};
fs_mount(&mp);
Signed-off-by: Grygorii Strashko <grygorii_strashko@epam.com>
The Kconfig option enables support for 64-bit LBA, which also allows
to enable GUID Partition Table (GPT) support.
Signed-off-by: Grygorii Strashko <grygorii_strashko@epam.com>
For almost all STM32 GPIO controllers, the number of supported GPIO
pins managed by a single controller is 16 (with some exceptions for
fewer). However, the default for ngpios in the device tree bindings
for gpio-controllers is 32; leading to inaccuracies in handling GPIO
for these controllers, such as presenting too many GPIOs in the GPIO
shell. This patch redefines the default for ngpios for "st,stm32-gpio"
compatible devices to 16 and adds the correct ngpios for the few
exceptions Zephyr current supports.
Signed-off-by: Michael R Rosen <mrrosen@alumni.cmu.edu>
When calling bt_cap_initiator_unicast_audio_start on a set of streams
that are all in the streaming state we return early with -EALREADY.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The unicast_start procedure should take a stream in any state
and put it in the streaming state. Adds tests with streams
in various states.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
This allows the procedure to work for streams in the non-idle state,
e.g. we can start one of more streams in the codec configured
or even enabling state.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
This allows applications to modify the values set by an
existing unicast group, assuming that none of the streams in
the CIG has been connected.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
So far 10 kHz tick rate was used but it has 2 drawbacks:
- kernel timer precision is limited to 100 us which is worse compared
to 30 us on platforms which use RTC (which had 32768 Hz tick rate)
- GRTC has 1 MHz frequency so tick rate requires dividing by 100 during
timeout calculation. When 31250 Hz is used (which is 1000000 / 32)
then dividing can be done with bit shifting and it is faster (> 2 times
faster on Cortex-M33 and >8 times faster on VPR - RISCV).
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Behaviour is unchanged for max_skip == 0
For max_skip > 0, use a slightly different calculation to ensure
we can pass LL/DDI/ADV/BV-28-C
Signed-off-by: Troels Nilsson <trnn@demant.com>
Updated condition to enable NET_STATISTICS. Changed
CONFIG_NET_STATISTICS_ETHERNET to CONFIG_NET_STATISTICS_WIFI
in airoc_wifi.c
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
Issue:
Kconfig WIFI_AIROC should not depend on infineon SOC family selection
for the connection. See issue#77012 for details.
Fix:
- update modules/hal_infineon/Kconfig to be able enable
USE_INFINEON_ABSTRACTION_RTOS for non Infineon SOC family.
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
Ignores "command disallowed" if the host privacy implementation tries
to change the device's random address while scanning or initiating.
This is not allowed by spec. It's caused by scan_update() in scan.c.
Signed-off-by: Olivier Lesage <olivier.lesage@nordicsemi.no>
CONFIG_SOC_COMPATIBLE_* is not configurable but CONFIG_BT_LLL_VENDOR_* is.
This allows an alternate LLL to be built on nordic and OpenISA chips.
Signed-off-by: Félix Piédallu <felix@piedallu.me>
With ACE2/3 the HDA DMA includes registers to read the Linear Link
Position.
Previous platforms (CAVS, ACE1) was able to report the LLP for GPDMA. Since
ACE2 all links are handled with HD-DMA, hence the new register has been
added for the firmware to report the LLP to the host.
Set the total_copied to 0 for older ACE1/CAVS platforms and in case of
host DMA on ACE2/3 since the informatiojn is not available.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Fixes: #77705
Fix wrong macro.
Tested with all the boards mentioned in that issue, build now works.
Signed-off-by: Sergio R. Caprile <scaprile@gmail.com>
The logs for retransmission attempts for sending segments and ack
retransmission attempts for receiving segments were the same, making it
difficult to distinguish between them. This can be solved by adding
information to the log of ack retransmission.
Signed-off-by: Junho Lee <tot0roprog@gmail.com>
Add the possibility to disable fault handling in spurious
interrupt handler on RISCs and replacce it with an infinite loop.
Signed-off-by: Magdalena Pastula <magdalena.pastula@nordicsemi.no>
[Reproduce issue]
1. Connect In-STA to Ex-AP
wifi connect WiFi_STA_HE_1.1.8 1234567890 3 2 2
2. Start APUT with ACS using below commands
wifi ap enable nxp-AP 161 1234567890 3
3. Connect Ex-STA to APUT and verify association using ping traffic
4. Now start two TCP server
zperf tcp download -I ml 5001 192.168.0.252
zperf tcp download -I up 6002 192.168.10.1
Observed behavior:
=============
Second TCP server fails to start
[Analysis]
1. After starting uap and a tcp server,
there is only one allocatable fd resource
left in the fdtable.
2. When two TCP clients try to establish a connection
with the server at the same time, the second client
cannot be assigned an fd, resulting in a failure.
[Fix]
Increase the maximum number of open file descriptors.
Signed-off-by: Qiankun Li <qiankun.li@nxp.com>
The change of alignment check in #76045 could be wrong and
isn't unnecessary to fix the stack traces output, undo it for
now.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Using strncasecmp to match HTTP headers can give unexpected results when
the strings to be compared match up until the end of one string, but the
other string contains additional characters. This can result in falsely
matching a HTTP header value, for example:
strncasecmp("Upgrade-Something", "Upgrade", sizeof("Upgrade") - 1) --> 0
In this case we know that both strings are NULL terminated since one is
a string literal and we have just length-checked and explicitly NULL
terminated the other. So we can just use strcasecmp without a max
length.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
The lwm2m_check_buf_sizes() function was not checking resources of
type LWM2M_RES_TYPE_U16, which could lead to potential overflows
when writing larger data types into U16 resources. Add a case for
LWM2M_RES_TYPE_U16 to properly validate the buffer size.
Fixes#77016
Signed-off-by: Hyunsu Yoon <piedroconti@naver.com>
If IPv6 is enabled, the fixed size net_buf data needs to be
large enough so that the full IPv6 header with extensions
can fit to one net_buf packet.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
When an LLEXT object uses symbols of another such object, it depends
on it. Such dependencies have to be tracked to prevent their
accidental unloading. Ideally we should be able to track arbitrary
numbers of such dependencies, but this is a bit difficult. In this
first implementation we use a fixed-size array, currently consisting
of 8 entries.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
When deciding which sections to group together, only the low 3
section attribute bits are relevant, ignore the rest.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Using the immediate logging option from LLEXT modules requires
one more symbol export.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
LLEXT objects can also export symbols for use by other such objects.
That means, that when linking an LLEXT object we have to look for
unresolved symbols in previously loaded objects too.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Replace LL_EXTENSION_SYMBOL() with EXPORT_SYMBOL() in all tests and
samples.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Currently LLEXT has two ways to export symbols:
EXPORT_SYMBOL() to exort symbols from the main firmware to extensions
LL_EXTENSION_SYMBOL() to export symbols from extensions
but it is possible to write code, that needs to export symbols
regardless of whether it is built into the main image or an
extension. And in fact there's no real need in two distinct macros -
we can use one for both cases and recognise at build time which
direction exporting is happening. This patch extends EXPORT_SYMBOL()
to also work from extensions.
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Add a mode to build the driver without FW blobs, this is mainly for
twister to run and catch any build issues without depending on any FW
blobs.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
The `bt_id_set_adv_own_addr` function itself tries to allocate a buffer
for the command and it failes due to lack of buffers, it returns error.
However, the `le_ext_adv_param_set` function doesn't handle the error
properly and keeps its own allocated buffer.
This commit releases the allocated buffer.
Partially fixes mesh in #77241.
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
Add nrf5x binding header, as NRF5X_REG_MODE_DCDC is used in a macro
comparison. Missing header prevented evaluation to become true and so
enable DC/DC module.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Implemented new DIS characteristics:
- UDI for medical devices
- IEEE 11073-20601 Regulatory Certification Data List
- System ID
Also fixed buffer overflow bug when assigning too long DIS string literals
Signed-off-by: Simen Eilevstjønn <simen.eilevstjonn@laerdal.com>
Enable CYW20829_BT_FW_TX10DBM_POWER by default to get
best user experience experience out of the box.
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
Update CYW20829 Bluetooth LE fw for PAwR support
Commit#88d2529a3c5aee2e81947553bf6cbacb4671088c
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
Problem:
on cyw208xx devices i see sometime `Timed out while synchronizing`
error in samples periodical_adv_rps/periodical_sync_rps.
log:
<err> bt_scan: Could not lookup connection handle from PAST
<err> bt_scan: Unknown handle 0x0000 for periodic advertising report
Timed out while synchronizing
...
After investigation i can confirm, the sync was created successful,
but in application (periodical_sync_rsp) terminated the sync when the
connection is not valid.
periodical_adv_rps doesn't have any mechanism to wait for sync and after
gatt write (subevent, response_slot information) it immediately
performs disconnection.
Solution:
Added sync wait delay before make disconnection, to ensure sync
is established before disconnection.
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
Added setup of PUBLIC ADDR
NOTE: By default, the CYW208xx controller sets some
hard-coded static address.
To avoid address duplication, let's always override
the default address by using the HCI command
BT_HCI_VND_OP_SET_LOCAL_DEV_ADDR. So
1. when cyw208xx_setup gets BT_ADDR_ANY from the host,
it will overwrite the default address, and the host
will switch to using a random address (set in the hci_init
function).
2. If user set the static address (by using bt_id_create)
before bt_enable, cyw208xx_setup will set user defined
static address.
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
Remove print "Failed to receive response...", if receive
BT_HCI_LE_ADV_EVT_TYPE_DATA_STATUS_RX_FAILED.
Problem: with cyw920829m2evk_02 device periodic_adv_rsp returns
multiple messages “Failed to receive response….” in the terminal
log.
This happens because controller generates
HCI LE Periodic Advertising Response Report event for each
RspSlot. Because no RSP_DATA is observed in the OTA, which
is no scan device to transmit RSP_DATA, no RSP_DATA can be
received. Therefore, Data Status is 0xFF in all of these events,
which finally cause the messages “Failed to receive response….”
Data_Status = 0xFF is expected because nothing is received
for that Rsp Slot.
Per spec, it’s not mandatory to generate these events,
So another vendors (e.g. Nordic) might skip the HCI event
generation if Data_Status = 0xFF.
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
Select PAwR if enabled following features:
- BT_PER_ADV_RSP
- BT_PER_ADV_SYNC_RSP
Remove dependency BT_AIROC_CUSTOM for AIROC_CUSTOM_FIRMWARE_HCD_BLOB
Signed-off-by: Nazar Palamar <nazar.palamar@infineon.com>
The 'soft-off' state must be used when explicitly request by calling
`pm_state_force`. Set this state as disabled in dts ensures that the
pm policy manager will not use this state.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
Stores a magic value togetter with the counter value, and resets the
counter in case that magic does not match.
A small magic value is not ideal, but should be good enough for the
sample and avoids pulling in a additional dependency e.g. on crc.
Signed-off-by: Thomas Stranger <thomas.stranger@outlook.com>
This commit moves the backup sram definition to the
series base dtsi file, the size is overwritten for socs
which have a bigger bkpsram.
The backup SRAM is available on all stm32h5 mcus.
stm32h503/523/533 have 2k
stm32h562/563/573 have 4k
Signed-off-by: Thomas Stranger <thomas.stranger@outlook.com>
Describe the samples using code-sample directive in preparation for
upcoming changes to the Zephyr documentation that will be leveraging
the provided description and metadata.
Also fixed a couple invalid or missing table of contents to have
proper document hierarchy.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
On stm32h735g_disco, `arduino_gpio` is declared while the connector is not
actually described.
On stm32h750b_dk, connector description was simply not included.
All these are blocking tests trying to make profit of arduino gpio
connectors.
Fix these.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
Rename `BT_CONN_AUTO_FEATURE_EXCH` to `BT_CONN_LE_FEATURES_EXCHANGED`,
and add some comments for readability.
Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
When using the it8xxx2bx chip, because the SRAM size is 60k and
not a power of 2, using (CONFIG_SRAM_SIZE - 1) results in an
incorrect value for the h2ram base address mask.
Therefore, the mask is declared as GEMASK(19, 0) here.
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
DMA_INTEL_ADSP_HDA_TIMING_L1_EXIT should be set by default
for all Intel ACE platforms
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@intel.com>
Tmr and dtmr drivers were missing a flag which tells the
counter_is_conting_up function that the counter is counting up. So I've
added the flag
Signed-off-by: Krystof Sadlik <krystof.sadlik@nxp.com>
If CONFIG_LOG_BACKEND_SHOW_COLOR is disabled, error and warning
lines are still being outputted with color, which is contrary to
what the Kconfig says. So change the color settings for error
and warning lines to no color if this Kconfig is disabled.
The log_output test is also amended to account for this.
Though the test is not skipped as no color is still some colors
(... well... maybe).
Fixes#77150
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
- Update the wrong value of xtal frequency on EK-RA6M1
- Update documentation of EK-RA6M2 regarding to clock description
Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
The samples had a _iso suffix, but the other ISO samples
prefix iso_.
Renames the central and peripheral sample so that they
prefix iso_ rather than suffix _iso.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Due to it is a normal firmware downloading sequence,
it should be a debug log instead of error log.
Change LOG_ERR to LOG_DBG for this case.
Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
The way ESP32 XIP works (with MMU and cache) does no fit the way Zephyr XIP
is implemented, causing issues related to included Zephyr linker files.
Flash code still resides in flash for execution, but MMU/Cache handles it
in such way that XIP might not (or should not) be used with current Zephyr
approach. To address this problem, XIP configuration option is being
removed from Espressif targets.
Signed-off-by: Marcio Ribeiro <marcio.ribeiro@espressif.com>
Several BSIM tests did not enable -RealEncryption=1.
Since everything in LE Audio effectively requires encryption,
we should enable it, as we have seen a few tests passing before
that shouldn't, because they didn't set -RealEncryption=1.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
With commit ad242b9, the buffer size was made configurable. Hence, the
corresponding definition CONFIG_SAMPLE_BUFFER_SIZE has to be used when
filling and displaying the buffer.
Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com>
Enable central HR peripheral HR samples for nrf54l15bsim.
RealEncryption is BabbleSIM is not enabled as nRF54L port
in Zephyr Controller is not yet supported and the test is
also not using security (SMP pairing).
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Use SW_SWITCH_SINGLE_TIMER for nRF54Lx so that fast ramp
can be used, and hence support assymmetric PHYs in ACL
connections.
nRF54Lx radio domain does not have second timer instance
to efficiently implement software switch unless a second
time is used from a different power domain needed use of
PPIB for the double buffered switch timer compares.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Use NRF_GRTC, Global real-time counter, instead of NRF_RTC.
NRF_GRTC is present in a different power domain in the SoC.
Also, NRF_GRTC provide microsecond resolution timing units,
in the future use of NRF_TIMER for packet timer can also be
replaced.
Use of NRF_RTC would keep Radio power domain ON in addition
to already ON NRF_GRTC's power domain, hence switch to using
NRF_GRTC on nRF54Lx SoC to have lower power consumptions.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
nRF54Lx have updated Data Whitening register settings, add
implementation to correctly set them up.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Refactor sw_switch hal interface use and document why some
PPI/DPPI channel group related subscriptions are not
disabled explicitly.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix software tIFS switching using single timer from
triggering spurious TXEN/RXEN if the first remainder is
shorter than the tIFS delay calculated in the sw_switch()
function.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
New file with ADC configuration for UCANS32K1SIC evb.
Add ucans32k1sic_s32k146 to platform_allow.
Signed-off-by: Marcin Wierzbicki <marcin.wierzbicki@accenture.com>
Extend the adc_mcux_adc12 adc api to set the ref_internal to
a value of vref-mv property.
Signed-off-by: Marcin Wierzbicki <marcin.wierzbicki@accenture.com>
Add the vref reference voltage in the DTS, so that the adc driver
can retrieve the value for conversion.
Signed-off-by: Marcin Wierzbicki <marcin.wierzbicki@accenture.com>
Enable support for channels >= 16 on devices S32K146 and S32K148.
Channels >= 16 are encoded as 100000b..101111b in SC1[ADCH] field.
Signed-off-by: Marcin Wierzbicki <marcin.wierzbicki@accenture.com>
Update Ambiq adc driver to add apollo4
fixed typ of BUMBER to NUMBER
Move buffer size prio to configuring slots
and enabling the ADC
removed #if defined(CONFIG_PM_DEVICE_RUNTIME)
Signed-off-by: Richard Wheatley <richard.wheatley@ambiq.com>
Get data for various roots from modules and do not hardcode location
when retrieving list of boards in testplan.
Fixes#71761
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add the yaml files needed for the dts binding of the Bosch bmp180 sensor.
V2 Fixup
--------
yaml fixup for complient checks
merge bmp180-i2c.yaml and bmp180.yaml
Signed-off-by: Chris Ruehl <chris@gtsys.com.hk>
Add driver support for Bosch bmp180 pressure sensor running on i2c bus.
It pushes the driver files to the bmp180 directory under
drivers/sensor/bosch. The driver implement the Sensor API
and support channel DIE_TEMP and PRESSURE.
Driver had been tested with the NRF5340DK.
V2 fixup
---------
Drivers: Bosch bmp180 fixups for PR v2
fix BMP180 in CMakeLists.txt
rename regControl to ctrlreg
simplify the logic in set_attribute
use BMP180_GET_CMD_TEMP_DELAY
Drivers: Bosch bmp180 use system byteorder macros
To aware of ENDIANESS use the macros from byteorders.h
Drivers: Bosch bmp180 comments added to #endif
Add a comment to the #endif /* CONFIG_FOO */
Drivers: Bosch bmp180 , fix twister run error
twister report an error related to using floor() with a float
fix this using floorf() function.
Drivers: Bosch bmp180, rework review v2
fix code style issues
simplify the structure for bus and i2c.
prepare to remove the empty bmp180_i2c.c
Drivers: Bosch bmp180, remove bmp180_i2c.c
bmp180: update CMakeList.txt remove bmp180_i2c.c
bmp180: remove unused variable
fixups for complient checks
replace homebrew bitshift with byteorder.h macro
sys_get_be16 and sys_get_be24
cleanup remove unused spi.h
change struct reg16/24 to uint8_t[]
remove channel AMBIENT_TEMP
bmp180/Kconfig add missing help text
fix indent issue in bmp180_pm_action
merge BMP180_CONFIG_I2C into BMP180_INST
Move DT_DRV_COMPAT out of the header file
drop LOG_DBG() from read calibration data
remove bus_io implementation and header cleanup
move headers and structs out from bmp180.h
fix typo in comment
apply clang format changes, only if not line lenght violation
fix indent code error after joined lines
conversion from Pa to kPh was wrong, fixed it
Remove default=n from Kconfig, it is the default.
Move the conversion ready test into a function (duplicate code)
and apply retry policy
parameter naming with indicate the usage
change BMP180_INST(inst) to clang format
fix int32_t overflow in convension formular
fix wrong devider in convension formula
move BSWAP_s16 BSWAP_u16 from .h to .c
Signed-off-by: Chris Ruehl <chris@gtsys.com.hk>
Now that there is an actual Kconfig symbol generated for blobs presence,
take advantage of that and declare appropriate dependencies to it. Also add
helpful CMake output if the blobs are missing by taking advantage of the
zephyr_blobs_verify() CMake function.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
For any module that defines blobs, add a new Kconfig symbol to indicate
whether the blobs have been fetched or not. Example output for the
hal_silabs module:
# (no blobs present)
$ scripts/zephyr_module.py --kconfig-out=/dev/stdout \
-m ../modules/hal/silabs
menu "hal_silabs (../modules/hal/silabs)"
osource "/Users/johedber/src/zephyr/modules/hal/silabs/zephyr/Kconfig"
config ZEPHYR_HAL_SILABS_MODULE
bool
default y
config ZEPHYR_HAL_SILABS_MODULE_BLOBS
bool
endmenu
$ west blobs fetch hal_silabs
# (blob fetching output)
$ scripts/zephyr_module.py --kconfig-out=/dev/stdout \
-m ../modules/hal/silabs
menu "hal_silabs (../modules/hal/silabs)"
osource "/Users/johedber/src/zephyr/modules/hal/silabs/zephyr/Kconfig"
config ZEPHYR_HAL_SILABS_MODULE
bool
default y
select TAINT_BLOBS
config ZEPHYR_HAL_SILABS_MODULE_BLOBS
bool
default y
endmenu
The generated output for modules which do not define blobs is not affected.
Having this additional symbol for blobs lets us specify Kconfig
dependencies for features which require the blobs to be present.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
The size of the rx_buffer used by icmsg.c mbox_callback_process()
is not MISRA compliant, being "dynamically" allocated on the stack.
This commit adds a kconfig to set the size of the read buffer and
asserts that it is large enough to read all received data.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Add a babblesim test for testing the behavior when providing
an invalid broadcast code as the broadcast sink.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
When building proxy client without proxy server, it fails to find
the `identity` field in the `struct bt_mesh_subnet_keys` because the
latter only compiles when Proxy server is enabled. It should be
possible to compile Proxy Client without Proxy server.
This commit compiles the field if any of GATT features is enabled.
Fixes#75914
Signed-off-by: Pavel Vasilyev <pavel.vasilyev@nordicsemi.no>
The BIG info new Framing Mode field was not initialiazed, so
random garbage was being sent to the air in this field.
For the controller this field is still RFU.
The spec specifies RFU fields must be initialiazed to
0. So let's do so to avoid sending invalid data,
and avoid having random data in the air which can cause
random differences in testcases.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This commit changes the default value of CONFIG_HELLO_WORLD_MODE to 'y'
so that the hello_world function is compiled as a built-in part of the
Zephyr image by default. This is the simplest possible configuration,
that works for all architectures.
To build hello_world as an llext module, the user must either follow the
commands in the documentation or set CONFIG_HELLO_WORLD_MODE=m in the
project file along with additional architecture-specific settings that
may be required for proper LLEXT support on the target.
Leave a note in the prj.conf and sample.yaml files to remind the user.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Includes an updated libcrypto with new APIs
for CCM packet encryption/decryption.
Also some other components have got very minor updates.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Update the HW models module to:
da5f426e7f3aff192a93e5874146260d4dcd943e
Including the following:
* 6e70c2d hal: hack: Support also AAR, CCM & ECB for 54L
* da5f426 Tests for AAR, CCM & ECB
* 03b8461 54: Added AAR, CCM & ECB models
* 2ebcc88 Add EVDMA model
* 71913e3 54: Enable AAR hal build
* 0f3a04b BLECrypt_if: Add new interfacing for latest libCrypto
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
The unicast server now prints when a steam enters the streaming
state.
This commit also slightly increases the metadata size to increase
interoperability with other devices such as Android.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The previously added overlay can now be used. Wire up SPI tests for the
Nucleo h745zi-q board.
Signed-off-by: Benedikt Spranger <b.spranger@linutronix.de>
Connect D12(PA6) & D22(PB5) pins on the board to pass the test.
Signed-off-by: Benedikt Spranger <b.spranger@linutronix.de>
Reviewed-by: Vasilij Strassheim <vasilij.strassheim@linutronix.de>
The board is capable to serve SPI on the Arduino extention header.
Configure and enable SPI to work on the extention.
Signed-off-by: Benedikt Spranger <b.spranger@linutronix.de>
The nucleo_h7X3zi overlays use memory attributes and therfore the
dedicated include file. This is unnessesary, since the memory attribute
include is already included from the underlaying CPU base file
"stm32h7.dtsi". Remove the unnessesary includes.
Signed-off-by: Benedikt Spranger <b.spranger@linutronix.de>
Test that SQE's created with `rtio_sqe_prep_callback_no_cqe` run, but
don't create a completion queue event.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Add a helper function that constructs a callback operation that doesn't
generate a completion queue event.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Add Doxygen tooltips in the main documentation.
The tooltips are triggered when hovering over C symbols in the
documentation and display a preview of the Doxygen documentation for the
symbol.
Some shadow DOM magic is needed to style the tooltips correctly, without
affecting the rest of the page.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Every High-Speed capable device must be able to enumerate at Full-Speed.
The functionality at different speeds can be different. Sometimes it is
possible to support exactly the same functionality on both High-Speed
and Full-Speed, but sometimes it is not. The problem is particurarly
relevant for UAC2 because it utilizes isochronous endpoints which means
that the available bandwidth is drastically different between High-Speed
and Full-Speed.
Full-Speed isochronous endpoint can support up to 1023 bytes per frame.
Typical 48 kHz 16-bit stereo stream consumes 48 * 2 * 2 = 192 bytes per
frame. Zephyr UAC2 instances with such streams are fine to work both at
Full-Speed and High-Speed.
An example stream that is too much for Full-Speed is the sometimes used
192 kHz 24-bit stereo (whether or not it is useful is out-of-scope here,
because it should be up to application developer) which would require
192 * 3 * 2 = 1152 bytes per frame.
Because the bandwidth required for audio stream depends on three
different parameters (sample rate, bit resolution and number of
channels), the UAC2 implementation should not automatically limit
available parameters to fit bandwidth requirements.
Adding explicit full-speed and high-speed boolean options to zephyr,uac2
compatible seems to be not only the easiest solution to the problem, but
also the most flexible one. Depending on the use case, the application
developer can then decide for example:
* to not support High-Speed at all - by having one zephyr,uac2 instance
with full-speed property
* to not support Full-Speed at all - by having one zephyr,uac2 instance
with high-speed property
* to support limited number of channels at Full-Speed and all channels
at High-Speed - by having one zephyr,uac2 instance with full-speed
property and separate instance with high-speed property
* to have exactly the same functionality at both speeds - by having one
zephyr,uac2 instance with both full-speed and high-speed properties
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add a composite fuel-gauge device to the Thingy53 to enable converting
the raw voltage to a battery percentage.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Support additional properties from the linux `battery.yaml`.
The `ocv-capacity-table-0` definition differs from the Linux version as
we do not have a good way to generate variable length arrays in our
config structs, or a good way to separate out the percentage vs voltage
in the mapping.
We reduce the flexibility by enforcing a step size of 10%, which removes
the need for the percentage to be in the array and solves the variable
length problem.
To simplify the effort of defining these voltage curves, default curves
for a variety of chemistries have been added, extracted from datasheet
graphs of discharge curves from reputable manufacturers.
Signed-off-by: Jordan Yates <jordan@embeint.com>
- HRS control point was added to server but no write callback is
defined, this causes issues if control point characterstic is
written by the client
Signed-off-by: Anuj Pathak <anuj@croxel.com>
Modify the function "i2s_stm32_set_clock" to handle the case where pclk_len
it is not greater then 1 and to ensure that the freq_in
variable is correctly set in both cases.
Signed-off-by: IBEN EL HADJ MESSAOUD Marwa <marwa.ibenelhadjmessaoud-ext@st.com>
RT1011 expects it's flash configuration block at a different offset than
the rest of the RT10xx series. Add default to fix the platform not
booting.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
I2S driver was merged after interrupt .dtsi was changed,
causing CI to fail. This updates it accordingly.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Extensions could have used logging, when log processing is
deferred, the logging thread can run after the extension has
been unloaded and thereby access invalid memory addresses.
Make sure to flush all logs before unloading extensions.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Zephyr already has various FlexIO drivers but imxrt11xx didn't enable
the base flexio peripheral.
Signed-off-by: Peter van der Perk <peter.vanderperk@nxp.com>
Due to issues with running the watchdog test in a fully
automated manner on the IT8XXX2_EVB, it was previously removed.
However, a fix has now been merged, and it should be operational
on this board once again.
Signed-off-by: Patryk Kuniecki <patryk.kuniecki@intel.com>
Flash partition was defining a scratch area which was implying the use
of mcuboot BOOT_SWAP_USING_SCRATCH f/w update method.
By removing this partition, mcuboot will automatically use
BOOT_PREFER_SWAP_MOVE method which should be prefered as it levels
flash wear. Incidentally increase slot1 by one sector (as this is
preferred for the swap method).
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
1) After the wifi driver successfully connects to the AP,
the dormant state should be set to OFF.
Once a deauth/disassoc frame is received or link lost occurs,
the dormant state should be set to ON.
2) Enable CONFIG_NET_TC_SKIP_FOR_HIGH_PRIO and CONFIG_NET_CONTEXT_PRIORITY
to push high priority packets directly to network driver.
Signed-off-by: Gang Li <gang.li_1@nxp.com>
The STM32H5x adc has a special option register that
needs to be set when using channel 0 on adc1.
fixes: #77618
Signed-off-by: Lars Jeppesen <lje@foss.dk>
The gen_kobject_list.py script expects the __subystem declaration to end
with _driver_api. Adjust the stepper api and existing driver implementation
accordingly.
Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
Update the EDTT module to:
b9ca3c7030518f07b7937dacf970d37a47865a76
Including the following:
* b9ca3c7 Fix for for python >= 3.11
* fe9b1d1 Corrected ISO interval for LL/CIS/PER/BV-05-C
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Some hardware configuration require rely on the ALERT/RDY
pin to know when and ADC conversion is completed.
The polling thread is left as fallback, when the pin
is not defined.
Signed-off-by: Efrain Calderon <efrain.calderon.estrada@gmail.com>
Add a new macro, DT_ANY_COMPAT_HAS_PROP_STATUS_OKAY
name, evaluates to 1 if any enabled instance of `compat` has the
property or to zero if it hasn't.
This macro can be useful in drivers for a family of devices.
Signed-off-by: Efrain Calderon <efrain.calderon.estrada@gmail.com>
This example demonstrates I2S audio playback combined with the codec
API. It can use the dmic API for audio input.
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Vit Stanicek <vit.stanicek@nxp.com>
Add Flexcomm signal sharing configuration for the mimxrt595s/cm33 and
mimxrt685s/cm33 SoCs. Properly instantiate the I3C peripheral for
interfacing with the WM8904's control port. Modify pinctrl DTs of
mimxrt595_evk/mimxrt595s/cm33 and mimxrt685_evk/mimxrt685s/cm33.
Instantiate the WM8904 codec for said boards.
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Yves Vandervennet <yves.vandervennet@nxp.com>
Signed-off-by: Vit Stanicek <vit.stanicek@nxp.com>
Add clock config for Flexcomm peripherals functioning as I2S interfaces.
Add MCLK clock config for the WM8904 codec located on the mimxrt595_evk
and mimxrt685_evk boards.
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Yves Vandervennet <yves.vandervennet@nxp.com>
Signed-off-by: Vit Stanicek <vit.stanicek@nxp.com>
Add sample rates. Add dai_route_t enum to allow codec configuration for
duplex operation. Allow for audio inputs to be controlled. Add functions
for signal routing.
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
Signed-off-by: Vit Stanicek <vit.stanicek@nxp.com>
Enable DMIC clock in soc.c - attach to chip's audio PLL. Add pinmux
definitions for the DMIC peripheral. Add nodes to SoC's device tree for
the DMIC peripheral and its audio channels. Configure the DMIC
peripheral in board's device tree to enable audio capture.
Signed-off-by: Vit Stanicek <vit.stanicek@nxp.com>
Commit consists of minimal set of overlays need to run tests
and samples. Additionally disables nRF54L15 platform in cpp98
tests, because unnamed unions are not supported.
Signed-off-by: Karol Lasończyk <karol.lasonczyk@nordicsemi.no>
timeutil internally uses 1900 as base year for calculation,
that is hidden from caller context. Thus declared a macro in
the public header file, and uses that macro will let caller adjust the
calulations accordingly.
Signed-off-by: Anuj Pathak <anuj@croxel.com>
find the headset which a2dp related record len is SEQ32,
fix sdp_client_get_total too because it doesn't handle
SEQ32 too.
Signed-off-by: Mark Wang <yichang.wang@nxp.com>
As the .bin & .hex build output is optional
and it can be disabled by CONFIG_BUILD_OUTPUT_BIN/HEX,
add support for the mandatory .elf build output
to the linkserver runner flash command.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
Following addition of a `name` to hal_stm32 module, the command to fetch
blobs that are required to build BLE applications on STM32WBA socs is now
changed from `west blob fetch stm32` to `west blob fetch hal_stm32`.
Update documentation and warn users in migration guide.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
Added volume offset for CAP commander
Added gain settings for CAP commander
Added play, pause and seeking for MCS
Added program_info and metadata update for PBP
Added long read and notify for all TBS characteristics
Added TMAP CG
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
For mapping operations in sys_mm_drv_simple_map_region() and
sys_mm_drv_simple_map_array(), when there was an error with
mapping any pages, it would simple return an error, leaving
already mapped pages still mapped. This modifies the behavior
where any failure during the whole mapping operation will
unmap the already mapped pages.
This also modifies the remapping and moving functions to
reset mappings when error is encountered.
Fixes#73121
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
If a diff only has added or removed lines we need to match both '-' and '+'
characters in the hunk context.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Adds the use of generic touch reporting method for stmpe811 driver.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Adds the use of generic touch reporting method for ft5336 driver.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Adds a way of reporting touchscreen events
taking common properties into account.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Adds common properties for touchscreen controllers.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
This transforms the existing driver for the Microchip MCP9808
to be used as a generic driver to be used with all
JEDEC JC 42.4 compliant temperature sensor chips.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
Caught by CI in another PR, should be 'Unsupported' instead.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Added entries in the release note & migration guide about the
changes to the `kernel thread` shell command.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Added commands to access the APIs in the kernel/cpu_mask.c
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Use `shell_strtoull()` to parse the thread ID argument for
error checking.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
`stacks` `threads` & `unwind` are commands related to kernel
thread, group them one level inside a main `thread` command,
and rename `threads` to `list`:
- `kernel threads` -> `kernel thread list`
- `kernel stacks` -> `kernel thread stacks`
- `kernel unwind` -> `kernel thread unwind`
Additionally, rename and mark the `thread_valid()` function
as `__maybe_unused` as it might be unused for architectures
without stackwalk implementation, and use the locked version
of the thread iterator (`k_thread_foreach()`)
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The "channels-num" should not be used here, other system's parts are using
"channel-count" instead for the same purpose.
Also property's description has been сorrected.
Signed-off-by: Andrey VOLKOV <andrey.volkov@munic.io>
These boards support Bluetooth, so it should be listed under "supported".
There's also no (known) good reason to explicitly skip "net" tags, so
remove that from the ignore_tags list as well. We don't particularly know
or care about relevant net tests for these boards, so "net" is left out for
now from the "supported" list.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
These boards don't currently have the necessary binary blobs available
for Bluetooth, so keep their Bluetooth HCI DT node disabled.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
Add overrun count in statistics. It will represent
the number of packets dropped either at received and
sent due to lack of buffer memory.
Signed-off-by: Kapil Bhatt <kapil.bhatt@nordicsemi.no>
Remove water mark configuration and handle its interrupt
instead, since it is only present in ESP32S3.
Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
since h750 and h743 have the same irq wkup priority,
we can add wkup interrupt in h743.dsti and simply
include the file in h750.dtsi.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Increase wifi connect input parameters max count to 13. Previous count
7 is not enough if other security type is supported.
When enabling softAP, the parameter cnx_params in cmd_wifi_ap_enable()
is with static key word. Then the parameter will always save
configurations of last time. Remove static keyword to eliminate effects
of configs from last tim and do memset before setting up softAP.
Signed-off-by: Hui Bai <hui.bai@nxp.com>
Link mode shows unknown when legacy (A or bg only) device connects to
APUT. Set the link mode to WIFI_2 when the host freq over 4000 and set
link mode to WIFI_3 when the host freq over 2000.
Signed-off-by: Hui Bai <hui.bai@nxp.com>
Increase max count of CONFIG_WIFI_SHELL_MAX_AP_STA from 5 to 8. The
SoftAP of NXP wifi chip can support up to 8 stations.
Signed-off-by: Hui Bai <hui.bai@nxp.com>
Added new flag CONFIG_WIFI_NM_HOSTAPD_AP for hostapd support. Once this
flag is enabled, softAP will be setup by hostapd. Both wpa_supplicant
and hostapd uses same task and eloop.
Included necessary hostapd files when compiling wifi samples if
CONFIG_WIFI_NM_HOSTAPD_AP is enabled. Added hostapd support for all
softAP command of L2 wifi shell commands.
Signed-off-by: Hui Bai <hui.bai@nxp.com>
When omitting the clk_src definition in a child node of a pclkblock,
it uses the source of the parent node.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Allows MSTP register addresses to be changed in the device tree
to support different configuration SoCs.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Add support for HSE as the RTC clock source.
The initial implementation has the following limitations:
- Only whole MHz HSE frequency is supported, e.g. 24.5 MHz will generate a
compile error.
- Frequencies equal or above 64 MHz are not supported and will generate a
compile error.
The implementation has been tested on nucleo_h563zi with:
- 8 MHz (via hse-bypass)
- 25 MHz (via external crystal)
Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
pwm: pwm_api: update testcase.yaml and add new overlay configuration
to support flexio pwm driver.
spi: spi_loopback: update testcase.yaml and add new overlay
configuration to support flexio spi driver.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
After testing the flexio spi_loopback on the ke1xz platform,
it is found that the master transfer and receive are not
synchronized. So add loop code to wait for the master transfer
to complete for frdm_ke17z and frdm_ke17z512 platforms.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
This adds the bits to test the displaying the usage of
privileged stacks for user threads. Note that this only
adds the printk part as this is to test the code path to
fetch usage data rather than the display part.
Also add qemu_xtensa/dc233c/mmu to platform allow list so
the privileged stack code can be tested on that platform.
This replaces mps2/an385 with qemu_x86 as an integration
platform due to the privileged stack test. Since ARM does
not currently support getting privileged stack info, test
would result in twister error due to kconfig warnings.
The board cannot be excluded since it's an integration
platform. So for now, use qemu_x86 as an integration for
32-bit testing. Once ARM has proper support, we can go
back to having mps2/an385 as an integration platform.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This disables QEMU icount for all the simulated platforms
in the allowed list. With icount enabled, the printout from
the thread analyzer would be continuous and non-stop instead
of the default once every 60 seconds. Besides, the console
harness only needs one, and these is no need to waste CPU
cycles and memory for processing the extra ones.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This implements arch_thread_priv_stack_space_get() so this can
be used to figure out how much privileged stack space is used.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds the bits to initialize the privileged stack when
a thread is transitioning to user mode. This prevents
information leaking if the stack is reused, and also aids
in calculating stack space usage during system calls.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This implements arch_thread_priv_stack_space_get() so this can
be used to figure out how much privileged stack space is used.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds the bits to initialize the privileged stack for
each thread during thread initialization. This prevents
information leaking if the thread stack is reused, and
also aids in calculating stack space usage during system
calls.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This implements arch_thread_priv_stack_space_get() so this can
be used to figure out how much privileged stack space is used.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds the bits to initialize the privileged stack for
each thread during thread initialization. This prevents
information leaking if the thread stack is reused, and
also aids in calculating stack space usage during system
calls.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Only set the privileged stack pointer for thread stacks, but
nullify the pointer for kernel-only stacks, as these stacks
do not have the reserved space. The psp pointer may point to
arbitrary memory in this case if stack is not big enough.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds the bits to display privileged stack usage for
architectures that support obtaining this information.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The per-thread output after the first stack usage line is not
aligned which makes it harder to decipher the content.
So align them for easier reading.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This adds a new arch_thread_priv_stack_space_get() interface for
each architecture to report privileged stack space usage. Each
architecture will need to implement this function as each arch
has their own way of defining privileged stacks.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
IPPROTO_IPV6 option was set on TCP socket (besides doing it already in
tcp.c) instead of UDP. Fix that.
Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
Use correct output for the changed-files action so that bsim tests are
also run on deleted files, no just added/copied/modified/renamed
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Use correct output for the changed-files action so that docs
is built in CI when relevant files are *deleted* too, not just
added/renamed/modified
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Adds the default MCUboot operating mode when building using sysbuild.
Fix mcuboot sysbuild for frdm_mcxn947.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
Currently, if the user wants to allocate heap on external RAM
he needs to enable CONFIG_ESP_SPIRAM and set a threshold defined
with CONFIG_ESP_HEAP_MIN_EXTRAM_THRESHOLD.
This approach requires that we re-implement `k_malloc` and allocate
the memory on the proper region based on the block size.
By using the shared multi heap feature the proccess of allocating
memory from external memory becomes more fluent and simple.
The attribute SMH_REG_ATTR_EXTERNAL was added to reference the
external memory.
Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
Update `shell_backend_uart` to take into account the new line print by
`z_cursor_next_line_move`.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
When the shell start, it will print two lines. The reason for that
behavior is not documented. Remove that to make the code simpler and
shorter one line at a time.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
The fact that the function was returning `true` for empty line was an
unexpected behavior according to the name of the function itself and how
it was used elsewhere.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
Follow ARM architecture recommendations:
* Use Data Synchronization Barrier (DSB) instruction before WFI,
to ensure that pending memory transactions complete before
changing state.
* To guarantee pend interrupts are recognized before subsequent
operation, use ISB after CPSIE (__irq_enable)
This prevents sporadicy delayed ISRs due to continous MEC172x
entering/exiting deep sleep.
Signed-off-by: Jose Alberto Meza <jose.a.meza.arellano@intel.com>
Instead of using filter (which is expensive in terms of CI as
it needs to run cmake on everything to get the full kconfigs
before filtering can be done), change that to a curated list
of allowed platforms. This avoids the expensive filtering
operation, yet can still run on some emulated platforms to
verify the dictionary output.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Adds support for setting the operating mode of the TMP116/7 sensor to
either shutdown, continuous conversion or one-shot mode.
Signed-off-by: Ian Morris <ian.d.morris@outlook.com>
Before commit baa70d8d36 ("arch/arm64/mmu: fix page table reference
counting part 2") it was possible to perform a partial unmap of a block
mapping. Restore that ability and provide a test case to validate it.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Resend CMD0 before each CMD8 query while initialising the card, as the
first CMD0 is not always sufficient to recover the card.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Since testing.c/h was moved to mesh, all functions and
structs in those files now follow a bt_mesh_test_*
naming scheme to be consistent with the naming in Zephyr.
Due to missing includes in many files, this commit also
added some that were missing in order to build since
the order of includes have changed.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The file is only ever used by mesh and it is even stated in the
header of the file that it is internal APIs.
The include file has been merged with the host testing.h file
as that was mesh specific as well. Similarly the testing.c
file was also moved
This is part of a process to clean up the file structure of
Bluetooth as it's a bit messy, which is evident from the
MAINTAINERS.yml file.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Re-arrange Twister command line options for test plan reporting
to a dedicated group with mutally-exclusive options to reflect
actual implementation and its dry-run execution mode.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Describe the samples using code-sample directive in preparation for
upcoming changes to the Zephyr documentation that will be leveraging
the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Describe the samples using code-sample directive in preparation for
upcoming changes to the Zephyr documentation that will be leveraging
the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Describe the samples using code-sample directive in preparation for
upcoming changes to the Zephyr documentation that will be leveraging
the provided description and metadata.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Drop support for Google Kukui EC board which was used for
early Zephyr experiments but doesn't really exist anymore.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Re-run issue check when a PR is updated, i.e. when someone adds
'Fixes...` to the PR body.
This is mostly for release branches and has no effect on main branch.
Also, add concurrency check in the workflow.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
There appear error on `ZBUS_CHAN_DEFINE` when `CONFIG_CPP`
is enabled. Error: `zephyr/zbus/zbus.h:352:9: error: designator
order for field 'zbus_channel_data::highest_observer_priority'
does not match declaration order in `zbus_channel_data`.
Solution: change order in `ZBUS_CHAN_DEFINE` macro according
to zbus_channel_data structure.
Signed-off-by: Mariusz Dziębowski <mdziebowski@meden.com.pl>
- Allow setting polarity from DT.
- At least on bcf, going from 0 to 255 causes brightness to decrease
(although 0 is still off and 255 is still on).
- Seems to work as expcted by using TnPWML register.
Signed-off-by: Ayush Singh <ayush@beagleboard.org>
TX/RX FIFO underrun shouldn't crash the RTOS when it occurs.
Also, since this can also happen under "normal" conditions
(i.e: DMA doesn't copy data fast enough from/to SAI's FIFOs)
the software should be able to recover from it.
As such:
1) Remove `z_irq_spurious()` call.
2) Clear error flag
3) De-escalate error message to warning message
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
This commit rebrands the STM32 EXTI API to a more hardware-agnostic
"GPIO interrupt controller" API, in anticipation of the introduction of
new series lacking the EXTI peripheral. The GPIO and EXTI drivers are
updated to match the rebranded API.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
This commit makes the contents of the stm32_exti_line_t data type opaque to
the EXTI GPIO interrupt controller API users. The GPIO driver is updated
to comply with this API change.
N.B.: while some assertions are removed as part of this commit, they were
broken since forever anyways, so nothing of value is lost.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Move the functions that interact with EXTI configuration registers to
select or get the GPIO port that triggers events on a given EXTI line
to the EXTI driver.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Modify all functions in the GPIO driver that interact with the EXTI
so that names, signatures and comments match what they do better.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Use the `gpio_pin_t` type for all variables that hold a pin number (0..15).
Change all `int` to `uint32_t` instead, as signedness is unwanted.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
This commit reorders the functions in the EXTI driver.
Internal functions and exported functions are now grouped with each other.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
This commit changes the EXTI driver API to use unsigned types
for all parameters previously typed as `int`, as the signedness
is unneeded and unwanted.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
All assertions performed in the EXTI drivers were wrong, as they passed
values to __ASSERT_NO_MSG instead of predicates. Update all assertions
to be actually useful.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
The EXTI driver API defined in exti_stm32.h is reserved for exclusive usage
by the STM32 GPIO driver, which doesn't use this macro. Since there is no
usecase for it anyways, it can be removed for future-proofing.
The STM32 UART driver is an unintended user of this definition, however.
Replace it with a private #define which is more appropriate anyways.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Update check_compliance to handle auto defined ZEPHYR_<name>_MODULE
Kconfig symbols.
check_compliance runs three levels of Kconfig check.
A basic and a full, both which uses the generated Kconfig.modules
created according to Zephyr modules present.
A Kconfig check where no Zephyr modules are sourced. This check ensures
that Zephyr Kconfig tree doesn't refer to Kconfig symbols defined in
Zephyr module's local Kconfig trees.
However, there are a few auto generated symbols which are allowed,
such as: `ZEPHYR_<name>_MODULE` and `ZEPHYR_<name>_MODULE_BLOBS`.
Therefore, when testing no blobs, filter the generated Kconfig.modules
file, so that no sourcing of extra Kconfig files are performed but
lines defining `ZEPHYR_<name>_MODULE` and `ZEPHYR_<name>_MODULE_BLOBS`
are preserved.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
apollo3 driver added PM to UART for only apollo3
but defined PM function for both causing an error
in twister
Signed-off-by: Richard Wheatley <richard.wheatley@ambiq.com>
In RISCV "sepc" is actually the name of an instruction.
As this prevents building. We should remove the line.
Signed-off-by: Sven Ginka <s.ginka@sensry.de>
This commit excludes the `m2gl025_miv` platform from running the
`kernel.common.stack_sentinel` test. It experiences the same issue as
`hifive1`, which was described in issue #66070.
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
Automatically handle device runtime PM for all flash API calls.
Asynchronously release the device after a small delay to minimise power
state transitions under multiple sequential API calls (e.g. NVS).
Signed-off-by: Jordan Yates <jordan@embeint.com>
Remove `SPI_NOR_IDLE_IN_DPD` to simplify the possible transition states
in the `spi_nor` driver. This option was originally added 5 years ago
when device runtime PM was in a much less mature state.
I do not believe having a separate power management implementation for
this one in-tree driver is in the interests of the project.
The behaviour of `SPI_NOR_IDLE_IN_DPD` leads to extremly suboptimal
behaviour in use cases where multiple small reads are performed
sequentially, see #69588.
Removal of this option does not break the behaviour of any existing
applications, only increases current consumption in idle by ~10uA until
device runtime PM is enabled.
Signed-off-by: Jordan Yates <jordan@embeint.com>
When change unaware client send ATT request it shall get Database
Out of Sync error. Reading GATT database hash is an exception here.
This was affecting GATT/SR/GAS/BV-05-C qualification test case.
Signed-off-by: Szymon Janc <szymon.janc@codecoup.pl>
Background of this modification is to make clock control
driver code provided by Renesas vendor to support for Renesas MCU
on Zephyr.
Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
A 16-bit value built using byte shifts and ORs from a given
couple of lsb and msb bytes will result to be the same on both
little-endian and big-endian architectures, e.g.
uint8_t lsb, msb;
int16_t val;
/* val is the same number on both le and be archs, but has
different layout in memory */
val = (msb << 8) | lsb;
All the xyz_raw_get() APIs of stmemsc sensor module build the sensor
data using the above method and DO NOT hence require (it actually leads
to wrong values on big-endian machines) to use any le/be swap routines,
such as sys_le16_to_cpu().
Fix#75758
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Updated the counter_mcux_lptmr driver to support multiple
instances of the lptmr peripheral. Also added a new
binding property to identify if the user is using
counter-mode or pulse mode. since we were previously using the
prescaler value to check this which could be wrong
if used as a division value for getting the freq.
Added a property that allows the user to decide
what the counter value in lptmr should be divided by.
Cleaned up INIT macro for lptmr.
Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
dts: arm: nxp: mimxrt1180_evk: add GPT1/2 instance into devicetree
Enable GPT1/2 clock
Add GPT1/GPT2 instances
Set GPT2 as a counter, the default frequency is 240000000
Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
The reset function uses uint32_t as its 2nd parameter, which leads to the
following compiler warning.
zephyr/drivers/mipi_dbi/mipi_dbi_stm32_fmc.c:176:18: warning:
initialization of 'int (*)(const struct device *, k_timeout_t)' from
incompatible pointer type 'int (*)(const struct device *, uint32_t)'
{aka 'int (*)(const struct device *, unsigned int)'}
[-Wincompatible-pointer-types]
176 | .reset = mipi_dbi_stm32_fmc_reset,
| ^~~~~~~~~~~~~~~~~~~~~~~~
When you look at similar drivers,
/drivers/mipi_dbi/mipi_dbi_smartbond.c#L126
/drivers/mipi_dbi/mipi_dbi_nxp_lcdic.c#L561
you notice they use k_timeout_t.
So the whole fix is to correct the type.
Signed-off-by: Thorsten Spätling <thorsten.spaetling@vierling.de>
Round up buffer size used in UDC_BUF_POOL_DEFINE() to respect the
required buffer granularity. The issue was observed with UAC2 explicit
feedback data, but the problem applies to any UDC_BUF_POOL_DEFINE() use.
In order for every buffer returned by UDC_BUF_POOL_DEFINE() to be both
aligned and to have required granurality, it is required to allocate the
buffers for ROUND_UP(size, LCM(UDC_BUF_GRANULARITY, UDC_BUF_ALIGN)).
Because we do not have Least Common Multiple nor Greatest Common Divisor
compile time macros, assume that granularity is multiple of alignment.
Validate the assumption with a build time assert. When we get a target
where this assumption fails we would have to come up with a solution to
compute LCM and/or GCD at compile time.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Remove the early max packet size check on endpoint activation, because
there are valid use cases where the max packet size is not multiple of 4
and the stack won't perform multi-transaction transfers. Example use
case is UAC2 explicit feedback endpoint that has Max Packet Size equal
3 when device is operating at Full-Speed.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Fail TxFIFO write if the endpoint is not activated, because there is
essentially no fifo assigned. Writing to not activated endpoint is
possible, but it does tend to corrupt fifo number 0 which is used for
control transfers. USB stack should not really be attempting to write to
endpoints that have not been activated (ep_enable called).
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Store SOF frame number and use the information to set the Even/Odd
microframe bit when enabling isochronous endpoints. Reject received
isochronous data if number of packets received does not align with
received PID.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
RxFLvl interrupt should only handle the actual data movement from RxFIFO
to the buffer. OUT transfers are completed in XferCompl handler both in
DMA and Completer mode. This reduces code size by avoiding having
separate code paths based on operating mode.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Function dwc2_set_dedicated_fifo() calls dwc2_flush_tx_fifo() before the
diepctl register is written. The register will be only written after the
dwc2_set_dedicated_fifo() finishes. Solve the problem by passing fifo
number directly instead of endpoint address to dwc2_flush_tx_fifo().
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add all register bit defines necessary for isochronous transfers. Clean
up the endpoint transfer size register defines clearly separating IN and
OUT registers because they do use different bit fields. Add alternate
bit names for bits that do have different meaning based on configured
endpoint transfer type.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
The clang-format check outputs a git diff with surrounding context. It
naively removed the first and last 3 lines, but this does not work if
there are less lines.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
As the .bin & .hex build output is optional
and it can be disabled by CONFIG_BUILD_OUTPUT_BIN/HEX,
add support for the mandatory .elf build output
to the pyocd runner flash command.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
The terminal offset for subcommands' help text isn't
computed correctly, fix it.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
- Use `SHELL_CMD_ARG_REGISTER` for the main cmd to state the
required number of arguments, this helps to remove the
runtime check from the command, and also print the help
message to the terminal when the argument count is
unexpected.
- Some changes to the help text that hopefully makes the
mandatory and optional arguments more obvious to the user
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Reset delay was not being calculated correctly in lcdic driver, the
ticks field needs to be accessed directly within the timeout structure
to calculate the correct delay time
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Exclude RW612 based boards from the WiFi testsuite, as these boards
require binary blobs be downloaded in order to build as expected
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Adds unittests for the CAP Initiator start procedure, simply
verifying that the procedure works as well as
testing invalid parameters.
This also allows us to remove the invalid behavior checks
from the babblesim test implementation.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The driver in tree is for u-blox M8 devices, not M10. The M10 series
devices (from Protocol Version 23.01) use a different, non backwards
compatible interface for configuring the modem behaviour.
Of the two boards tested in the original PR, the "VMU RT1170" is
explicitly listed as having a u-blox NEO-M8N modem, while I have
been unable to find any information online about the "FMURT6" board.
Leaving the naming as-is will cause problems when M10 drivers are
contributed.
Signed-off-by: Jordan Yates <jordan@embeint.com>
disk_access functions were called from an interupt context, thus
crashing on mutexes (no sleep is allowed in interrupt context).
The usage of a spinlock is permitted. The functions guarded by
the spinlock are executed very quickly anyway, so the spinlock
is applicable.
Signed-off-by: Alexi Demers <alexi.demers@axceta.com>
Usb "write" method never copies the input data buffer, it uses the
buffer pointer directly. The fact that it was on the stack made
the buffer ephemeral, and could disappear before the USB transfer
actually occurred. The data transmitted was then random. This commit
converts the transfer buffer to a static buffer, so that it always
exists for the duration of the USB transfer.
Known side-effect: if "read capacity" command is read twice
simultaneously, the same buffer will be used twice. As the capacity of a
USB drive should not change between 2 calls, this side effect can be
ignored.
Signed-off-by: Alexi Demers <alexi.demers@axceta.com>
This provides memory mappings with the ability to be initialized in their
paged-out state and be paged in on demand. This is especially nice for
anonymous memory mappings as they no longer have to allocate all memory
at mem_map time. This also allows for file mappings to be implemented by
simply providing backing store location tokens.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
- Removed zero initialization of `pincfg` structure as all members
are guaranteed to be set.
- Introduced `pfs_cfg` as an intermediate variable to store data in
the CPU register instead of stack.
- Simplified pin setting logic by relying on `pfs_cfg` being
zero-initialized, eliminating the need for explicit bit clearing.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add power management support to various drivers:
- gpio-kbd-matrix
- ite,it8xxx2-kbd
- nuvoton,npcx-kbd
- microchip,xec-kbd
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Add power management support to the keyboard matrix library. This
provides a generic pm_action function that changes the keyboard matrix
scan in two places when suspended:
- reset the state to 0 for all columns
- do not enable key press detection
This ensures that any key that was pressed when the device is suspended
is released, and no other scan happens until the device is resumed.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
The latency_measure benchmark is designed for systems with a single
CPU. When the system allows for multiple CPUs, instead of forcing
a single CPU to be used via 'prj.conf', spawn a non-preemptible
thread to keep the other CPUs busy.
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
Update changes about `arch_stack_walk()` in RISCV, ARM64 & X86.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Having `CONFIG_EXCEPTION_STACK_TRACE_SYMTAB` to select the
`CONFIG_SYMTAB` or to explicitly not print the symbol name
during exception stack unwind seems unnecessary, as the extra
code to print the symbol name is negligible when compared with
the symbol table, so just remove it.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Currently it supports `esf` based unwinding only.
Then, update the exception stack unwinding to use
`arch_stack_walk()`, and update the Kconfigs & testcase
accordingly.
Also, `EXCEPTION_STACK_TRACE_MAX_FRAMES` is unused and
made redundant after this change, so remove it.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Currently it supports `esf` based unwinding only.
Then, update the exception stack unwinding to use
`arch_stack_walk()`, and update the Kconfigs & testcase
accordingly.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
This commit introduces a new ARCH_STACKWALK Kconfig which
determines if the `arch_stack_walk()` is available should the
arch supports it.
Starting from RISCV, this will be able to converge the exception
stack trace implementation & stack walking features. Existing
exception stack trace implementation will be updated later.
Eventually we will end up with the following:
1. If an arch implements `arch_stack_walk()`
`ARCH_HAS_STACKWALK` should be selected.
2. If the above is enabled, `ARCH_SUPPORTS_STACKWALK` indicates
if the dependencies are met for arch to enable stack walking.
This Kconfig replaces `<arch>_EXCEPTION_STACK_TRACE`
2. If the above is enabled, then, `ARCH_STACKWALK` determines
if `arch_stack_walk()` should be compiled.
3. `EXCEPTION_STACK_TRACE` should build on top of the
`ARCH_STACKWALK`, stack traces will be printed when it
is enabled.
4. `ARCH_STACKWALK_MAX_FRAMES` will be removed as it is
replaced by `ARCH_STACKWALK_MAX_FRAMES`
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Add `arch_stack_walk()` under the `arch-interface` group and
add documentation on how to add support for it.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Fix missing implementation to handle Broadcast ISO MIC
failure during Broadcast ISO establishment, and during an
already established Broadcast ISO sync.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Adding myself as maintainer because my employer Husqvarna wants to
upstream SiM3U support to Zephyr, and keep it well-supported.
Adding as collaborator M1cha, because he did the initial port and
Asmellby, jerome-pouiller, and jhedberg because they take care of
all Silabs products.
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
This is just the driver for banks 0 to 3. Bank 4 will come via a
separate commit since it needs a different driver.
Signed-off-by: Michael Zimmermann <michael.zimmermann@grandcentrix.net>
This serves two main purposes:
- change the CPU clock via devicetree nodes
- provide the APB frequency to device drivers via the clock driver
interface
Theoretically this could also support choosing between the available
clock sources, but right now we only support LPOSC0 going into PLL0,
going into AHB.
Turning the PLL back off is also not supported since the only current
use case is to set the PLL frequency, turn it on, and switch the AHB
over to it.
Signed-off-by: Michael Zimmermann <michael.zimmermann@grandcentrix.net>
This is the bare minimum and includes the SoC, pinctrl, flash and
devicetree.
I had to include the flash driver that early because I couldn't make
Zephyr compile without flash driver nodes in the device tree.
Signed-off-by: Michael Zimmermann <michael.zimmermann@grandcentrix.net>
Can be used only once the SiM3U SoC support has been added.
Developed-by: Michael Zimmermann
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
For applications that rely on low noise/variance in accelerometer
sample reading. Application can take advantage of integrated LPF
Thus this PR adds LPF configuration capability to the mc3419 driver
Signed-off-by: Anuj Pathak <anuj@croxel.com>
Very very weird behavior.
Deleting the `options & BT_LE_ADV_OPT_USE_NRPA` branch in
`id.c:bt_id_set_adv_own_addr` makes the test pass. But add a log in that
branch, and you'll see that we never take it in the UT binary..
I don't have time for this, maybe some compiler guru or C language
lawyer can look at that decompiled function and figure out the root
cause.
Someone should also really fix the Bluetooth unit tests and make them
run on any Bluetooth related PR. Also nightly.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
We want to make sure `struct closure` fits in the user data, so a user data
size of `sizeof(struct closure)` is valid.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
Reuse the file clock_stm32g0.c for the STM32U0 and
rename it to clock_stm32g0_u0.c
because the G0 and U0 series share the same clock control.
Signed-off-by: IBEN EL HADJ MESSAOUD Marwa <marwa.ibenelhadjmessaoud-ext@st.com>
The sample illustates how to achieve bidirectional asynchronous audio.
Implicit feedback is the only way to achieve asynchronous USB headset
on devices that have only one isochronous IN and one isochronous OUT
endpoint.
The sample implements stereo playback and mono recording. While it would
be possible to have stereo recording, the commonly available headsets
are mono only. The number of channels can differ between audio sink and
source because the only requirement is that the two run on same clock.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Move negative tests for flash driver to a separate test suite.
Run negative tests only on platforms that are aligned.
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
This commit addresses an issue in net_context_bind() where unaligned
memory access was not properly handled when checking for INADDR_ANY.
The problem primarily affected MCUs like ARMv6 that don't support
unaligned memory access.
- Use UNALIGNED_GET() to safely access the sin_addr.s_addr field
- Ensures correct behavior on architectures with alignment restrictions
This fix improves compatibility and prevents potential crashes or
unexpected behavior on affected platforms.
Signed-off-by: Daekeun Kang <dkkang@huconn.com>
If we receive incoming neighbor solicitation packet and drop
it for some reason, ignore some of the errors which are not
really errors so that the icmpv6 handler does not complain.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Make sure that incoming DAD NS message is allowed in
so that we can detect duplicate address detection NS packets.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
To specify the serial number, JLink expects either one argument
('--dev-id=xxx') or two (e.g. '--dev-id' 'xxx'), but it can not deal
with a single one that is '--dev-id xxx'.
The problem has been introduced (or just made visible?) by commit
5ee4284320 (twister: runner: j-link: use
dev-id instead of SelectEmuBySN) in PR #76931.
How to reproduce:
1. Create a HW configuration map, e.g.:
```
$ cat zephyr-hw-map-nrf52840dk-1.yml
- connected: true
id: '683517317'
platform: nrf52840dk/nrf52840
product: nRF52840 DK 1
runner: jlink
serial: /dev/ttyACM-nrf-dk-1
```
2. Run test `logging.dictionary` with Twister:
```
$ west twister --platform nrf52840dk/nrf52840 --device-testing \
--hardware-map zephyr-hw-map-nrf52840dk-1.yml -s logging.dictionary
```
3. The build will fail, and the `twister_harness.log` contains:
```
10:21:24.375:DEBUG:twister_harness.device.factory: Get device type
"hardware"
10:21:24.375:DEBUG:twister_harness.device.hardware_adapter: Opening
serial connection for /dev/ttyACM-nrf-dk-1
10:21:24.376:DEBUG:twister_harness.device.hardware_adapter: Flashing
device 683517317
10:21:24.376:DEBUG:twister_harness.device.hardware_adapter: Flashing
command: <snip>/bin/west flash --skip-rebuild --build-dir
twister-out/<snip>/tests/subsys/logging/dictionary/logging.dictionary
--runner jlink '--dev-id 683517317'
10:21:24.590:ERROR:twister_harness.device.hardware_adapter: Could not
flash device 683517317
10:21:24.592:DEBUG:twister_harness.device.hardware_adapter: Closed
serial connection for /dev/ttyACM-nrf-dk-1
```
(note the '--dev-id 683517317' part)
4. Running the stated `west flash` command shows the following error
message:
```
-- west flash: using runner jlink
FATAL ERROR: runner jlink received unknown arguments: ['--dev-id
683517317']
```
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Ensure initial search menu visibility is properly set so that key
events don't get trapped preventing arrow key navigation on the
document.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Net capturing would not link when either IPv6 or IPv4 was switched off
due to missing symbols. This change allows for capturing a single IP
protocol only.
To reproduce:
samples/net/sockets/http_client/prj.conf
```
-CONFIG_NET_IPV4=y
+CONFIG_NET_IPV4=n
-CONFIG_NET_CONFIG_NEED_IPV4=y
+CONFIG_NET_CONFIG_NEED_IPV4=n
+
+CONFIG_NET_CAPTURE=y
```
This will cause the following linker error:
```
.../subsys/net/lib/capture/capture.c:648:
undefined reference to `net_if_ipv4_get_ttl'
```
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
Improved debuggability of IEEE 802.15.4 network management commands.
Some of these conditions were especially hard to debug (e.g. invalid
channels due to the wrong driver being selected, conflict between
settings, ...)
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
Low throughput links (e.g. IEEE 802.15.4) require additional stack and
buffering resources. Therefore some stack and buffer pool sizes were
increased to cater for over-the-air scenarios.
Fixes: #77287
Signed-off-by: Florian Grandel <fgrandel@code-for-humans.de>
SOF is designed with the idea that the data transfer
between the host memory and local memory is performed via
DMA. This is not true for imx platform in which the DSP
performs this operation.
Because of the aforementioned design, SOF performs a
cache invalidation operation on the destination memory
region before data is copied further down the pipeline.
For some imx platforms, the destination memory region is
cacheable. As such, some of the data transferred from the
host memory region is held entirely in cache, which means
the RAM and the cache have different data for the same
memory region.
In such cases, performing cache invalidation forces
the DSP to fetch data from RAM instead of the cache, which
means the DSP will read stale data and propagate it further
down the pipeline.
Although not optimal and mostly as a workaround to this issue,
perform a cache WB operation on the destination memory region
to make sure that the cache and the RAM hold the same data.
During the data read operation (to copy it further down the
pipeline) after the aforemention cache invalidation, the DSP
will no longer end up reading stale data.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
When CONFIG_RISCV_VECTORED_MODE is disabled, CLIC claims interrupts using
CSR 'mnxti' and handles all pending interrupts before exiting the ISR.
When CONFIG_RISCV_VECTORED_MODE is enabled, all interrupts use vector mode
and are claimed automatically. The RISC-V common ISR is used for interrupts
hooked into SW ISR table, but it only handle one pending interrupt per ISR.
This commit enhances CLIC to set vector mode for direct ISRs only and use
the CLIC common entry for regular ISRs to handles multiple pending
interrupts in an ISR.
Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
- 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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
Fixes division by zero exception when SPI is configured to operate in mode3
whit CS controlled by software.
Such exception occurred because data->dfs is listed as the denominator in
a division inside the spi_esp32_transfer() function which is called from
spi_esp32_configure() (before assigning a value to data->dfs) inside
transceive() in the condition where mode 3 is chosen as the SPI operating
mode and the chip select is configured to be software-controlled.
Signed-off-by: Marcio Ribeiro <marcio.ribeiro@espressif.com>
Run clang-format on drivers/led/lp5569.c to align formatting in the file.
No functional changes intended.
Signed-off-by: Emil Dahl Juhl <emdj@bang-olufsen.dk>
The lp5569 features a double functioning pin for enable and pwm control.
The chip, however, uses the first rising edge to initialize and get ready
for i2c communication, and then the pin alters function to pwm mode.
Add support for providing enable-gpios to the lp5569 in the dts, which
will make sure to assert the pin and wait for the chip to initialize
before attempting further configuration of the chip.
Signed-off-by: Emil Juhl <emdj@bang-olufsen.dk>
The lp5569 controller contains an internal charge pump which can be useful
for driving LEDs with a forward voltage greater than the lp5569 supply.
Taking advantage of the charge pump can alleviate the need for an external
boost converter.
Add a dts property, charge-pump-mode, to the ti,lp5569 binding with which
the cp_mode bits of the MISC register will be configured.
Following the datasheet, the possible configurations are:
0x00 -> disabled (default)
0x01 -> 1x mode
0x10 -> 1.5x mode
0x11 -> auto mode
Signed-off-by: Emil Juhl <emdj@bang-olufsen.dk>
Introduces the test for testing the new functionality
of ztest shell.
Passing -r (repeat iter) parameter. This allows to run
a particula testcase or testsuite several times.
Passing -p (any value) parameter. This allows to provide
a parameter to a test at runtime.
Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
Expanding the ZTEST shell to include a command that
accepts additional parameters, such as ztest run_testcase
<suite:test> -p any_value.
Adding the new ZTEST_P macro, to create the
parameterized test.
Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
Expand ztest_shell subcommands `run-testcase`
and `run-testsuite` to include additional parameter `-r`
repeat-iter. This allows to run a particular testcase or
testsuite several times.
Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
Mark the POSIX_SIGNALS Option Group as supported to the extent
possible under Zephyr, as Zephyr does not yet support processes.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Since Zephyr itself does not currently support processes, but
conformant applications should still be able to link, add stubs
for the remaining POSIX functions in the POSIX_SIGNALS Option
Group.
The POSIX_SIGNALS Option Group is required for PSE51, PSE52,
PSE53, PSE54, and likely many other POSIX Subprofiles.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Newlib requires an alias for the getpid() function. There was
a Kconfig already present for doing so, but the actual alias
was missing.
So this is technically a bugfix.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The buffer flags MPSC_PBUF_FULL is a shared resource to determine
whether the buffer is available. When processing drop messages,
the flag will be cleared first and then set, add spin lock protection.
Signed-off-by: Xiaolu Sun <xiaolu.sun@intel.com>
Route `configure` and `recover_bus` through the RTIO framework to avoid
race conditions. Update `RTIO_OP_I2C_RECOVER` implementation to actually
recover the bus, instead of triggering a loop.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Incorrect value set by user when using sensor_attr_set can fail silently
since it always returns 0.
Fix by adding ret. Also added return on sensor_attr_get.
Signed-off-by: Aiman Mazlan <mohammad.aiman@stratusauto.com>
Initial CMake yaml module to facilitate reading yaml files into CMake,
update yaml settings and write it back to a file.
The yaml module also supports creation of yaml files from scratch.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Add a new zephyr_check_arguments_required_allow_empty() macro for
function argument validation.
Zephyr already has a zephyr_check_arguments_required() for checking
required arguments, like
zephyr_check_arguments_required(foo_func <prefix> FOO BAR)
which ensures that one of FOO or BAR are given in a call like:
foo_func(BAR val)
One limitation however, is that is some cases BAR may be allowed to be
empty, so that it's still possible to know if FOO or BAR were supplied.
In most case, BAR and FOO will have values following the keyword, like:
foo_func(BAR my_bar_val)
foo_func(FOO my_foo_val)
but in cases where `my_bar_val` is a variable which may be empty, like:
set(my_bar_val)
foo_func(BAR ${my_bar_val}) # (expands to: foo_func(BAR)
then BAR was actually supplied.
To support functions where such empty expansion is allowed, then a new
helper macro `zephyr_check_arguments_required_allow_empty()` has been
implemented, as to be able to distinguish `foo_func()` from
`foo_func(BAR)` when parsing arguments.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Toggling `CONFIG_USERSPACE` to `y` results in compilation
errors caused by the fact that various k_* functions don't
have their prototypes included in the SCMI sources (e.g:
`k_mutex_*`, `k_sem_*`, `k_is_pre_kernel()`).
To fix this, switch to using the `kernel.h` header instead
of `sys/mutex.h`. Previously, this worked because `sys/mutex.h`
included `kernel.h` if `CONFIG_USERSPACE` was set to `n`.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
When running on native_posix, the thread needs to be created
before the thread name can be set.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
This will update the posix thread names to match
the zephyr thread names.
This will simplify debugging as the debugger will
recognize the thread names.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
The intention of this API is to allow setting the posix thread
name equal to the zephyr thread name.
By defining it as an arch interface, the implementation becomes
generic.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
Newer Xtensa toolchain needs to include xtensa-types.h so that
macros in tie.h can be used without compilation errors.
The exact verison needing this is unknown but first encountered
in RJ-2023.2. Tested with older toolchain and that did not
cause any compilation errors so just include xtensa-types.h
if xt-clang is used. Haven't seen newer toolchains being
generated with xcc, so skip that for now.
Note that Zephyr SDK and the public HAL in Zephyr do not provide
this file.
Signed-off-by: Anthony Giardina <anthony.giardina@intel.com>
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
The gtest 1.15 has slightly different output from the original one that
was used to set up the harness. With this change we support both output
formats.
Fixes#72318
Signed-off-by: Yuval Peress <peress@google.com>
Fixes the adxl345 accelerometer driver to return zero on sample fetch
success, as specified by the sensor driver API. Prior to this change,
the driver incorrectly returned a positive non-zero value on sample
fetch success, which in turn caused a bus fault getting data with the
sensor shell.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
Initialize the missing chunk field when canceling a BLOB Transfer.
If you canceled a BLOB Transfer, the missing_chunk was not cleared in
the next BLOB Transfer. This can make it look like there are still
missing chunks, even though all chunks in the block have already been
received, and it does cause bugs.
Signed-off-by: Junho Lee <tot0roprog@gmail.com>
IMXRT11XX secondary core should not deinit ENET PLL
as it could be configured by primary core.
Signed-off-by: Anders Bjørn Nedergaard <abn@polytech.com>
Add test suite for remove of zephyr native libc
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Signed-off-by: Karthikeyan Krishnasamy <karthikeyan@linumiz.com>
Add checks to return value of esp_intr_alloc to avoid drivers init
returning 0 when interrupt allocation fails.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Adding macros to convert and validate input config from device tree
for IRQ priority and flags.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
This commit moves the test buffer from ITCM (not accessible by DMA) to DTCM
on several NXP boards, to make the test successful.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
This commit places the chan_blen_transfer DMA test's TX and RX buffers
in a separate file that gets entirely relocated. This ensures that the
buffers reside in the correct memory, without breaking other things
due to relocation of test data/code.
Fixes#75676.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Initial commit for entropy support on RA8
- drivers: entropy: implementation for TRNG driver of RA8x1
- dts: arm: add device node for trng of RA8x1
- boards: arm: enable support zephyr_entropy for ek_ra8m1 and
update board documentation
Signed-off-by: The Nguyen <the.nguyen.yf@renesas.com>
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
Fix compilation by providing an overlay file for cpuapp.
Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Co-authored-by: Andreas Moltumyr <andreas.moltumyr@nordicsemi.no>
Fix compilation by defining the watchdog flags for nRF9280 as well.
Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Co-authored-by: Andreas Moltumyr <andreas.moltumyr@nordicsemi.no>
Add board support for Application, Radio and PPR cores
of the nRF9230 SoC / nRF9280 SiP on the nRF9280 PDK board.
Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Co-authored-by: Andreas Moltumyr <andreas.moltumyr@nordicsemi.no>
The nRF9280 is a SiP (System-in-Package) consisting of the nRF9230 SoC
and additional components such as PMIC and others. Additionally,
the nRF9230 contains several CPUs, similarly to the nRF54h20 SoC.
Update nrfx glue, and add necessary Kconfig and initialization code
to allow building for nRF9280 targets: CPU, Radio and PPR cores.
The nRF9280 is used for all user build targets and Kconfigs,
whereas the nRF9230 is used as the build target for the MDK.
Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Co-authored-by: Andreas Moltumyr <andreas.moltumyr@nordicsemi.no>
Move mpu_region.c to common folder, to re-use with nRF92.
Rename it to nrf54hx_nrf92x_mpu_regions.c to indicate
which product series it applies to.
Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Add definition of the nRF9280 SiP with its Application,
Radio, and Peripheral Processor (PPR) cores and a basic set
of peripherals: GRTC, GPIOs, GPIOTE, and UARTs and few others.
Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Co-authored-by: Andreas Moltumyr <andreas.moltumyr@nordicsemi.no>
Monitor mode relies on core Wi-Fi management functions, so, the file
should be included for both system and system with raw modes.
Fix this by adding a hidden symbol.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
If Wi-Fi management is enabled, then independent of modes scan
functionality is always included.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
This is a fix from QSPI-NOR driver to wait for clock divider change to
be applied and take effect.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
For less than 32MHz using HFCLK192M, /2 divider should be used and only
for Anamoly159 /1 divider should be used.
Without this fix 8MHz clock in DTS uses 16MHz clock.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
SHEL-2947] Option to set either PS-poll or QoS null frame based
power save data retrieval mechanism.
Signed-off-by: Ajay Parida <ajay.parida@nordicsemi.no>
Removes the requirement for the different layers in the OS agnostic
parts of the driver having to maintain a handle to the OS interface
layer in order to call the OS interface calls. The OS interface layer
now maitains the handle to OS-specific ops internally and invokes the
appropriate functions.
Fixes SHEL-2639
Signed-off-by: Sachin D Kulkarni <sachin.kulkarni@nordicsemi.no>
[SHEL-2542] When reset command is called this will
reset all statistics including firmware and host.
Signed-off-by: Kapil Bhatt <kapil.bhatt@nordicsemi.no>
[SHEL-2054] Adding a kconfig option for WMM.
By default it will be enabled. If user needs
to disable it, set it as n.
Signed-off-by: Kapil Bhatt <kapil.bhatt@nordicsemi.no>
Adds an optional callback which can be used to append custom
fields to the image slot state command response
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
errno is defined by the ISO C standard to be a modifiable lvalue of type
int, and **must not be explicitly declared**
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
1. tm_mon in rtc_time structure has a range [0, 11],
while the RTC expects [1, 12]. Add missing
increasing / decreasing of this value.
2. Fix typo in debug log
Signed-off-by: Daniel Kampert <DanielKampert@kampis-elektroecke.de>
The r0 register holds the system_off function pointer. As r0 is a scratch
register, the pointer needs to moved to a preserved register before
branching to a (custom) marker function.
Furthermore, in accordance to rule 6.2.1.2 of aapcs32, the stack pointer
needs to align on 8 bytes. Hence r0 is pushed to the stack in addition to
the lr register, before calling the public interface of checking the
s2ram marker.
Signed-off-by: Hessel van der Molen <hvandermolen@dexels.com>
Do not try to format each single failure, this will take too long to
process and will run for hours and spam GH.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Adds a new board definition for the ADI MAX32690FTHR board. This board
uses the same SoC as the MAX32690EVKIT board, but with a smaller feather
form factor.
Tested on hardware with the following samples:
- samples/hello_world
- samples/basic/blinky
- samples/basic/threads
- samples/subsys/shell/shell_module
- samples/subsys/input/input_dump
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
NXP IMX USDHC fallback card detection method changed from querying the
peripheral to simply assuming the card was present. Add a note to the
migration guide highlighting this and explaining how to restore the
previous behavior for anyone using this detection method.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
The imx USDHC driver previously queried the peripheral's internal card
detect signal to check card presence if no card detect method was
configured. However, some boards do not route the card detect signal and
do not work correctly with the DAT3 detection method supported by this
peripheral. As a fallback, assume the card is present in the slot but
log a warning to the user.
Fixes#42227
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
Modify the condition in the parse_testplan
function to align with the changes in the Status class.
Signed-off-by: Arkadiusz Cholewinski <arkadiuszx.cholewinski@intel.com>
Updated the clocks that get initialized for the MCXN947
when using the LPTMR. The LPTMR allows the user to select
and Input clock, however said input clock must be
initialized before the user can select it.
Update description for clk-source in binding file.
Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
Move default of monolithic and fw loader, options, etc to the
common kconfig files rather than defaulting in soc file.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Consolidate the ROM RAMLOADER config to be in one place,
add a new Kconfig file to be included by the SOCs with the feature.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
The CONFIG_USB_MCUX_CONTROLLER_TYPE choice config
is not necessary, let's just remove it. Theoretically,
if there was an SOC with the EHCI and LPCIP3511, then
it might cause a build error, but there is no SOC
which is supported on this legacy driver that has that.
Remove all settings of it in the SOC files.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Currently this code related to how to configure the
flash size and address when using flexspi to XIP is copy
pasted in all sort of places and ways all over the tree,
let's clean this up and have single point of control over
this configuration.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Move all dependencies of the family config to series level,
and put a disclaimer saying not to use the family config.
Change all occurrences of the family config in code to the
MCXNX4X series config.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Some flash/memc drivers like flexspi will want to default the
value of the log level to off to avoid RWW hazard while XIP,
to do this, the logging template must be sourced after the driver
kconfig files so that the default value from the driver is able
to be checked, since logging template introduces an unconditional
default otherwise.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
NXP is not supporting these derivative parts in the zephyr upstream,
these references to them should therefore be removed in order to avoid
confusion.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
The Kconfig defaults should be in Kconfig.defconfig.
MFD should not be made dependent on the LP flexcomm being
enabled, since MFD can be for other things than just flexcomm.
Change from depends on to an if.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Doesn't seem like there is any reason to be changing the
serial and ADC driver init priorities in the SOC defconfigs.
By default, clock control has priority 30, dma has priority 40,
and serial/adc have priority 50. This seems already to be the order
that is needed, and the original goal of these overrides, which
don't seem necessary anymore.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
There are some SOCs which use the same pinctrl
device, but are not really overall that similar to the kinetis
family of SOCs, so prepare to reuse this code by other SOC families.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Moving RT118x kconfigs to series level instead of family level,
and cleaning up redundant declarations, and adding missing
HAS_MCUX_FLEXSPI selection.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Introduced `GPIO_DEVICE_INIT_RA_IF_OKAY` which utilizes `COND_CODE_1`
to reduce the chain of #if DT_NODE_HAS_STATUS(...) #endif
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Refactor the guidelines rule table and add a zephyr rule number
to make it more clear that the coding guideline rules are a
subset of the MISRA-C:2012 rules.
Signed-off-by: Simon Hein <Shein@baumer.com>
Build was failing due to const variable being passed as function param
accepting non-const variable discarding const qualifier. Explicitly cast
to fix the build issue.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
The ESAI is already reset during the config_set() function
so no need to also reset it during init().
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
The reset pin on the chip is optional, add a soft reset call when the
reset pin is not specified for the device.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Implemented the following:
- `asctime_r()`
- `asctime()`
- `localtime()`
- `localtime_r()`
- `ctime()`
- `ctime_r()`
Specifically:
- the implementation of `localtime()` & `localtime_r()` simply
wraps around the gmtime() & gmtime_r() functions, the
results are always expressed as UTC.
- `ctime()` is equivalent to `asctime(localtime(clock))`, it
inherits the limitation of `localtime()` as well, which only
supports UTC results currently.
Added tests for these newly implemented functions.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
`readdir_r()` belongs to the following option group
POSIX_FILE_SYSTEM_R: Thread-Safe File System
Create a new Kconfig `CONFIG_POSIX_FILE_SYSTEM_R` to compile
it.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Add minimum support for the `west sdk` command.
This only provides completion for the `sdk` command itself.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
This command can list and install SDK.
Run 'west sdk install' to install the SDK.
Run without any parameter, installing
specified by SDK_VERSION in the source tree.
'west sdk' to show installed SDK information.
This command is just a wrapper for SDK's setup command,
but it simplifies the installation process. It will be a good
improvement for onboarding first-time users.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Removes calling k_busy_wait() and uses k_msleep().
Updates polling rate of EEPROM busy status after read request to 1 ms, as
recommended by the app note.
Signed-off-by: Jakub Topic <jakub.topic@anitra.cz>
The tests manually include sources that are normally conditionally
included (ie based on kconfig values) in the stack.
The tests should be fixed by the original authors.
For now, force-on the hidden kconfig that enables the log options.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
`OTS_CLIENT=y` and `OTS=n` is a valid config.
Since the logs weren't conditionally included, this flew under the radar
for a while.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
- got rid of "Others" menu
- JK I made a new one: "Common"
- moved all host-related opts to "Host" instead of "Others"
- moved all audio-related opts behind `if BT_AUDIO`
- moved only controller kconfig to controller/Kconfig.ll_sw_split
- it had a dependency there already
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Having all the configs be visible by default clutters the menuconfig
view. Make them visible only when the corresponding subsys or module is
enabled.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Commit 698a0c3193 changed the bluetooth_api
section title, which made the reference in the Coding guidelines turn into
"API", which is confusing.
Use a fixed title for that reference to fix the issue.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
There was hardcoded value for user_data which is no longer valid.
Use proper CONFIG_BT_CONN_TX_USER_DATA_SIZE for that.
Signed-off-by: Szymon Janc <szymon.janc@codecoup.pl>
Align all sensor drivers that are using stmemsc (STdC) HAL i/f
to new APIs of stmemsc v2.6
Requires https://github.com/zephyrproject-rtos/hal_st/pull/21
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Fix warnings generated when performing sensor drivers build test
due to typos in i2c DT definition.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
All the network related shell activities should be under
network shell so moving it to "net bridge ..." command.
Add this information to migration guide.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Remove the references to the breathe extension in the
Schematic of the documentation build process graph and
the filtering expected warnings section.
Signed-off-by: Simon Hein <Shein@baumer.com>
The generated HTML was broken, even though the rst files themselves
contained the correct URLs. Update to a different format which should
generate the right output.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
set high_bandwidth and use the cfg->mps to set
ep_init.maxPacketSize because NXP MCUX controller
driver supports additional transaction bits in
maxPacketSize.
Signed-off-by: Mark Wang <yichang.wang@nxp.com>
Instead, use the helper to get the size field from the MPS value.
MPS value may contain information about additional transaction
per microframe (bits 12..11).
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Make driver aware of High-Bandwidth endpoints both in Completer and
Buffer DMA mode. In Completer mode TxFIFO must be able to hold all
packets for microframe, while in Buffer DMA mode space enough for two
packets is sufficient.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
DMA is capable of packetizing transfers on its own and the driver
doesn't need to check available TxFIFO size when scheduling DMA
transfer.
Split packets on DWORD boundary when writing more than one packet to
TxFIFO in completer mode.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add macros for converting between Max Packet Size and total payload
length. Allow drivers specify whether endpoint supports high-bandwidth
interrupt and high-bandwidth isochronous transfers.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Use COND_CODE_1() instead of UTIL_AND() to make it possible to only
define the HID_MPS_LESS_65_ macros up to value 64.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
wMaxPacketSize in endpoint descriptor is stored in little-endian order,
but the mps parameter passed to functions is in host order.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
This adds a kconfig option to force
tx blocking on serial. This way only rx
will use the interrupt.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
To prepare for supporting flexcan, can node should be
renamed to canxl to support both flexcan and canxl
Signed-off-by: Tu Nguyen Van <tu.nguyenvan@nxp.com>
The received messages are put into the FIFO one by one in the
order, the hardware will return the queue index for current
message. So use the index instead of reading always from 0.
Signed-off-by: Ha Duong Quang <ha.duongquang@nxp.com>
CONFIG_BT_CONN_TX_USER_DATA_SIZE is now used for callbacks in the host.
We don't want to limit ourselves to that, so change the wording to be
more generic.
In the future, the plan is to not use user_data at all, removing the
need for the kconfig altogether.
Also rename the structure that was referenced in the docstring.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
/zephyr/soc/intel/intel_adsp/ace/power.c:46:9: warning: implicit
declaration of function 'cache_data_flush_range'; did you mean
'sys_cache_data_flush_range'? [-Wimplicit-function-declaration]
46 | cache_data_flush_range((__sparse_force void *)
| ^~~~~~~~~~~~~~~~~~~~~~
| sys_cache_data_flush_range
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
The symbol DCACHE_LINE_SIZE was not being defined in Intel ADSP
targets.
It fixes the following problem:
/zephyr/soc/intel/intel_adsp/ace/power.c:30:29: error:
'CONFIG_DCACHE_LINE_SIZE' undeclared here (not in a function); did you
mean 'XCHAL_DCACHE_LINESIZE'? 30 | uint8_t
adsp_pending_buffer[CONFIG_DCACHE_LINE_SIZE]
__aligned(CONFIG_DCACHE_LINE_SIZE);
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
In SoC imxrt1010, edma channel has separate interrupt entry,
not like the rest of in-tree imxrt SoC series
Signed-off-by: Dat Nguyen Duy <dat.nguyenduy@nxp.com>
Power off the SD card in `DISK_IOCTL_CTRL_DEINIT`, instead of only
waiting for the card to be idle then doing nothing. This is a safer
state for `DISK_IOCTL_CTRL_DEINIT`, which is documented as preparing the
disk to be removed from the system. It also has the advantage of
lowering power consumption while de-initialized.
Signed-off-by: Jordan Yates <jordan@embeint.com>
This commit ensures that the state of the address can be changed from
the Deprecated state to the Preferred state.
Additionally, an issue with improper memory comparison size for the mesh
local prefix has been fixed.
Signed-off-by: Łukasz Duda <lukasz.duda@nordicsemi.no>
The .bin & .hex build output is optional and can be disabled by
CONFIG_BUILD_OUTPUT_BIN/HEX.
Add support for the mandatory .elf build output
to the jlink runner flash command.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
Added the battery level status char to bas service
as per bas_1.1 spec. Added BSIM test for BAS service
to test the NTF/INDs of BAS characteristics.
Signed-off-by: Nithin Ramesh Myliattil <niym@demant.com>
dhcv4 server was not providing the dns server details to the
client because dns option was handled. Added the dns server
option to be send to the client as response form dhcpv4 server
Signed-off-by: Muhammad Haziq <muhammad.haziq@zintechnologies.com>
Unfortunatelly new Qualification Workspace is not able to properly import
ICS if file is UNIX line endings.
Signed-off-by: Szymon Janc <szymon.janc@codecoup.pl>
To make the scanner module more understandable and more streamlined, I
reworked the update mechanism of the scanner. The scanner tracks now the
parameters that were used to enable it and the reason why it is running.
This facilitates state logic and allows other modules to "start the
scanner", altough it is already running.
This is mostly a refactoring and not a functional change.
Added a test to verify the behavior.
Signed-off-by: Jan Müller <jan.mueller@nordicsemi.no>
add to task
A common question is how twister decides on which platform to run
a given test. Added section is meant to explain those rules.
Signed-off-by: Maciej Perkowski <Maciej.Perkowski@nordicsemi.no>
The serial number for debugger selection over USB
can be selected with the dev-id. This change
reflects also more the workflow of west flash
with J-Link.
The usage of SelectEmuBySN breaks the support for
J-Link over IP with twister.
Signed-off-by: Michael Arnold <marnold@baumer.com>
sys_heap_validate() is in sys_heap.h API but it is available only when
CONFIG_SYS_HEAP_VALIDATE=y. Add empty implementation if option is
disabled.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Enables open loop operation when initializing into LRA mode. Open loop
operation is enabled by default for ERM mode. This is hard coded for LRA
mode because calibration is currently unsupported.
Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Adds "vib-overdrive-mv" device tree property to configure the overdrive
clamp at initialization.
Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Adds support for boot time configuration of the rated voltage at
initialization via "vib-rated-mv" devicetree property.
Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Adds the default value for the existing properties to the device tree
and fall back on those values at initialization if necessary.
Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Removes an unused enum defining the DRV2605 power states. This enum is
dead code so it is being removed.
Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Add the support of the reset-cmd property for the stm32h7 disco kits
where the quad-spi flash is mt25ql512ab
This device accepts the SPI_NOR_CMD_RESET_En/SPI_NOR_CMD_RESET_MEM
Signed-off-by: Francois Ramu <francois.ramu@st.com>
Use the define to send the reset cmd at quad-flash init :
SPI_NOR_CMD_RESET_EN followed by SPI_NOR_CMD_RESET_MEM
when the st,stm32-qspi-nor has the <reset-cmd> property set.
Reports the jedecID correctly.
Signed-off-by: Francois Ramu <francois.ramu@st.com>
MCUX ehci controller driver support cache maintenance if
USB_DEVICE_CONFIG_BUFFER_PROPERTY_CACHEABLE is enabled.
Enable USB_DEVICE_CONFIG_BUFFER_PROPERTY_CACHEABLE if
CONFIG_UDC_BUF_FORCE_NOCACHE is false and CONFIG_NOCACHE_MEMORY
is true.
Signed-off-by: Mark Wang <yichang.wang@nxp.com>
add reset control registers information (on RCC_BUS_RSTR LTDCRST bit)
for display peripheral reset.
Signed-off-by: Fabrice DJIATSA <fabrice.djiatsa-ext@st.com>
Configures pins for the SPI instance attached to the Pmod connector to
enable using this board with the pmod_acl shield.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
Adds a new shield definition for the Digilent Pmod ACL module. This
module provides support for an ADI ADXL345 3-axis accelerometer over a
Pmod SPI connector.
Signed-off-by: Maureen Helm <maureen.helm@analog.com>
The MBT server, as the MBT client currently sets the maximum chunk size
according to maximum supported segments in the accesss layer. This might
be suboptimal for some use cases.
The added Kconfig options give customers the option to fine tune it
themselves.
Future work will include addition of an API for the customer to modify
it also during runtime.
Signed-off-by: Kyra Lengfeld <kyra.lengfeld@nordicsemi.no>
Add conn parameter to status/flags callbacks of bt_vcp_vol_rend_cb
to differentiate between remote and local changes.
Signed-off-by: Chang An <chang.an_1@nxp.com>
Check if the frame is within the text address before saving
into the buffer, this eliminates the extra, uninitialized frame
at the end of the unwind.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Relocate stack unwind backends from `arch/` to perf's
`backends/` folder, just like logging/shell/..
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The timer & dwork can be statically initialized,
SYS_INIT is not strictly required.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Currently, the timer is stopped:
- in the timer handler, when the buffer is full, or
- in work handler, when time's up
In any cases, the work handler is bounded to run to print
the message, so we can kill the timer there instead.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Added:
- `clear` to discard the buffer without printing
- `info` to print info about the buffer and if the
profiler is running
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
"Perf is already running" works for `record` but is a little
strange when doing `printbuf`, so remove the "already" to
make it more universal.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
The `buf_full` flag is set when it is full, but dumping the
buf currently only resets the `idx`, this means that the perf
command only works when the buffer hasn't been full before.
Reset the flag when we clear the buffer.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
`PERF_EVENT_TRACING_BUF_OVERFLOW` isn't used, remove it.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
`cmd_perf` isn't doing anything meaningful, remove it so that
the help message will be printed when invoked. Updated
the help message of the main command.
```
uart:~$ perf
perf - Lightweight profiler
Subcommands:
record : Start recording for <duration> ms on <frequency> Hz
Usage: record <duration> <frequency>
printbuf : Print the perf buffer
```
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
static perf_data is zero-initialized by default, there's no
need to explicitly set `idx` to `0`.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
Introduce list mode in Zephyr-sdk module package.
The list mode allows to list all Zephyr SDK's found in the system
without loading any of them.
Signature of the list mode is:
> find_package(Zephyr-sdk COMPONENTS LIST)
Will print valid Zephyr SDKs and their path, as well as defining the
following corresponding CMake lists:
- Zephyr-sdk : List of Zephyr SDKs' version
- Zephyr-sdk_DIRS : List of Directories with a valid Zephyr SDK.
Each entry in Zephyr-sdk corresponds to the same entry index in the
Zephyr-sdk_DIRS list.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Minor cleanup of the FindZephyr-sdk.cmake module.
- Honor the QUIET flag on find_package(Zephyr-sdk QUIET)
Do not print messages when caller has specified QUIET in the
'find_package()' call.
- include Zephyr extensions CMake module.
FindZephyr-sdk.cmake uses zephyr_get() from extensions.cmake, and
therefore the proper thing to do is to include said module in order
to have the package re-usable.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Install the default delegate for reporting the CAN core clock frequency at
driver instance initialization. This allows using the default clock
configuration when not using ztest.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
This patch contains big-endian version of the macros present in that
file. The new code is formatted by clang-format, which is why the
formatting is different.
Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add missing braces to comply with MISRA C:2012 Rule 15.6 and
also following Zephyr's style guideline.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
This assert cannot be turned on, as `pdu` will be NULL sometimes. This
is okay, it just means that the current channel doesn't have anything to
send and that we should probably try another one.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Disable input buffer full interrupt for 60h/64h and 62h/66 ports by
calling interrupt controller API. The API has barrier mechanism to
ensure that a thread's requirement to disable peripheral interrupt
takes effect before enabling CPU interrupt. Therefore, the disabling
operation does not occur in ISR and results in interrupt 0 symptom.
Signed-off-by: Dino Li <Dino.Li@ite.com.tw>
The Audio integration PLL is faster on PTL compared to earlier ACE
platforms: 442.368 MHz instead 393.216 MHz, however the default
divider remained 16, which will result incorrect cardinal clock speed.
Change the divider to 18 in order to get correct 24.576 MHz cardinal
clock.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Add power management support for Apollo3/Apollo3P SPI, and
automatically enables device runtime power management
Signed-off-by: Zhengwei Wang <zwang@ambiq.com>
Add power management support for Apollo3/Apollo3P I2C, and
automatically enables device runtime power management
Signed-off-by: Zhengwei Wang <zwang@ambiq.com>
Add power management support for Apollo3/Apollo3P UART, and
automatically enables device runtime power management
Signed-off-by: Zhengwei Wang <zwang@ambiq.com>
Add initial support for npcm400 evaluation board
Signed-off-by: Tyrone Ting <kfting@nuvoton.com>
Signed-off-by: James Chiang <cpchiang1@nuvoton.com>
Signed-off-by: Joseph Liu <kwliu@nuvoton.com>
Add initial support for nuvoton npcm400, which is a chip
family of Satellite Management Controller(SMC).
Add ecst python scripts to append the header used by ROM Code
Signed-off-by: Tyrone Ting <kfting@nuvoton.com>
Signed-off-by: James Chiang <cpchiang1@nuvoton.com>
Signed-off-by: Joseph Liu <kwliu@nuvoton.com>
Config to enable VLAN promiscuous and untagged.
Config to enable SI message interrupt.
Fix the build warning.
Signed-off-by: Ha Duong Quang <ha.duongquang@nxp.com>
Create the set FD mode function because the old
RTD function is updated to static.
Fix the build warning by update the type of buffidx
and u32SysStatus arguments in the callback function
to uint32_t.
Signed-off-by: Ha Duong Quang <ha.duongquang@nxp.com>
Fixing 3 issues:
1. The mask can be wrong if the alarm register is
set to a MAX value because the alarm bit is the
highest in the alarm register. The mask is now
generated by checking the AE_x bits in the time
registers.
2. Fixing possible NULL pointer exception in
alarm_set_time API. timeptr can be set to NULL
with mask 0 in the alarm_set_time function.
The regs variable for the I2C communication
is written with the correct value from timeptr
only when the right bit in the mask is set.
3. rv8263c8_alarm_set_time() now resets the
alarm status.
4. Interrupts are now enabled by using
rv8263c8_alarm_set_time() rather than when
setting an alarm callback.
Signed-off-by: Daniel Kampert <DanielKampert@kampis-elektroecke.de>
Adds commands for triggering conn_mgr functions and
tweaking conn_mgr connectivity flags.
Signed-off-by: Georges Oates_Larsen <georges.larsen@nordicsemi.no>
Add functional test for flash_erase().
Add negative tests for flash_read(), flas_write(), flash_erase(),
flash_fill() and flash_flatten().
Add functional test for flash page layout.
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
For Enterprise crypto MbedTLS needs more heap either separate pool or
libc heap, based on experiments 55000 was arrived for a successful
WPA2-EAP-TLS association.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Add basic WPA2 EAP-TLS support.
Also, add test infrasturcture esp. the certification handling,
non-certificate credentials are take as runtime input and certificated
are build time input for testing.
A real application can set certificates at runtime too.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Keep WIFI_SECURITY_TYPE_EAP, and define WIFI_SECURITY_TYPE_EAP_TLS
same value as WIFI_SECURITY_TYPE_EAP to make it backwards
compatible. Ready to support more EAP type in the comming PR.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
Wipe partition header prior to fatfs testsuite starting. This insures
that the disk will be in an unformatted state at the start of the test,
so the first fs_mount() calls will fail as expected.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
TX time tracing tells how long it took from network packet
creation to when the stack got rid of it.
So the network stack allocates net packet, this is the
start time. The end time is when the packet is fully processed (sent)
by the network device driver.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
RX time tracing tells how long it took from network packet
creation to when the stack got rid of it.
So the network device driver allocates net packet, this is the
start time. The end time is when the packet is fully processed.
Currently the limitation is that the RX time duration is used
for network packets that are tied to an open socket.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
For regexes such as `CONFIG_DEBUG_(OPTIMIZATIONS|INFO)` and
to be able to use `.*` as this syntax is used in the Kconfig search.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
The docs for the iterable sections has a minor typo when
describing how to add the structs to the linker, repeating
'place the' twice.
Signed-off-by: Paulo Santos <pauloroberto.santos@edge.ufal.br>
Writing directly to Px_DATA_REG modifies pins which are not
indicated by mask, causing gpio_basic_api test to fail.
Use Px_SET_DATA_REG and Px_RESET_DATA_REG to modify only
pins indicated by mask.
Signed-off-by: Ioannis Damigos <ioannis.damigos.uj@renesas.com>
Set pin to input with no resistors selected when it is configured as
GPIO_DISCONNECTED.
Signed-off-by: Ioannis Damigos <ioannis.damigos.uj@renesas.com>
Clear pending interrupts after disabling TRNG to avoid
smartbond_trng_isr getting called with TRNG disabled
Signed-off-by: Ioannis Damigos <ioannis.damigos.uj@renesas.com>
The gt911 can recognize up to 5 touch points at a time.
Add code to support these multi-touch events.
Signed-off-by: Farah Fliss <farah.fliss@nxp.com>
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
ESP32-C3-DevKit-RUST-1 is a ESP32C3 based board
that includes a builtin LED, button, WS2812,
temperature and humidity sensor (SHTC3) and a IMU
(ICM42670).
Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
Enable the NXP Kinetis Low Power Timer (LPTMR) timer driver when
power management is enabled.
When the NXP KE1xZ SoC series is using the Arm SysTick as hardware
timer, the cycles/second will always be equal to the CPU core clock
frequency.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
Add LPTMR driver counter support for NXP frdm_ke17z and frdm_ke17z512
boards, tested 'drivers.counter.basic_api' case.
Enable cpu power states and determine the default
CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC from devicetree when using the
Arm SysTick hardware timer.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
Add lptmr support for ke17z, add related configuration for lptmr
driver.
Add supported CPU power states for idle, stop, partial stop 1, and
partial stop 2.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
Tmp114 has an average function, according to the datasheet this is
default disabled. Add attribute to enable this feature.
Signed-off-by: Fredrik Gihl <fgihl@hotmail.com>
MAX32690EVKIT board has CFAF128128B1-0145T display which
is 128x128 graphic display.
The pins goes to display is not standard SPI interface, it requires
SPI bitbanging to drive display.
This commit enables mpi dbi display support with LVGL graphic library
Pin connection of display is 3wire mode
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
MAX32680EVKIT board has CFAF128128B1-0145T display which
is 128x128 graphic display.
This commit enables mpi dbi display support with LVGL graphic library
Pin connection of display is 3wire mode
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
MAX32672EVKIT board has CFAF128128B1-0145T display which
is 128x128 graphic display.
This commit enable mpi dbi display support with LVGL graphic library.
Pin connection of display is 3wire mode
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Update spi_bitbang_transceive_async function parameter to it match
with correct one that declared in struct
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Dynamic memory allocation depends on various factors and many are
only known at runtime depending on application inputs.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Update the bus_clk divider value from 4 to 2 for frdm_ke17z512
platform. The bus and flash clocks are raised to 16Mhz to ensure
that `tests.kernel.timer.timer_jitter_drift` sample passes.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
This commit addresses an issue where enabling the alarm or update
callbacks unexpectedly disabled the RTC's programmable clock output
during runtime.
The interrupt configuration has been moved to the driver's init
function.
Signed-off-by: Jakub Topic <jakub.topic@anitra.cz>
include/zephyr/bluetooth/mesh/ was missing from the exclusion
files for Bluetooth Host, and include/zephyr/bluetooth/audio/
was there twice.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
EARLY, APPLICATION and SMP levels are no longer support for device
drivers as 2 releases have happened since its deprecation. Add a
validation macro so that compilation fails if the given level is not
valid.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Compatible headers have already been kept for 2 releases, so the time to
remove them has come.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
This includes helper function for pin configuration
and a DT binding for the pinctrl DT node.
There's two important notes to be made regarding this
protocol:
* pinctrl drivers have no subsytem API to implement as opposed
to clock control drivers. Because of this (and the fact that
`pinctrl_configure_pins()` doesn't require a `struct device`
handle) the pinctrl driver consists only of a helper function,
which implements the `PINCTRL_CONFIGURE_PINS` command.
Additionally, the `scmi_protocol` structure is defined inside
the pinctrl helpers source file to avoid redundant code
(otherwise, each SCMI-based pinctrl driver would have to define
it its source file).
* each vendor may have their own set of pin propeties and DT
representations for them. Because of this, there can't be a
generic, SCMI-based pinctrl driver. As such, each vendor who
wants to use the SCMI support for pinctrl operations will have
to implement their pinctrl driver (which, to put it simply,
revolves around implemeting `pinctrl_configure_pins()`) and
make use of the pin configuration function introduced in this
commit. Moreover, this means that each vendor will have control
over the way their pin properties are encoded in the
`scmi_pinctrl_settings` structure.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
This includes:
1) Source containing helper functions, each
implementing a command from the clock management
protocol.
2) A clock controller driver making use of said
helper functions and implementing the clock
subsystem API.
3) A DT binding for clock protocol node.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
Introduce core support for ARM's SCMI (System Control and
Management Interface). This includes:
* shared memory (SHMEM) driver. This consists of a suite
of functions used to interact with the shared memory area.
* shared memory and doorbell-based transport layer driver.
Data is passed between platform and agent via shared
memory. Signaling is done using polling (PRE_KERNEL) and
doorbells (POST_KERNEL). This makes use of Zephyr MBOX API
(for signaling purposes) and the SHMEM driver (for polling
and data transfer).
* core driver - acts as glue between transport and protocol
layers. Provides synchronized access to transport layer
channels and channel assignment/initialization.
* infrastructure for creating SCMI protocols
This is based on ARM's SCMI Platform Design Document: DEN0056E.
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
The function interval_to_sync_timeout was copied several places.
Made it into a common function and removed duplicate code
Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
The babblesim tests for the CAP acceptor test have been refactored
for improved readability
Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
Exclude the nucleo_h755i_q m4 core from the flash_shell samples,
as the m4 core in stm32h7 parts does not have flash support in Zephyr.
Signed-off-by: Mike Banducci <michael.banducci@sandc.com>
Add support for the ST nucleo h755zi_q board which
uses an stm32h755 in the st nucleo-144 board
format.
Signed-off-by: Mike Banducci <michael.banducci@sandc.com>
Add support for the stm32h755 which is a close relative of
the stm32h745 with additional cryptography and hashing
peripherals.
Signed-off-by: Mike Banducci <michael.banducci@sandc.com>
Nrf54h20dk and nrf54l15 have UART Flow Control enabled
by default on all cores.
It's a source of problem when mbox sample is run in Twister.
Twister opens serial port only on host core,
thus nobody confirms reception of logs from remote core.
As a result, remote core stucks on printing boot banner.
Twister fails sample due to the timeout while waiting for messages
from remote to host.
Disable Flow Control on remote core when mbox sample is executed
on nrf54h20 or nrf54l15.
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
Extend pytest-args from configuration yaml file with args
from command line instead of overwriting.
Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
Added mimxrt1040_evk to inregration platforms, so that fxls8974 is tested,
and added config for mimxrt1040_evk to sensor_shell
Signed-off-by: Krystof Sadlik <krystof.sadlik@nxp.com>
Change NuMaker M463/M467 series USBD clock source to HIRC48M.
This makes core-clock and its clock source PLL not required
to be multiple of 48MHz.
Signed-off-by: Chun-Chieh Li <ccli8@nuvoton.com>
Background of this modification is to make clock control
driver code provided by Renesas vendor to support for Renesas MCU
on Zephyr.
Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
- Initial support for RA6M2 SoC
Signed-off-by: Tri Nguyen <tri.nguyen.wj@bp.renesas.com>
Signed-off-by: Danh Doan <danh.doan.ue@bp.renesas.com>
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
First commit to support serial driver running on r_sci_uart for Renesas
RA devices.
Signed-off-by: The Nguyen <the.nguyen.yf@renesas.com>
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
Background of this modification is to make gpio driver code
provided by Renesas vendor to be an official support for Renesas
MCU on Zephyr
Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
Update pinctrl driver which used for Renesas RA series with
PFS secure register
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
This extension was created to overcome C domain/Breathe limitations.
This is no longer needed as we link directly to Doxygen pages.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
DHCPv4 server will probe the offered IP address (send ICMP echo request)
and wait for 1s (default) before offering the address. STA sends out DHCP
discover, but gets no response. Windows automatically assigns the network
card an IP address of 169.254.xx.xx.
So set timeout for ICMP probe sent by the server to 100ms.
Signed-off-by: Gang Li <gang.li_1@nxp.com>
When user_data is not zeroed-out, the API returns an error. Downgrade
the API error to a warning log instead.
Introducing this check (#76489) broke a few PTS tests, as user_data is
not initialized by `net_buf_alloc()`. Doing so is in discussion:
https://github.com/zephyrproject-rtos/zephyr/issues/77088
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
It is already checked against `NULL` in the codepaths that take the
`ops` struct as a parameter.
Add a note in the documentation to make the requirement official.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
For two reasons:
- prevent exposing the previous user's info to the new user
- make NULL checks on user_data work
Since we don't really have a field that specifies what part of the
user_data array is valid, we have to rely on other checks.
Such a check, if user_data contains a callback, is comparing against
NULL before calling said callback.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
In order to reduce excessive false positives for Coding
Guidelines checks in CI, maintain a list of paths that are
marked "safe" for reserved names to be implemented or declared.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Implements the driver for the OLED SSD1327 controller.
This driver is based on the ssd1306 driver due to their similarities.
Only the SPI control bus is supported.
Signed-off-by: Luc BEAUFILS <luc.beaufils@savoirfairelinux.com>
Some tables used more than 120 characters per line. This commit compresses
the formatting of the tables in the documentation.
Signed-off-by: Jonas Remmert <j.remmert@phytec.de>
This commit add the description of the fmc in the SoC stm32l5, and the
description of the screen controller st7789v in the board stm32l562e-dk.
Signed-off-by: Miguel Gazquez <miguel.gazquez@bootlin.com>
Add support for using the stm32 fmc to interact with a display
controller, using Intel 8080 protocol with a 16 bits parallel bus.
Signed-off-by: Miguel Gazquez <miguel.gazquez@bootlin.com>
Macros to write specific peripheral registers were removed as a
compile flag was added to hal_espressif requesting struct bitfields
to have strict volatile access (thus 32-bit access), allowing for
the cleanup.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Calling k_msleep() leads to a int64_t division, causing udivdi3 and
similar to be linked in.
Keep the outer API the same, but switch to k_timeout_t before passing
to the inner API. This saves 1916 B of ROM.
Signed-off-by: Michael Hope <mlhx@google.com>
Path loss monitoring does not work without LE Power Control
also enabled in the controller, so update the dependencies
in the kconfigs so path loss monitoring selects power
control.
Signed-off-by: Sean Madigan <sean.madigan@nordicsemi.no>
Path loss monitoring was not being enabled anywhere, meaning
that issues could be merged in without catching the issue.
This commit adds a test case to build the shell with path
loss monitoring enabled to catch issues.
Signed-off-by: Sean Madigan <sean.madigan@nordicsemi.no>
callback_list was renamed to conn_cbs in commit 3eb975d.
However plm callback was missed due to it not being built
anywhere.
Signed-off-by: Sean Madigan <sean.madigan@nordicsemi.no>
Transmit/write buffers are expected to be constant values given to the
operation to transmit but not mutate. Seperate the OP_TX and OP_RX
operation description unions.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
This log message does not need to be repeated 10 times at the INFO level
when the same information is provided after all the retries are done:
```
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Legacy card detected, no CMD8 support
<inf> sd: Card does not support CMD8, assuming legacy card
```
to
```
<inf> sd: Card does not support CMD8, assuming legacy card
```
Signed-off-by: Jordan Yates <jordan@embeint.com>
Added python-tk to the brew install statement.
In order to use the zephyr gui tools python must also have the
"tkinter" (python tk interface) tools available.
tkinter is NOT part of 'python3' through homebrew on macOS.
fixes#76811
Signed-off-by: Eric Southam <eric.southam@lvt.com>
3506a7925a originally put it, and
24082d582f removed it.
The `pm_s2ram` group needs to belong to some group to not show up in
the topmost `Modules` list.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
kconfig options should be *merged* instead of *appended*, otherwise
search index can be huge, among other side effects.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The shell script did not provide -RealEncryption=1 which then never
really did proper encryption, which is the point of the test.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Clean up documentation pages for the new perf tool
as they contained several typos, grammar errors, and
duplicated content between main doc page and sample
page
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
If the value in the period_cycles variable exceeds UINT16_MAX, a 16-bit
timer will return an error code 134. An error message was added to
indicate that the value does not fit into the 16-bit timer register.
An error message advising developers to reduce the value to 16-bit
simplifies the process, allowing them to understand immediately that
reducing the value will resolve the issue.
Signed-off-by: Marek Sroka <m.sroka14@gmail.com>
Trigger the TX processor on connection teardown.
When a disconnection happens before the controller has acknowledged some
ACL fragments the host has sent, we run `process_unack_tx()` to free
those unacknowledged buffers and their associated TX contexts.
The problem is that the TX processor still holds a reference to the conn
object. That reference is not released until the TX processor is
triggered again and figures out that the connection is invalid.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Verifies that we don't leak connection references when the peer goes out
of range whilst we are fragmenting and sending data to the controller.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Updated `link_mode` assignment to reflect the actual negotiated PHY mode
by using `esp_wifi_sta_get_negotiated_phymode`.
Since `ap_info.phy_11b` ... `ap_info.phy_11ax` represent the access point
capabilities and not the actual current link mode.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Fix missing invalid aux offset check that was being caught
in a development assertion check. If aux offset where less
than the PDU time of the primary channel PDU, radio was
redundantly being setup delayed for reception that was
being caught in an assertion check.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Notify only if the device configuration has changed. Pass only the
configuration value as the message status, the actual device speed can
be obtained with usbd_bus_speed().
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Remove dead code. The write opcode instruction
is set based on dev_data a couple of lines after.
This was supposed to be in the merged "memory map
support for other modes" PR.
Signed-off-by: Georgij Cernysiov <geo.cgv@gmail.com>
Fix confusing `TypeError: 'type' object is not subscriptable`
at _get_installed_packages() if twister runs on python version < 3.9
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
native_posix is deprecated, let's switch the
description & comments to refer to native_sim instead.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
An ifdef should have been also checking for native_sim,
let's correct it.
Note: By now native_sim builds with "native_posix compatibility mode"
enabled, which sets BOARD_NATIVE_POSIX to avoid breaking all this kind
of dependencies. But that will stop soon.
So let's fix the dependencies.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
A few tests were only allowed for native_posix, but we are
deprecating it. Let's switch them to native_sim instead.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is being deprecated, let's switch this test to native_sim
instead.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is being deprecated, let's switch this test to native_sim
instead.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Add support of sys_poweroff API on m2l31x series.
It could support SPD0~2 standby or DPD0~1 deep power down mode.
Signed-off-by: cyliang tw <cyliang@nuvoton.com>
This test create a setup where an ISO broadcaster will send fragmented
data and get stopped after sending the first fragment and repeating that
operation multiple time to verify that buffers are not leaked.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
When sending data using ISO and the data is fragmented, if the
connection is cut before all the fragments are sent, the data buffer
will be leaked.
Fix the issue by unref'ing the buffer when ISO is not in a connected
state.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
When disconnected while sending data, if ISO doesn't get the number of
completed packets it will not call `process_unack_tx` and thus will leak
TX context.
Fix that by setting the connection state in ISO disconnection which will
trigger a call to `process_unack_tx`.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>
Enable the driver using the standard mechanism used everywhere else in
the tree. It is possible here as it is a singleton, so there's no
dependency on nrfx instantiation magic.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The BAP scan delegator test does not compile when
BT_BAP_BASS_MAX_SUBGROUPS is larger than 1.
Signed-off-by: Andries Kruithof <andries.kruithof@nordicsemi.no>
The comment should refer to the architecture, not one particular
board. Let's fix it.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Replace native_posix w native_sim in the comments,
and account for the fact that we have several nrf bsim targets now
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
It should have reffered to the architecture,
not one of its board's name.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix is deprecated. Let's remove its mentions
from the general docs and figures.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Deprecate the net_buf_put() and net_buf_get() functions.
Special handling of net_bufs in k_fifos is no longer needed after commit
3d306c181f, since these actions are now
atomic regardless of any net_buf fragments.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Convert users of net_buf_put() and net_buf_get() functions to use
non-wrapped putters and getters k_fifo_put() and k_fifo_get().
Special handling of net_bufs in k_fifos is no longer needed after commit
3d306c181f, since these actions are now
atomic regardless of any net_buf fragments.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
i.MX 93 EVK has a series of digital MUXes controlled by ADP5585 GPIO
expander. This commit adds board level initialization to such MUXes to
control these MUXes.
Signed-off-by: Chekhov Ma <chekhov.ma@nxp.com>
Add additional Microsoft OS 2.0 USB descriptor structures. These are
documented in the Microsoft OS 2.0 Descriptors Specification.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Support rgpio/lpuart peripherals
Support linkserver/jlink debug ways
Test cases: hello_world; button; blinky; synchronization; philosophers
There is one limitation with flashing and debugging the SoC's second
core(M7) that will be addressed with furture submission
Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
RGPIO model on RT1180 is same with igpio, however,
current driver can't support.
Update gpio driver to support gpio pad control
Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
The offset of the peripheral is abstracted so that
the peripheral can be defined in RT118x.dtsi,that
is a common dtsi file for RT1180.
Due to cm33 core, add ns/s files which are served
on different status for cm33 core.
Add rt118x_cm7 dtsi file
Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
Add new RT118x device, due to structure is different from rt11xx series.
Boot header also differ from rt10xx and rt11xx, so add support for boot
container.
define new container name and new container tag
Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
errno is a reserved macro. Use ret instead.
Fixes a bug introduced with commit
bfb541ccbe.
Fixes#76751.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The processing order is relevant if the IRQ handler call is delayed and
multiple interrupts are pending. Handle USB SoF before other interrupts
to ensure that it would be reported before other USB events (e.g. before
completed USB data transfers).
Signed-off-by: Marek Pieta <Marek.Pieta@nordicsemi.no>
Add DMA channels to test overlay files as DMA support is now available
for MAX32 I2C driver.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
MAX32 I2C peripheral can benefit from DMA transfers. This patch adds
DMA support for transactions made in controller mode.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
This adds platform_allow to limit the scope of platforms to
build and run. This avoids the need to constantly nudge
the platform filter lists to exclude platforms which fail
to build or run due to incompatible kconfigs.
Fixes#76945
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit fixes potential unpredictable behavior, caused by using
the ^ form of ldmia instruction, while exiting an exception in SMP
mode on Cortex-A/R.
Change:
Use "pop" instead of "ldmia" to restore user mode registers while
exiting from an exception via `z_arm_cortex_ar_exit_exc`.
Reason for change:
Processor mode is always set to system (MODE_SYS) before calling
`z_arm_cortex_ar_exit_exc` and hence, the user mode register can be
accessed directly without the ^ form of the instruction. Also, LDMIA
instruction is UNPREDICTABLE in SYStem mode.
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
This commit fixes the unpredictable behavior, caused by using the
^ form of stmdb instruction, while entering an exception in SMP mode
on Cortex-A/R.
Change:
Use "push" instead of "stmdb" to store user mode registers on
stack while entering an exception in SYStem mode.
Reason for change:
As reported in discussion/#75339, processor is already in SYS mode
after entering `z_arm_cortex_ar_enter_exc()` in an exception and
using stmdb is UNPREDICTABLE in system mode. Also, the user mode
register can be accessed directly without the ^ form of the
instruction. The solution suggested to fix this is to use
`stmdb sp!, {r0-r3, r12, lr}` which can save the user registers,
update the SP and avoid an extra instruction.
We use "push {}" instruction instead since it is the preferred
mnemonic over `stmdb`.
Signed-off-by: Sudan Landge <sudan.landge@arm.com>
This commit enables pyOCD support for the STM32F429I Discovery board.
Signed-off-by: Dominik Lau <dlau@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
The commit ad63ca284e replaced
default value of 65535 to UINT16_MAX. That change might cause
confusion as it suggests that the HEAP size is limited to UINT16_MAX.
For this particular scenario, 65535 bytes is a resonable amount of
HEAP to allow both Wi-Fi and BT working in coexistance, which could be
increased as per application.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
The RTC alarm and update fakes where not defined correctly. This
commit adjusts them to match the RTC API.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Sample was modified to enable pull-down when using EXT1 pins for
wake-up on deep sleep sample in order to simplify testing in case
user doesn't notice external pull-down will be needed otherwise.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Clock is disabled at startup for LP core peripherals, greatly
improving power consumption in deep sleep mode.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Port of similar change in arm64 that eliminates exclusive load/store
instructions, which may not work when MMU/MPU/cache are disabled.
Based on: 7904c6f0f3
Signed-off-by: Stan Skowronek <stan@corellium.com>
The base address of H2RAM can be as large as KB(CONFIG_SRAM_SIZE), so
the mask for the H2RAM address should be (KB(CONFIG_SRAM_SIZE)-1).
This PR corrects the size of the mask.
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
Let's link from the deprecated instructions,
To increase visibility and hopefully avoid developers forgetting to
do so.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Let's link to the deprecated instructions.
To increase visibility and hopefully avoid developers forgetting to
do so.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Let's link from the deprecated instructions.
To increase visibility and hopefully avoid developers forgetting to
do so.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
1.16 was not meant to be a release, and 1.14 was long ago.
Let's use as example something much more recent.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
When deprecating APIs,
let's tell users to add to one GitHub issue tracking all
deprecated APIs meant to be removed,
so the process is simpler and hopefully developers do it.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
In order to mitigate side channel attacks, even if the PWE is found the WPA
supplicant goes through full iterations, but in some low-resource systems
this can be intensive, so, add an option to exit early.
Note that this is highly insecure and shouldn't be used in production
Signed-off-by: Gang Li <gang.li_1@nxp.com>
This should be configurable by applications in case a full CLI interface
to the WPA supplicant is needed.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
To demonstrate the usage of the UATT MTU API to determine if a payload
with its associated length can be sent over a GATT notification.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
Replace `shell_fprintf(sh, SHELL_ERROR, ...)` with
`shell_error(sh, ...)` since it brings the same underlying
action with less typing.
Note: `shell_error` already concatenates `\n` to format strings,
so we remove `\n` from the original code.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Utilize a code spell-checking tool to scan for and correct spelling errors
in `subsys/testsuite/ztest/src/ztest.c` file.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Now that the dts/bindings filter has been removed from
Devicetree Binding area, this area serves no real purpose.
Move the include/dt-bindings files to their respective areas.
Fix some of the orphaned dts/bindings paths.
Add regex filter for any binding with "zephyr" in the name to be
in the devicetree area.
Fix the imx_spc.h file being in it's own pm/ folder instead of
power/ like the other power related headers.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
- Add SENSOR_ATTR_GAIN and SENSOR_ATTR_RESOLUTION
- Remove SENSOR_ATTR_GAIN from tsl2540 header
Signed-off-by: Daniel Kampert <DanielKampert@kampis-elektroecke.de>
Improve DUT selection at DeviceHandler: for each DUT it counts
how many test instances have been failed on it during the current
twister execution, so the next available DUT will be chosen
ordering the eligible DUTs by less failures occured so far.
The new selection mechanism should increase chances to retry failed
tests on different DUTs, for instance to resolve ploblems when some
DUTs have connectivity or HW issues slowing down test plan execution,
or even block the execution when only one test suite runs whereas
the same first DUT candidate in the list is not working and others
were not chosen.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Change Twister PyTest plugin's test finalizing sequence to release
the DUT it is used as the very last operation, after the Test Instance
status becomes fully updated from the execution results.
This also fix a race condition possible when pytest plugin releases
the DUT and it becomes acquired by another test while the current test
is not yet finalized completely.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Twister DeviceHandler - add test failure counter for how many
test instances have been failed on each DUT (Device Under Test)
when it executes the current test plan.
Output DUT falure counter summary at the end of Twister run.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Fix Twister DeviceHandler exit on SerialException when
it connects to the serial device in 'flash before' mode.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
Several improvements at Twister DeviceHandler when it releases
current DUT (Device Under Test):
- release the exact DUT which is used for the test instance
instead of all configured DUTs which happened to have
the same serial device configured.
- Twister PyTtest harness plugin adjustment to the above.
- additional debug logging to track DUT waiting/retain/release.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
accelerometer range is not suffixed with 'G' in the header
and also in the usages, but bindings use with suffix 'G'.
remove the suffix 'G' to have same reference.
Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
The current driver implements the global defined "systick" interrupt
callback "sys_clock_isr" as a standard C function with an argument.
However, ARM's direct interrupt handlers do not have any arguments;
they must be declared as "void handler(void)".
Additionally, the direct handler should include some missing special
header/footer.
Fixes: #75693
Signed-off-by: Andrey VOLKOV <andrey.volkov@munic.io>
Relocate common properties from dedicated SOC's related
Cortex-M SysTick DTS files into the new generic
'cortex-m-systick.yaml' one.
Signed-off-by: Andrey VOLKOV <andrey.volkov@munic.io>
Replace useless "TICKLESS" define by
IS_ENABLED(CONFIG_TICKLESS_KERNEL) one, and replace error-prone
'cycle_t' pseudotype defs by real typedefs.
Signed-off-by: Andrey VOLKOV <andrey.volkov@munic.io>
XTENSA_CCOUNT_HZ is no longer common to ACE soc series
This will fix Hz value for ACE30 platform
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@intel.com>
The OK response should be processed before entering CMUX mode.
Use UART ISR mode by default.
Fix warnings and errors produced by the sample.
Signed-off-by: Ryan Erickson <ryan.erickson@ezurio.com>
When the PHY is hardware designed to communicate on address '1', the mdio
node of the device tree is labeled 'ethernet-phy@1'.
Therefore, STM32 HAL must adapt to resolve the appropriate DT node:
'ethernet_phy_1'.
Signed-off-by: Alex Fabre <alex.fabre@rtone.fr>
Introduced `MODEM_CELLULAR_DEFINE_INSTANCE` macro to streamline
the definition and initialization of modem cellular instances.
This macro enables passing parameters that vary among modems, including:
`power_pulse_duration_ms`, `reset_pulse_duration_ms`, `startup_time_ms`,
`shutdown_time_ms`, `autostarts`, `init_chat_script`, `dial_chat_script`
and `periodic_chat_script`.
This will reduce the number of redundant lines in the code, aiming for
improved maintainability.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Introduced the `MODEM_CELLULAR_DEFINE_AND_INIT_USER_PIPES` macro to
consolidate multiple user pipe data definitions into a single macro call.
This will reduce the number of redundant lines in the code, aiming for
improved maintainability.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
SPI pins are defined in board.dts file to simplify usage
so that no need to redefine it in overlay files
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Enable SPI test for MAX32662EVKIT.
SRAM size increased to get enough space for SPI test image
Co-Authored-By: Sadik Ozer <sadik.ozer@analog.com>
Signed-off-by: Furkan Akkiz <hasanfurkan.akkiz@analog.com>
Add MAX32655FTHR and MAX32655EVKIT board configuration for SPI loopback
test. Supports interrupt and asynchronous transfers as well as 16-bit
frames.
Co-Authored-By: Sadik Ozer <sadik.ozer@analog.com>
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
nrfutil is becoming the default tool for flashing Nordic devices.
Default to it for the nRF54L15.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
As nRF54L15 supports retained_mem driver,
this test should be executed on this target.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
Now retained_mem driver can utilize nrfx_ram_ctrl helper
for nRF devices. It provides abstraction over various RAM retention
peripherals like POWER, VMC or MEMCONF.
Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
It's usual to show debug logs as blue.
Showing dbg and info with different colors are good,
but it's preferable to keep info logs with default
color.
Signed-off-by: Félix Piédallu <felix@piedallu.me>
Don't pulse the enable pin on boot if the device is going to immediately
go into suspend mode via `zephyr,pm-device-runtime-auto`.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Some tests have a compile script for that test alone, named
`_compile.sh` or `_build.sh`. These scripts are useful for developers to
avoid compiling the world. But these scripts were not run in the CI.
These scripts were previously not suitable for running in the CI because
would put the artefact in the source directory, but this is no longer
the case, and the CI could run these scripts now.
This commit renames any `<test>/test_scripts/_compile.sh` and
`<test>/test_scripts/_build.sh` to `<test>/compile.sh`. The test runner
in CI will ignores any file named `compile.sh`, so there is no need for
a underscore prefix.
This fits into and extends the hierarchical structure of `compile.sh`
chain that starts at `:/test/bsim/compile.sh`, the CI build script tree.
The newly moved scripts now become a part of the build script tree,
called from a `compile.sh` where a duplicate set of build commands was
before. The sub scripts use `run_in_background` to preserve the
parallelism as it was before this change.
This removes an error-prone duplication and makes the CI test all the
build scripts.
Tests that did not have any compile script are not given one for now.
Signed-off-by: Aleksander Wasaznik <aleksander.wasaznik@nordicsemi.no>
Updated the Pytest-Harness methods to capture and log error messages from
the subprocess, when pytest command fails.
Ensured that error messages are logged with `--inline-log` option
and placed in twister log reports.
Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
Put disconnected GPIOs to high impedance state by setting their
direction to input and pad control to none.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Z_SPIN_DELAY already behaves differently in
POSIX arch based targets and real targets
there is no need to ifdef around it.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
The sys_define_gpr_with_alias macro was defined by arch.h,
but was used by the two exception.h files that did not include it.
Attempting to include arch.h from exception.h would resolve
in a recursive include, so the macro was simply moved to the
files that used it.
An alternative could have been to define a new file that defined it,
that could have been included by exception.h
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
As commit 6a1d9877ef ("cmake: Add LL_EXTENSION_BUILD to EDK flags")
made clear, only building an application with the EDK is not enough to
prevent regressions. This patch address that by also running the
application using the extension built with the EDK.
To provide a more comprehensive test, the application runs the extension
code on both kernel and user space, using a parameter sent by the
application. Assertions on the output from the application are used to
ensure expected results.
For now, tests only run on qemu_cortex_r5, but this can be expanded in
the future.
Signed-off-by: Ederson de Souza <ederson.desouza@intel.com>
While the option to inform pytest about which platform a test is for
(platform being the board, such as mps2/an385) is available, it wasn't
being used. This patch fixes that, by building a pytest command which
includes the platform.
Signed-off-by: Ederson de Souza <ederson.desouza@intel.com>
Add a new fixture, `unlaunched_dut`, which is basically the `dut`
one, but without launching the device - thus also not building the
application. It is useful for tests who need a finer control of
the building of the application, before the dut can be launched
to run it.
It will be used on a future patch, which will use it to enable LLEXT EDK
tests.
Signed-off-by: Ederson de Souza <ederson.desouza@intel.com>
As discussed internally, add evgeniy-paltsev as a co-maintainer for
ARC and Synopsys areas.
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
Migrate drivers/timer/*arcv2* from CODEOWNERS to MAINTAINERS
by adding it to ARC architecture entry
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
* migrate dts/arc/ from CODEOWNERS to MAINTAINERS
* drop iriszzw as not working in Synopsys anymore
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
The frame event callback unconditionally copies into the enqueued video
buffer. The driver only supports fixed length frames, so reject enqueued
buffers that are not large enough to prevent invalid memory access.
Signed-off-by: Brett Witherspoon <brett@witherspoon.engineering>
The auto-pts project is now days hosted under an independent organization
instead of the intel one.
Signed-off-by: Johan Hedberg <johan.hedberg@silabs.com>
Fix after #71401 merge at Twister Reporting:
* filter status value type mismatch;
* tesplan.json generation incorrect error logs.
Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
The driver can run in either native_posix or native_sim.
Let's make sure to set the dependencies acordingly.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
LwM2M SEND functionality is defined in LwM2M v1.1
So quard the condition with protocol version, not
server object version.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
The Host Interface Type in the DEVCNT register sets the HIF type
(either eSPI or LPC).
Currently, it is configured in the host-interface-related drivers like
eSPI or SHI. However, some I/O pads sourced from VHIF in the other
modules such as GPIO and I3C also rely on this field. It might be
problematic when using those I/Os without enabling eSPI or SHI drivers.
This commit moves the setting from the specific drivers to the global
system initialization function scfg_init().
Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
Introduce Controller dependent EVENT_MAFS_MIN_US value to
use as the value when populating the aux offset between
Extended Advertising primary and auxiliary channel PDUs.
This can be used as workaround for peers having difficulty
receiving Extended Advertising PDUs with near 300 us MAFS
values used in aux offset calculations.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Propose myself as collaborator to areas I have contributed to lately
in order to more easily follow/take part in them and help in those
where there was no collaborator.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Merge "TF-M integration" into "West project: trusted-firmware-m".
The former was a superset of the latter.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
Merge "Mbed TLS" into "West project: mbedtls".
Also, change the label to a more fitting one.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
As Renesas Hal is not compatitble with C++98 we use
filter CONFIG_HAS_RENESAS_RA_FSP to skip the test
Signed-off-by: Duy Nguyen <duy.nguyen.xa@renesas.com>
Initial support for EK-RA8D1 board this commit
only support basic GPIO and Serial driver for
RA8D1 board
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
Initial commit to suppor RA8D1 SoC
This is deveop base on RA8M1 so it will have similar stucture and
feature
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
Relax the radio packet pointer assignment deadline assertion
until access address being transmitted. The PDU buffer is
probably only needed just after access address is being
transmitted or received by the radio. This will give some
more breathing room for slow CPUs like in nRF51x SoCs.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix regression using speed optimization introduced in
commit 1b7fe792e0 ("Bluetooth: Controller: Support Link
Time Optimizations (LTO)").
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix regression in encrypted connection introduced in
commit f3deccda91 ("Bluetooth: Controller: CCM read data
to early when DF enabled on PHY 1M").
Due to this nRF51x SoC hang waiting to encrypt and/or
check MIC.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
In case of ISR latencies, if packet pointer has not been
set on time then we do not want to check uninitialized
length in rx buffer that did not get used by Radio DMA.
This would help us in detecting radio ready event being
set? We can not detect radio ready if it happens twice
before Radio ISR executes after latency.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Only 3 bytes (PDU_EM_LL_SIZE_MAX) is required for empty PDU
transmission, but in case of Radio ISR latency if rx packet
pointer is not setup then Radio DMA will use previously
assigned buffer which can be this empty PDU buffer. Radio
DMA will overrun this buffer and cause memory corruption.
Any detection of ISR latency will not happen if the ISR
function pointer in RAM is corrupted by this overrun.
Increasing ISR latencies in OS and CPU usage in the
ULL_HIGH priority if it is same as LLL priority in
Controller implementation then it is making it tight to
execute Controller code in the tIFS between Tx-Rx PDU's
Radio ISRs.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix ISR profiling when using single timer for tIFS radio
switching wherein in the timer is cleared on every radio
end. Hence, the captured timer value is the latency and
does not required the radio end timestamp to be subtracted.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Use uint16_t to store ISR profiling value to avoid overflow
in case of higher latencies.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Fix in-system ISR profiling for advertiser and connection
role for the missing implementation when there is CRC error.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
The interval and latency for a CIG are set for each direction now,
allowing applications to use e.g. 10ms for sink ASEs and 7.5ms for
source ASEs.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Gets experimental and deprecated symbols directly from Kconfig instead
of rely on hardened.csv.
This way we keep the tool consistent with Zephyr's code.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
Add name to choice symbol, so that default value can be changed
downstream.
Developed-by: Andreas Rudolf <andreas.rudolf@husqvarnagroup.com>
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
Add name to choice symbol, so that default value can be changed
downstream.
Developed-by: Andreas Rudolf <andreas.rudolf@husqvarnagroup.com>
Signed-off-by: Reto Schneider <reto.schneider@husqvarnagroup.com>
- Remove the `strlen`, as it is unnecessary for safe copying.
- Limit the `strncpy` to `sizeof(fsm->terminate_reason) - 1`
to ensure the last byte is reserved for null-termination.
- Add an explicit null terminator to guarantee correct string termination.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Instead of disabling code with a specific compilation switch, enable it
and apply `__maybe_unused` in the `ns16550_outword` and `ns16550_inword`
functions to make the codebase cleaner.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Correct the following typo in Kconfig and
the corresponding function.
- Kconfig.it8xxx2 from `BUADRATE` to `BAUDRATE`
- Correspoding function from `burdrate` to `baudrate`
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
The max window time of RaspberryPi Pico WDT is 8,388,607 us(0x7FFFFF),
But 20,000ms have been set.
Correcting the value to 8,000ms to pass the test.
This was a problem that was discovered because the fix in
ccedcd1ac0 now properly handles the error.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Cloning a packet for a capture may fail due to insufficient memory.
In such a case, the networking statistics should be updated
to reflect this processing error. This commit updates the processing
error count on the capture tunnel network interface because this is
the interface that the captured packet would have been assigned to.
Signed-off-by: Tom Finet <tomfinet@outlook.com>
xtensa_mmu_init() is called really early in the boot process
where the _kernel struct has not yet been initialized, and
thus we cannot use it to determine if the current CPU is
the boot CPU. In some cases, this may skip the call to
initialize the page tables which leaves us with incorrect
page table entries. Fix it by using a static variable to
determine whether the page tables have been initialized so
we only do it once per boot.
Fixes#76909
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Samples, that were obtained by profiling perf tool, can be be translated
into flamegraph using stackcollapse.py script.
Originally-by: Yonatan Goldschmidt <yon.goldschmidt@gmail.com>
Signed-off-by: Mikhail Kushnerov <m.kushnerov@yadro.com>
Implement stack trace function for x86_32 arch, that get required
thread register values and unwind stack with it.
Signed-off-by: Mikhail Kushnerov <m.kushnerov@yadro.com>
Implement stack trace function for x86_64 arch, that get required
thread register values and unwind stack with it.
Originally-by: Yonatan Goldschmidt <yon.goldschmidt@gmail.com>
Signed-off-by: Mikhail Kushnerov <m.kushnerov@yadro.com>
Implement stack trace function for riscv arch, that get required
thread register values and unwind stack with it.
Signed-off-by: Mikhail Kushnerov <m.kushnerov@yadro.com>
Add profiling subsystem.
Add perf util based on periodic stack unwinding. Perf from Linux
was taken as a reference.
The operation of module is based on frame pointer usage and saving
registers during interruption handling.
The unwinding function stay in timer as expiry functioin so is called
during interruption handling. Thus the function have access to saved
registers (program counter and frame pointer in particular) of the current
thread and use it to unwind the thread stack.
Timer starting and results printing function are made as shell commands
for conveniency.
Originally-by: Yonatan Goldschmidt <yon.goldschmidt@gmail.com>
Signed-off-by: Mikhail Kushnerov <m.kushnerov@yadro.com>
Move samples config files from 'boards' to 'socs' in order to
remove multiple files with the same configuration and render
available samples for new boards. Only changed sample files
which are not board or hardware specific.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
The nrf7002dk board's wifi chip requires blobs to build wifi driver.
Therefore it can not be built by CI. Exclude the board and its
variants from the wifi test suite.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
Some new Nordic nRF SoCs are based on a common platform, named
'Haltium'. Introduce a selectable Kconfig option available for series to
flag they are part of such common platform. This will allow to easily
enable common code shared across all Haltium based products.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
When application code runs from M4 (resides on lower 896KiB of
the internal flash of bank2) and it does write to a block in
the upper 128KiB, write fails sometime (for example failed
1 out of 10 block write based on the tests) due to STRBERR.
As per technical reference manual section 4.7.4 of
STM32H745/755 SoC, application may ignore this error and
continue with write. So check for the flag and return okay
status for write(). Based on our tests, the application write
succeeds even when this error happens and match with document
description. So igoring this error flag is okay during write.
Signed-off-by: Murali Karicheri <murali.karicheri@sandc.com>
Refactor (1 << xyz) to use the BIT(xyz) macro.
The change aims to enhance code readability.
Signed-off-by: Muhammad Haziq <muhammad.haziq@zintechnologies.com>
is_dblexc is constant for targets without MMU. There is no need
to check it when building without MMU.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
The `struct bt_l2cap_le_chan` and `struct bt_l2cap_br_chan` objects
should be memset before passing them to the stack.
This was not stated anywhere, but all the in-tree users are doing it, so
it must be API.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
When the native simulator use was introduced,
the POSIX architecture and SOC were split in 2 versions:
One was the old version, which remained used by native_posix and the
other NATIVE_APPLICATION based targets.
The new version was a shim on top of the native simulator threading
and CPU start/stop emulation.
This was done to ensure no regressions were introduced in the old
targets while the native simulator was tested and matured.
The old SOC code was removed a small while after, and all
NATIVE_APPLICATION targets moved to use the shim version on top of the
native simulator.
Now we remove also the old arch code, so native_posix and its
NATIVE_APPLICATION kin, also use the native simulator NCT component
instead.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
native_posix has been replaced with native_sim.
Users have been encouraged to switch since 3.6.
We deprecate it now, and plan to remove it in 4.2.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
gcc 13 thinks max_adv_duration may be used unitialized
and warns accordingly (see below)
It seems the reason is the goto, which confuses it.
In any case, pacifying this warning is trivial,
so let's just do so.
The warning:
```
In function ‘gatt_proxy_advertise’,
inlined from ‘bt_mesh_proxy_adv_start’ at
subsys/bluetooth/mesh/proxy_srv.c:1214:9:
subsys/bluetooth/mesh/proxy_srv.c:842:44: error: ‘max_adv_duration’ may
be used uninitialized [-Werror=maybe-uninitialized]
subsys/bluetooth/mesh/proxy_srv.c: In function ‘bt_mesh_proxy_adv_start’
zephyr/subsys/bluetooth/mesh/proxy_srv.c:786:17: note:
‘max_adv_duration’ was declared here
786 | int32_t max_adv_duration;
| ^~~~~~~~~~~~~~~~
```
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Up to now there was only support for parsing/encoding 32-bit integer
numbers, with no support for larger ones.
Introduce support for 'int64_t' type, so that large numbers can be
serialized into JSON payloads.
Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
Add more clarity to memory map log output.
Use LOG_DBG instead of LOG_INF to signal about
memory map mode being enabled.
Signed-off-by: Georgij Cernysiov <geo.cgv@gmail.com>
On ARM64 the build will fail with coverage and GCOV enabled:
CONFIG_COVERAGE=y
CONFIG_COVERAGE_GCOV=y
CONFIG_FORCE_COVERAGE=y
west build -b rpi_5 -p always samples/hello_world -- \
-DCONFIG_COVERAGE=y -DCONFIG_FORCE_COVERAGE=y
Failure:
"linker_zephyr_pre0.cmd:181: undefined symbol `__gcov_bss_end' referenced
in expression"
Fix build of ARM64 platforms with coverage and GCOV enabled by adding for
ARM64 the same gcov linker sections as it is done for ARM.
Signed-off-by: Grygorii Strashko <grygorii_strashko@epam.com>
The Tracing page did not cover the Percepio Tracealyzer support.
Added a guide for Tracealyzer with a screenshot (like SystemView has).
Moved the three tools to a common subsection for better overview.
(Updated with kartben patch.)
Signed-off-by: Johan Kraft <johan.kraft@percepio.com>
Add few other sensors support to steval_stwinbx1 board:
- IIS2MDC: 3-axis magnetometer
- ISM330DHCX: IMU, 3D accelerometer and 3D gyroscope
- IIS2DLPC: 3-axis accelerometer
- IIS2ICLX: 2-axis digital inclinometer
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Fix the sensor range setting at runtime which is currently returning error,
converting the SI (ms2) value passed thru SENSOR_ATTR_FULL_SCALE in mg (and
not in g) as this is the unit used in the driver internals.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
Do not fail when requested rate passed in SENSOR_ATTR_SAMPLING_FREQUENCY
is not matching any of the odr values supported by sensor. Instead, round
it up to the next one.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
The STM32 devices like stm32F0/G0/C0 which have a f0-rcc compatible
does not have APB2 prescaler : do not try to set it.
Signed-off-by: Francois Ramu <francois.ramu@st.com>
90ab94f61d added a change that source name pointers were not stored
in the const data structure associated with a logging source. That was
done because those string pointers were invalid (on purpose pointing to
non-existing memory) and reading those strings could lead to a fault.
However, those pointers are used by scripts which are building the
dictionary database and after this change script was no longer
able to retrieve source names from elf file and database was incomplete.
This patch brings back storing of source name string pointers but in
API for reading those source names guards are added to not return
invalid addresses.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Undefine _POSIX_C_SOURCE before defining it to avoid double
definition
The previous version, changed in this PR
https://github.com/zephyrproject-rtos/zephyr/pull/70363, did the undef.
Make sure to do the same for all files in the current dir.
Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
Add drivers/interrupt_controller/intc_gic* to the ARM platform area so
they get assigned to the ARM platform maintainers directly.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
When setting these pins as I2C alternate mode and then setting
GCR7 or func3-ext of GPIO extended, it will cause leakage.
In order to prevent leakage, it must be set to GPIO INPUT mode.
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
Add RTC driver support for NXP frdm_ke17z512, rtc doesn't exist on
frdm_ke17z board, delete rtc node from its dtsi file.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
Set LPO 1KHZ clock for RTC if clock source 'LPO' is selected.
The frdm_ke17z512 has no 32KHZ OSC, the RTC clock comes from SOSC,
RTC_CLKIN, LPO 1KHZ. But usually the SOSC is connected with 8MHZ
oscilator, so only 1kHZ LPO is usable.
Update the nxp,kinetis-rtc.yaml to select RTC clock source.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
Add pwm configuration for frdm_ke17z and frdm_ke17z512 boards.
Set the alias of pwm-0 to ftm2 and test the pwm_api sample.
Update the ftm and pwt configuration to test pwm_loopback sample.
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
Fixes repeated allocation of interrupt sources by successive calls
to esp_intr_alloc or esp_intr_enable for the same source.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Add an initial version of doxybridge, an extension that allows to use
Sphinx C domain to automatically reference Doxygen pages.
It also introduces minimal support for `.. doxygengroup` directive,
which effectively links to the group's Doxygen page.
Co-authored-by: Benjamin Cabé <benjamin@zephyrproject.org>
Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
When trying to build Zephyr with -Wignored-qualifiers this leads to a
compiler warning like:
zephyr/drivers/serial/uart_pl011_registers.h:40:1: error: type
qualifiers ignored on function return type [-Werror=ignored-qualifiers]
Since the return value is copied by the caller, making it const has no
effect and the compiler warns that this is being ignored. This enables
applications to build with additional compiler warnings turned on.
Signed-off-by: Benjamin Gwin <bgwin@google.com>
Adds an entry to the MAINTAINERS file claiming maintenance of the
haptics subsystem.
Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Added a websocket connection sending network statistics to a client, to
demonstrate how this can be used to push data to the client as an
alternative to GET requests triggered by a Javascript timer.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
Accept JSON payload including LED number and state, to demonstrate JSON
parsing and allow control of multiple LEDs if the board supports this.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
Previously the dynamic resource in the http_server sample simply echo'd
the received data back to the sender. This doesn't demonstrate how the
dynamic handlers would be used in a more typical use case, where the
application may need to wait for the full request before acting on it or
creating a response.
Therefore two new dynamic resources have bee added: a '/led' resource
which can be used to control the board's LED (if present) via a POST
request, and a '/uptime' resource which can be used to query the kernel
uptime via a GET request.
The static resources are updated with some javascript to support
demonstrating the new dynamic resouces via a web browser.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
Navin-Shankar is not part of Linumiz or Zephyr RTOS projects
anymore. Adding parthitce as colloborator for LZ4.
Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
lz4 is moved as optional module, add step in README to add
as project filter to include into west manifest.
Fixes: https://github.com/zephyrproject-rtos/zephyr/issues/65127
Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
all the external modules related samples are part of samples/modules,
whereas lz4 is in parent. move it to sample/modules/compression/lz4
Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
LZ4 is a fast compression and only of it's kind available
in Zephyr RTOS manifest. But it wasn't maintained to sync
with mainline version. This commit together with [1] PR
help updating to latest mainline release version of LZ4.
[1]: https://github.com/zephyrproject-rtos/lz4/pull/2
Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
Previously, configuring the GDMA was limited to a single descriptor,
restricting memory transfers to a maximum of 4kB.
This update introduces support for multiple descriptors, enabling users
to define multiple dma_blocks. The maximum number of descriptors can be
configured via the CONFIG_DMA_ESP32_DESCRIPTOR_NUM option.
Additionally, the dma_get_status() function now reports the index of the
currently processed descriptor
through the status.read_position and status.write_position fields.
Signed-off-by: Armin Kessler <ake@espros.com>
Incorrect status assignments were previously just warnings in logs.
Now they are elevated to errors.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
Various different Statuses were joined into a single class,
TwisterStatus. This change anticipates further streamlining
of the Twister's approach to Status.
Code guarding Twister's Properties was shortened to a
value check only.
QEMUOutputStatus was left separate, as doubts were cast
whether it should remain a status. Leaving it separate makes
its removal easier.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
TestInstanceStatus of TIMEOUT and FLASH were never really used.
They were checked for, but never assigned.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
Now statuses are not just a str that can be easily mistyped
or assigned wrong. Now they are an Enum.
Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
- Made CCC_STORE_MAX configurable under the BT_SETTINGS
- Added a buffer overflow check on ccc_save
Fixes: #76838
Signed-off-by: Yago Fontoura do Rosario <yafo@demant.com>
Using DEVICE_DEFINE, a device without a corresponding DT node can be
defined (for example CRYPTO_MTLS), Z_DEVICE_INIT() does not initialize
dt_meta for such devices, leaving the field as NULL.
device_get_dt_nodelabels() and functions calling it have to handle
dev->dt_meta == NULL to prevent fatal errors.
Signed-off-by: Jan Peters <peters@kt-elektronik.de>
http1_headers_sent flag has to be cleared when entering
HTTP_SERVER_REQUEST_STATE and not only on the client init. Otherwise,
serving multiple HTTP1 POST requests over the same connection does not
work as intended (headers were not sent for the second and further
requests).
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Fixes#64149
Add support for a new Kconfig symbol: BUILD_OUTPUT_ADJUST_LMA_SECTIONS.
This is supplemental to the existing BUILD_OUTPUT_ADJUST_LMA setting,
which normally adjusts all output sections' LMA by the provided offset.
Defining the new symbol will narrow down the set of applicable sections
to a user-specified CMake list of name patterns.
Example usage:
DT_CHOSEN_Z_FLASH = zephyr,flash
DT_CHOSEN_Z_SRAM = zephyr,sram
config BUILD_OUTPUT_ADJUST_LMA
default "$(dt_chosen_reg_addr_hex,$(DT_CHOSEN_Z_FLASH)) - \
$(dt_chosen_reg_addr_hex,$(DT_CHOSEN_Z_SRAM))"
config BUILD_OUTPUT_ADJUST_LMA_SECTIONS
default "*;!bss;!noinit"
Supported values for BUILD_OUTPUT_ADJUST_LMA_SECTIONS are aligned with
objcopy, since this feature has only been supported with GNU binutils
thus far.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Added support for the Sparkfun Thing Plus Matter MGM240P board.
For more information about this board please check:
https://www.sparkfun.com/products/20270
Signed-off-by: Teresa Zepeda Ventura <teresa.zvent@gmail.com>
Adds a sysbuild Kconfig to select the operating mode of MCUboot
which is then propagated to the MCUboot and application images
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Increase the counter timer prescaler for some instances of NXP System
Timer Module, so that late alarms and short relative alarms are
excercised.
Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
Support short relative and late alarms for NXP System Timer Module
counter driver. The late alarm detection algorithm applied, is based on
existing counter drivers.
Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
RA4M1-specific options were being applied system-wide because
conditions were not set properly.
This change fixes this problem.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Instead of forcing users to provide this setting, allow to describe
which signals require CLOCKPIN enablement at device nodes. This is later
captured by the pinctrl macros and applied in the pinctrl driver. Note
that name has been adjusted to nordic,clockpin-enable to avoid confusion
with clock related settings.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Make appending to the newest log file in the fs logging backend optional.
By default, if there is still free space in the latest log file,
the fs logging backend appends to it on startup. This is useful for saving
space and avoiding the removal of older log files, if the maximum number
of log files has been reached. The drawback of this behavior is,
that log files that got appended can not be decoded, if the firmware
has changed between startups, for instance by an update,
since the log_dictionary.json used for decoding has also changed.
Therefore, it may be desirable to deactivate appending to log files.
Signed-off-by: Niklas Fabian <niklas.fabian@lemonbeat.com>
Code size can significantly reduced (220 bytes per instance) if data
structure (stored in RAM) is not initilized (can be moved to .bss).
Data for asynchronous API had two fields which can easily be moved
to the configuration structure (which is in ROM) because they do not
change duing runtime.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
When runtime configuration is not enable then we can determine at
compile time what are the hardware settings. Function which
translates zephyr values to nRF register values is not needed as
macros can do that at compile time.
This optimization saves almost 400 bytes of code.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Enabled ENET ethernet port on Cortex-A Core for imx8mn EVK board.
Updated document for supported features.
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
Enabled ENET ethernet port on Cortex-A Core for imx8mm EVK board.
Updated suported featues in board document.
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
custom arch_cpu_idle and arch_cpu_atomic_idle implementation was done
differently on different architectures. riscv implemented those as weak
symbols, xtensa used a kconfig and all other architectures did not
really care, but this was a global kconfig that should apply to all
architectures.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Clear the UNALIGN_TRP bit in the CCR register, if the config
CONFIG_TRAP_UNALIGNED_ACCESS is not set.
Despite the fact that the reset value of UNALIGN_TRP is 0, always clear
the bit. It is useful in double image systems. The new image can't rely
on settings left by the previous image.
Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
The LLEXT EDK was not exporting common Zephyr compile definitions
("-Dxxx" flags). This patch adds the compile definitions before the
other compile flags, as it is done in the Zephyr build system.
This patch also adds to this list the "-DLL_EXTENSION_BUILD" flag,
instead of providing a special case at a later stage.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
The variable llext_edk_cflags was used in the main CMakeLists.txt file,
while llext_cflags was used in the llext-edk.cmake file. This commit
unifies the variable names to use llext_edk_cflags in both files.
No logic changes are introduced by this commit.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
gcc 13 produces a build warning (see below), as it seems to
believe the number of read bytes may overflow the frame_size
type.
Let's increase the frame_size bitwidth to avoid this.
(Any 32bit type, signed or unsigned, avoids this warning)
The build warning:
```
In file included from /usr/include/features.h:502,
from bits/libc-header-start.h:33,
from /usr/include/stdint.h:26,
from include/stdint.h:9,
from zephyr/include/zephyr/types.h:11,
from zephyr/include/zephyr/kernel_includes.h:21,
from zephyr/include/zephyr/kernel.h:17,
from zephyr/drivers/bluetooth/hci/userchan.c:9:
In function ‘read’,
inlined from ‘rx_thread’ at drivers/bluetooth/hci/userchan.c:201:9:
/usr/include/i386-linux-gnu/bits/unistd.h:28:10: warning: ‘__read_alias’
specified size between 4294902273 and 4294967295 exceeds maximum object
size 2147483647
[-Wstringop-overflow=]
28 | return __glibc_fortify (read, __nbytes, sizeof (char),
| ^~~~~~~~~~~~~~~
drivers/bluetooth/hci/userchan.c: In function ‘rx_thread’:
drivers/bluetooth/hci/userchan.c:187:32: note: destination object allocated
here
187 | static uint8_t frame[512];
| ^~~~~
/usr/include/i386-linux-gnu/bits/unistd-decl.h:29:16: note: in a call to
function
‘__read_alias’ declared with attribute ‘access (write_only, 2, 3)’
29 | extern ssize_t __REDIRECT_FORTIFY (__read_alias, (int __fd, void
| ^~~~~~~~~~~~~~~~~~
```
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Allows RTT inizialization function to either init Cntrol Block always
or initialize only after checking it it's not already initialized by
another program, typically by a bootloader.
Signed-off-by: Giancarlo Stasi <giancarlo.stasi.co@gmail.com>
Use recommended write API that internally locks RTT usage and checks
if the RTTcontrol block initialization is done.
Signed-off-by: Giancarlo Stasi <giancarlo.stasi.co@gmail.com>
Allows optionally placing Segger RTT data either in a specific
linker section that is located at RAM start, or in a specific linker
section defined by a memory region in DTS, as third and fourth
alternative to the DTCM section or the default data section.
This is useful to share the fixed address for different programs,
typically bootloader and application, and have seamless logging.
Signed-off-by: Giancarlo Stasi <giancarlo.stasi.co@gmail.com>
Print the ISR & its ARG along with the IRQ and Hits in
`plic stats get <intc>` command, i.e.
```CONFIG_SYMTAB=n
uart:~$ plic stats get interrupt-controller@c000000
IRQ Hits ISR(ARG)
10 541 0x800054ee(0x80008170)
```
```CONFIG_SYMTAB=y
uart:~$ plic stats get interrupt-controller@c000000
IRQ Hits ISR(ARG)
10 114 uart_ns16550_isr(0x80008230)
```
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
This function call frees the buffer kept by the host for reassembling L2CAP
PDUs into.
Without this call, the current buffer will eventually be
leaked, leading to a non-functional host due to lack of RX buffers.
The effect is worse when host flow control is not enabled, as the RX
buffer pool is shared with events, which means communication with the
controller is essentially dead.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
`net_buf_alloc(K_FOREVER)` can now return NULL if running in the system
workqueue. `bt_hci_evt_create()` is called in that context in a few cases.
Since we can't really do anything about it, add a (default-on) assert.
This should ideally never fail. I saw it fail because of a leak in the ACL
buffer pool, which is also shared with events when host flow control is not
enabled.
In that particular case, the host is rendered non-functional, so trying to
recover using error handling is futile.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Add a test that verifies no resources are leaked when re-assembling L2CAP
PDUs over an unreliable channel (ie. lots of disconnects).
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Remove wpa_supp_els_pkc_mbedtls_config.h, as this header file
contains PSA_CRYPTO_DRIVER_ELS_PKC, and ELS-PKC is a proprietary
component of nxp to provides HW acceleration for psa-apis.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
REG_X_BASEADDR will be removed from all hal files.
This forces the use of the peripheral base address
Define MSPI_PORT macro for chip drivers
Signed-off-by: Richard Wheatley <richard.wheatley@ambiq.com>
Device tree configuration for USB serial node and clock control
fix for proper device initialization.
Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
Remove the flash node defined in the default `v0.9.0` variant before
adding a new node for the `v0.7.0` variant. Fixes two instances of
`jedec,spi-nor` being present in the final dts.
Signed-off-by: Jordan Yates <jordan@embeint.com>
set _XOPEN_SOURCE appropriately to avoid compilation errors
due to missing S_IFxxx macros on some systems.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Today the thread analyzer depends on !ARCH_POSIX,
so this filter needs to filter any board for this architecture
not just native_sim.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
As mentioned in the TSC Meeting of 7 August 2024
* Mahesh Mahadevan (mmahadevan108)
* Dan Kalowsky (dkalowsk)
will be the release managers for 4.0.
Let's update the MAINTAINERS files accordingly.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Some kind of race condition caused the gpio_keys input module to
occasionally miss an event after boot. This is fixed by initializing the
pin state variable in the input_gpio_keys module.
Related to https://github.com/starcopter/bms-firmware/issues/6
Signed-off-by: Lasse Fröhner <lasse@starcopter.com>
Provide information how to configure mosquitto >= 2.0
for the mqtt publisher sample. Secondly, how to
configure ethernet interface in case the board is
connected directly to the host computer through LAN.
Signed-off-by: Jasper Jonker <jjasper.jonker@gmail.com>
This change is removing some deprecation warnings
which for some reason causing failing tests with
Python 3.12 on CI #76877.
Also, it fixes warnings from pytest like:
PytestCollectionWarning: cannot collect test class 'TestPlan'
because it has a __init__ constructor
(from: scripts/tests/twister/test_testplan.py)
Signed-off-by: Lukasz Fundakowski <lukasz.fundakowski@nordicsemi.no>
Add a new compliance check that reports any clang-format issues on
the git diff and prints a warning.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
- Change the argument for i2c_is_read_op to a const pointer
- Add function i2c_is_stop_op to test if a message has a stop flag.
Signed-off-by: Yuval Peress <peress@google.com>
Update i2c_emul.c to support i2c_target_register and i2c_target_unregister
function calls as well as support address forwarding in emulation.
Address forwarding helps us test IPCs in native sim. Instead of having to
emulate 2 separate cores, we can forward read/write requests from one bus
to another bus (effectively creating a loop). This way the same image can
simulate both the controller and the target.
Signed-off-by: Yuval Peress <peress@google.com>
The testsuite subsystem provides the macro PRINT_DATA() which can be
overridden using CONFIG_ZTEST_TC_UTIL_USER_OVERRIDE. Switch all calls of
PRINT() to PRINT_DATA withing the testsuite subsystem.
Signed-off-by: Keith Short <keithshort@google.com>
Introduce `wifi_utils_get_next_chan_6g` to get the next
valid Wi-Fi 6GHz channel.
This commit addresses the proper handling of cases when
`chan_start` is not 1.
Fix#74063
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Pin definitions should correctly reflect the actual drive mode of the GPIO
controller, either push-pull or open drain.
Signed-off-by: Armin Brauns <armin.brauns@embedded-solutions.at>
This allows getting rid of the ngpios property, which is implicit in the
part number. It also prepares for configuring pins as open-drain on
supporting chips in the next commit.
Signed-off-by: Armin Brauns <armin.brauns@embedded-solutions.at>
This chip is handled by the more generic mcp23xxx driver, which will get a
microchip,mcp23s17 compatible binding in the next commit.
Signed-off-by: Armin Brauns <armin.brauns@embedded-solutions.at>
- apply correct order to suspend/resume when using continuous mode
- unset LPEN (low-power-enable) bit on suspend (causing excessive
current draw)
- fix a starting issue which lead to higher power consumption
Signed-off-by: Juliane Schulze <juliane.schulze@deveritec.com>
Add MAX32666EVKIT board file and documentation
For more information about this board please check
https://www.analog.com/
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
The NTC thermistor sensor in drivers/sensor/ntc_thermistor/ntc_thermistor.c
cannot work with a 16-bit ADC.
The voltage becomes negative if the ADC raw value is 0x8000 or higher.
To correct this, I changed the types in the
ntc_thermistor_data struct from int16_t to int32_t.
This also corrects a potential problem at line 53
where we transform an int16_t into an int32_t.
Fixes: #75203
Signed-off-by: Robin Carrupt <robincarrupt@gmail.com>
Add config file to host WiFi specific settings.
Introduce CONFIG_ESP_WIFI_MAX_THREAD_PRIO to be used
as a cap for the LL driver runtime.
Signed-off-by: Marek Matej <marek.matej@espressif.com>
Packet buffer is designed to run writer and reader code on two CPUs.
The write function cannot be preempted by the read function in a CPU,
or the cache management could result in data corruption. In the tests,
the reader and the writer are executed on a single CPU. Disable data
cache management to prevent potential data corruption.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Reduce the size of the ble notification if the length of
the line output is less than the current mtu size.
Signed-off-by: Victor Chavez <vchavezb@protonmail.com>
Macros for registering TCP and UDP services accept a port as a number,
not a pointer. Also added missing parameter to UDP service macro, and
missing type of bar_txt
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
The MQTT publisher/subscriber/pubsub tests suites are currently
depending on an external MQTT broker being available. In result, the
test suites cannot be executed in twister and need to be run manually,
which makes them kind of pointless from the CI perspective.
This commit reworks the tests, so that they no longer rely on an
external broker being available, but rather implement minimalistic
broker functionality for test purposes only. This will make the tests
self contained, and thus executable in the CI.
Since it makes not point to duplicate the effort between the test
suites, the test suites have been merged into a single mqtt_client test
suite.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Currently existing tests suites verify MQTT 3.1.1 functionality,
therefore group them together under "mqtt/v3_1_1" directory, so
that the test base can be extended easily in the future with MQTT 5.0
tests without collision.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Up till now the size of net buffer chunk was set to only 64B. This
approach was acceptable for IPv4 support as all headers would fit into
64B of allocated continuous memory.
With enabled support for IPv6 one would observe following errors when
Neighbor Discovery [ND] is performed:
net_pkt: Uncontiguous data cannot be linearized
net_ipv6_nd: DROP: NULL NA header
net_icmpv6: ICMPv6 handling failure (-5)
As some IPv6 headers span on multiple 64B net_pkt buffer instances.
To fix this error - the received chunks are stored to large enough single
net_pkt buffer fragment.
Signed-off-by: Stefan Bigler <linux@bigler.io>
Signed-off-by: Lukasz Majewski <lukma@denx.de>
To change mac or enable/disable promiscous mode transmit/receive does not
need to be disabled.
Disabling and enabling again leads to not transmitting anything afterwards.
Signed-off-by: Stefan Bigler <linux@bigler.io>
Signed-off-by: Lukasz Majewski <lukma@denx.de>
Up till now the configuration of LAN865x was NOT allowing any
multicast frames to be received.
However, those are required for correct handling of IPv6's Neighbor
Discovery [ND] protocol.
This patch - by setting all bits in hash enable register - allows
all muticast MAC addresses to be recived.
Of course - more granular approach to specify set of addresses to
be allowed would be better and will be added in the future.
Signed-off-by: Stefan Bigler <linux@bigler.io>
[Cleanup + modified comment]
Signed-off-by: Lukasz Majewski <lukma@denx.de>
Add extra information regarding the case when ZAREFE (0b01) combination
is set for RFA in OA_CONFIG0 register.
Signed-off-by: Lukasz Majewski <lukma@denx.de>
Enhancing code consistency provides cognitive leverage with
the following changes:
- Unified the order of declaration for `opt`, `opt_index`,
`state`, and `long_options`.
- Unified the wrapping of `getopt_long` calls, regardless of
the length of the `options` string.
- Renamed `option_index` to `opt_index` for consistency.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Using `getopt_state` to access `optarg` and also `optopt` offers
a better alternative to direct global access.
See e145eb9201 for the previous change related to this.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
This change marks the remaining instance of the `struct option` as
`static const`.
The rationale is that `struct option` is a read-only variable.
By using `static const`, we ensure immutability, leading to usage of only
the `.rodata` section and a reduction in the `.data` area.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Various manual code formatting adjustments, including:
- Wrapping lines in the `long_options` declaration to prevent them
from extending too far to the right.
- Adding missing `{` and `}` in the `if` statement in
`cmd_wifi_set_rts_threshold`.
- Aligning `SHELL_CMD_ARG` in `wifi_commands` with previous declarations.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Introduces a haptics API for use with LRA driver ICs to
create haptic feedback events.
Signed-off-by: Ricardo Rivera-Matos <ricardo.rivera-matos@cirrus.com>
The power_down() function will lock dcache for the hpsram_mask
array. On some platforms, the dcache lock will fail if the array
is on cache line that can be used for window register context
saves.
Work around this by aligning and padding the hpsram_mask to cacheline
size.
Link: https://github.com/thesofproject/sof/issues/9268
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
SenML is technically a JSON based format which can
be encoded as a CBOR. SenML-CBOR specification in
RFC 8428 section 6 states that numbers can be decoded
as an integer.
Also RFC 7049 section 4.2 states that JSON numbers
without fractional part can be decoded as an integer.
I have seen with one commercial LwM2M platform that
the decoder they use, sends floating point values as
integers, if there is no fractional part.
So LwM2M engine cannot assume from the path that
the incomming number is either float or int. Accept both.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
Introduce a Kconfig option to signal whether a HW info driver is
available when HWINFO is enabled.
Signed-off-by: Tomi Fontanilles <tomi.fontanilles@nordicsemi.no>
This commit moves reading nexthop's LL address only if it's supported
by a given neighbor and can be used for routing between interfaces.
Signed-off-by: Konrad Derda <konrad.derda@nordicsemi.no>
Use the new `SPI_MOSI_OVERRUN_DT` macro to determine at compile-time
whether the 512 byte array of `sdhc_ones` is required.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Expose the new common property `overrun-character` from the devicetree
nodes, falling back to the `SPI_MOSI_OVERRUN_UNKNOWN` value.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Move the `overrun-character` property from the common Nordic SPI
binding to the `spi-controller` base binding. This gives users of the
SPI interface a way to query what the default value is at compile-time,
and potentially avoid allocation of large constant buffers.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Remove address-of operator ('&') when assigning `init_fn`
function pointer in `DEVICE_DT_INST_DEFINE` macro.
This change aims to maintain consistency among the drivers in
`drivers/spi`, ensuring that all function pointer assignments
follow the same pattern.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Add spi configurations of NXP frdm_ke17z and frdm_ke17z512 boards,
tested spi_loopback sample for lpspi drivers.
Update the "HAS_MCUX_*" kconfig to "DT_HAS_*" in testcase.yaml
Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
After flashed EC image, we needed to manually press the reset button
on it8xxx2_evb. Now, without pressing the button, we can disable
debug mode and trigger a watchdog hard reset for running tests.
After flash EC, running below tests can pass (without pressing the button):
west build -p always -b it8xxx2_evb tests/drivers/watchdog/wdt_basic_api
west build -p always -b it8xxx2_evb tests/kernel/timer/timer_api
west build -p always -b it8xxx2_evb tests/kernel/fatal/exception
Signed-off-by: Dino Li <Dino.Li@ite.com.tw>
Signed-off-by: Ruibin Chang <Ruibin.Chang@ite.com.tw>
Don't push the TS flag on `buf` itself.
This messes up the MTU calculations: a packet that would exactly fit the
MTU and has a timestamp would be unnecessarily fragmented.
The MTU check is done on `buf` as a whole. At the point where the
fragmentation length is decided, `buf` includes one extra byte to pass the
TS bit around. That byte shouldn't count towards the MTU.
Instead, infer the presence of the timestamp by inspecting the amount of
headroom that the buffer has. This works because we always reserve
enough memory to push the timestamp, but not always push a timestamp on
the buffer. #tightlycoupled
This method is slightly uglier IMO, but eases MTU confusion and doesn't
rely on user_data.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
This overlay is no longer needed, as presently there are more test
scenarios covering all combinations of DMA and SPY_ASYNC support for
LPSPI peripheral.
Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
Update manifest to pull fixes for mr_canhubk3 DMA driver.
Fixes#76708
Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
Signed-off-by: Manuel Argüelles <marguelles.dev@gmail.com>
Add MAX32662EVKIT board files
For more information about this board please check
https://www.analog.com/
Co-authored-by: Maureen Helm <maureen.helm@analog.com>
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Allow to run with timer random generator which does not need any
entropy device.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
When logging is on and optimization and multithreading is off then
build fails to link because unoptimized compiler/linker seems to not
look beyond the function and it fails trying to link k_thread_name_get.
Reworking the code to make it known to the compiler without optimization
that k_thread_name_get is not needed and not logging current thread
name in that case.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
For stm32 platforms where the sysclock is less or equal to
32MHz, the Ticks per second is reduced to 8000 (instead of
10000).
Signed-off-by: Francois Ramu <francois.ramu@st.com>
Current PHY rate
It represents the current PHY rate of transfer
of data in bits per second. It will a TX data rate.
Signed-off-by: Kapil Bhatt <kapil.bhatt@nordicsemi.no>
Over run count
It represents the number of packets dropped either at
received and sent due to lack of buffer memory to retain
all packets on the network interface.
Signed-off-by: Kapil Bhatt <kapil.bhatt@nordicsemi.no>
This sample crates a touchscreen desk calculator based on
the sample state machine in _Practical UML Statecharts in
C/C++_ by Miro Samek.
Sample should build and run on any touchscreen-enabled
board with sufficient resources.
Tested on `disco_l475_iot1` board with
`adafruit_2_8_tft_touch_v2` touchscreen.
Signed-off-by: Glenn Andrews <glenn.andrews.42@gmail.com>
It's a superfluous value which used to be required by tooling, but now
we can remove it.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Between SoC revisions, the address was moved from 0x5F909000 in the
global domain, to 0xF0000000 in PPR's private address space.
Move the corresponding DT node out of `cpuppr_vpr` range to a separate
bus node, which is considered inaccessible to all cores but `cpuppr`.
This is expressed by selectively leaving out the `simple-bus` compatible
and `ranges` property, i.e., they're only set in `nrf54h20_cpuppr.dtsi`.
This lets the interrupt controller node remain visible at system level,
for the purpose of describing IRQ mappings between cores in devicetree.
Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
Enable the rng module for the google_dragonclaw board by default.
The RNG module is always used anyway and it helps with running tests
that needs entropy.
Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
qemu_riscv32e uses a different ISA and is kinda special, add it
to the testcase for better coverage.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
arch_kernel_init() was misused for all architecture initialization code
that is done in prep_c and prior to cstart on other architectures.
arch_kernel_init() is late in the init process and comes after EARLY
init level, making xtensa have a very special boot path.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Many xtensa target jump from soc code directly into cstart and depend on
architecture code being initialized in arch_kernel_init(). Instead of
jumping to cstart, jump to newly introduced prep_c similar to all other
architectures, where common platfotm initialization will happen.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
xtensa is the only architecutre doing thing differently and introduces
inconsistency in the init process and dependencies as we attemp to
cleanup init levels and remove misused of SYS_INIT.
Introduce prep_c for this architecture and align with other
architectures.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add a config to use the custom _sbrk function, defined by a user.
It is possible that an application doesn't want to use the entire
remaining RAM for the heap.
Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
User can assign callback function to local domain dvfs handler
and get notification when scaling process is finished for
particular domain.
Reworked usage of DVFS_SERV_HDL_FREQ_CHANGE_IN_PROGRESS_BIT_POS
which was not initialized properly.
Signed-off-by: Lukasz Stepnicki <lukasz.stepnicki@nordicsemi.no>
This update is to support clock API for RA8
Move the clock initialize function into clock driver
Peripheral clock now has 2 more property in clock cell for enable
and disable clock to peripheral module
Signed-off-by: Duy Phuong Hoang. Nguyen <duy.nguyen.xa@renesas.com>
This change adds the device tree property for specifying oe-override
(output-enable override behavior), as well as defines for possible values
of the property.
RP2040 GPIOs can be configured to automatically invert the output-enable
signal from the selected peripheral function. This is useful for tasks like
writing efficient PIO code, such as in the i2c example in the rp2040
datasheet.
Signed-off-by: Yiding Jia <yiding.jia@gmail.com>
PXP can flip image written to the frame buffer. Provide a mirror image
on the display by flipping the camera image horizontally. Enabled on
boards mimxrt1066_evk and mimxrt1060_evkb.
Signed-off-by: Derek Snell <derek.snell@nxp.com>
This commit fixes an issue where deprecated IPv6 addresses were not
being correctly marked. In some cases, deprecated addresses might have
been used as source addresses.
Signed-off-by: Łukasz Duda <lukasz.duda@nordicsemi.no>
According to 5.1.2.2.5 I3C Target Address Restrictions in the I3C
v1.1.1 specification. Certain addresses are not allowed. These are
all marked as reserved in the address map. Print "RS" if they are
reserved and skipped.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Wi-Fi shell now uses _sta/_ap APIs to getch specific inteface types, so,
by default register as a Station.
This needs more work to handle multiple modes and mode switching.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
When Wi-Fi utils is enabled it causes build error due to missing rename
in a couple of places.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
The version header is generated during build and generated path included
already has "zephyr" directory.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Added MAX32675EVKit board
For more information about this board please check
https://www.analog.com/
Co-authored-by: Maureen Helm <maureen.helm@analog.com>
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
Add an opaque pointer to store upper layer private data and initialize
it with the USB device context during controller initialization. Use the
pointer in event processing to get the correct context.
Fixes commit 48f2a4bc1a
("usb: device_next: remove initialized state checks in event processing")
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
cplusplus-rom linker initialization was wrongly placed
in RAM area when it should be in ROM area.
Fixes#75853
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Account for the scenario when we are doing `esf`-based
unwinding from a function which doesn't have any callee.
In this case the `ra` is not saved on the stack and the
second function from the top of the frame could be missing.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
On a successful update we should reset the retry counter, similarly
like we do on successful registration.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
When socket errors call sm_handle_timeout_state() we might be
in a state where application assumes we are in registered state
but we are dropping it.
Therefore we must ensure that all registration states emit either
REGISTRATION_TIMEOUT event for application to indicate that
we have lost the connection to server.
Signed-off-by: Seppo Takalo <seppo.takalo@nordicsemi.no>
Enable 'chan_blen_transfer' and 'loop_transfer' tests for MAX32670EVKIT.
Co-authored-by: Maureen Helm <maureen.helm@analog.com>
Signed-off-by: Mert Ekren <mert.ekren@analog.com>
Enable DMA peripheral support on MAX32655EVKIT and FHTR boards.
Co-Authored-By: Sadik Ozer <sadik.ozer@analog.com>
Signed-off-by: Jason Murphy <jason.murphy@analog.com>
Revise data type declarations to avoid implicit/explicit casts:
- Changed `unsigned char` to `uint8_t` for `zeros` array
to match with `longest`.
- Declared variables `i`, `j`, and `pos` as `int` to use the same type.
- Cast `value` to `uint16_t` instead of `uint32_t` since
`value` is `uint16_t`.
- Moved `bh` and `bl` declarations to narrow the scope of variables.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Simplify high and low byte conversion by removing redundant checks,
since `net_byte_to_hex` already takes care of zero padding.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Replace the loop with direct high and low nibble extraction,
and ensure the padding and zero suppression logic is simplified.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
number of counters have changed in gcc 14 by commit
https://github.com/gcc-mirror/gcc/commit/08a52331803
Specifically, a new counter was added in gcc/gcov-counter.def:
```
/* Conditions. The counter is interpreted as a bit-set. */
DEF_GCOV_COUNTER(GCOV_COUNTER_CONDS, "conditions", _ior)
```
which in turn updates the value of GCOV_COUNTERS that is defined in
gcov-io.h like this:
```
enum {
GCOV_COUNTERS
};
```
Signed-off-by: Roman Studenikin <srv@meta.com>
If only 2 page frames are queued and code executing in one frame is
making an access to memory in the second frame then the access will trap
and k_mem_paging_eviction_accessed() will be called to move that frame
to the end of the queue ... marking the new head frame unaccessible.
But that newly unaccessible frame contains the code that has yet to be
resumed to perform its memory access. Since it is now unaccessible, a
trap is triggered, the frame is moved to the end of the queue and the
new head frame (the one we trapped for initially) is marked unaccessible.
Execution is resumed with the memory access which is unaccessible again
and the cycle repeats infinitely.
Fix this by not marking the new head unaccessible if there is only one
queued frame left in the queue.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
RRAMC peripheral is a secure-only peripheral, and the application
cannot use it directly. While building an application with TF-M
enabled and SOC_FLASH_NRF_RRAM the NRFX_RRAMC selection must
be forbidden.
Signed-off-by: Arkadiusz Balys <arkadiusz.balys@nordicsemi.no>
Do not depend on platforms that need a HAL. This should speed things up
and should resolve issues where runner did not have enough space to deal
with all HALs.
t
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add support for testing IPC between cpuapp<>cpuflpr. Some adjustments
have been done to be able to support two different remote targets for
the nrf54h20dk cpuapp.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
While executing from MRAM will likely never happen in practice for the
FLPR core, add such variant for testing.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
This is required since NRF_FUN_POS (pinctrl) has changed its position
from 17 to 18 (a value hardcoded in the nrf-regtool as well).
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
On new SoCs, certain pins need to enable the clock setting on the pin
for it to work properly. For now, this has been handled internally in
the pinctrl driver, however, it appears to be an instance-specific
property (e.g. UARTE/SPIM instances in the fast domain do not require
such setting). Move the configuration of this settings to DT, the best
place where to have instance-specific hardware settings.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Some UARTE instances may be clocked at higher speeds than 16MHz, so the
baudrate setting needs to be scaled accordingly. This patch parses the
`clocks` property and obtains the clock-frequency property of the
associated clock, assuming it is a fixed-clock. We should ideally have a
proper clock control subsystem where frequency can be queried using an
API, but we're far from there.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
HSFLL120 is a clock used by fast peripherals, and it is controlled by
the system controller. From an application perspective, it is a fixed
clock. Note that it has multiple outputs (clk_main @ 320MHz, and
clk_main2|4 which provide the main clock divided by 2 and 4,
respectivelu). Only the main frequency is represented for now.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Programming of the MLCS register was performed on the incorrect bits.
Additionally, saving the new version did not erase the previously set
value, which could result in an incorrect register value.
Signed-off-by: Damian Nikodem <damian.nikodem@intel.com>
Wi-Fi sample is stack heavy, so, by default increase the stack sizes to
work with any driver, esp. those use WPA supplicant like nRF Wi-Fi.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Wi-Fi shell prints scan results to the console taking time and this puts
pressure on net_mgmt Queue, so, increase both timeout and Queue depth to
handle crowded Wi-Fi channel (~200 APs).
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
These shields in the Arduino form factor can be mounted on supported
boards and can provide Wi-Fi6 capability.
Base shield is nRF7002, with variants as nRF7001 (2.4GHz only) and
nRF7000 (dual band scan only).
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Driver for Nordic nRF70 Wi-Fi6 companion chipset, depends on
hal_nordic/nrf_wifi for OS agnostic part of the driver.
This supports (Q)SPI interface to communicate from host to chip.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
The repo-path field is meant to override the repository name if it's
different than the module name, drop two cases where repo-path has no
effect.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
The CST816D touch chip is similar to the CST816S, with the primary
difference being the chip ID. This commit extends the existing
CST816S driver to support the CST816D by adding its chip ID. There
are no other modifications.
Signed-off-by: Shang Xiangyao <shxyke@gmail.com>
For commonly-accessible I2C nodes, status and pinctrl are now set in
board dts. Remove these properties from test overlay files.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Enable commonly-used I2C in ADI MAX32 boards by default to access I2C
functionality without having to create an additional overlay file.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Some offloaded ifaces have an L2, but lack support for
net_l2->send. This edge case is not handled by
net_if_send_data, resulting in a NULL dereference under
rare circumstances.
This patch expands the offloaded iface guard in
net_if_send_data to handle this edge case.
Signed-off-by: Georges Oates_Larsen <georges.larsen@nordicsemi.no>
Added a sample application demonstrating how to use the coap_client API
to download a resource via GET request.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
It looks like both cpuapp/cpunet cores share the same definitions for
LEDs, buttons and Arduino connector. This patch puts these repeated
definitions into a single shared file.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Fixes issues with net_ptp_time arithmetic where second
overflow/underflow would not be handled properly.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
Offset should be *subtracted* from current clock value, not added.
This was causing clock to accumulate error instead of actually
"converging".
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The test `storage.flash_map.mpu` for `nrf52840dk/nrf52840` fails
althought the output is correct. Time to test execution is not enough.
This change extend test execution timeout.
Signed-off-by: Katarzyna Giądła <katarzyna.giadla@nordicsemi.no>
Inform users about Kconfig options deprecation and show what is the
alternative with some examples.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
nRF53X HV regulator differs from eg nRF52X as it offers a silent mode
option. For this reason, a new compatible is used, even if now such
capability is not exposed yet.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
In addition to Kconfig options (soon to be deprecated), allow
configuring the regulators using DT.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The SoC main supply is part of the POWER IP block. The POWER IP is a
kind of multi-purpose block, so each of its functions is described as a
child node in DT, like similar other MFD. This allows to have specific
properties, e.g. for DC/DC mode.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Some Nordic SoCs, like nRF52 contain an internal regulator for the main
SoC supply. Depending on the SoC, the regulator can have multiple
configurations (e.g. single/double stage), which mainly depends on
supporting "high-voltage" mode or not (VDDH pin supply). This patch adds
bindings for nRF5X regulator and nRF52X HV regulator.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
When presenting an example of how to run a failing test case with
`west build`, provide the source dir path relative to the current
working directory, not the zephyr root directory.
Signed-off-by: Jordan Yates <jordan@embeint.com>
For 2.4GHz and 6GHz bands, while counting the channels in configured
range, start of the range is being counted twice. Correct this
by advancing the index by 1 while counting channels in range.
Signed-off-by: Ravi Dondaputi <ravi.dondaputi@nordicsemi.no>
The WeAct STM32F405 Core Board is an extremely low cost and bare-bones
development board featuring the STM32F405RG, 64-pin variant of
the STM32F405x series.
Signed-off-by: Pavlo Yadvychuk <pyadvichuk@gmail.com>
Flexible arrays are arrays declared without a specific size, e.g:
uint8_t my_array[];
They are widely used as as last member in structs that are dynamically
allocated.
Since C99 they are part of the C standard, but for historical reasons
many places still use an older GNU extension that is declare zero
length arrays.
Although zero length arrays are flexible arrays, we can't blindly
replace [0] with [] because of some syntax limitations. This macro
workaround these limitations while get rid of this non standard
extension.
Using true flexible arrays allows the compiler to calculate the size
of the array better and improve potential issue checking.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
It is safer to base the SUIT artifacts path on the path of the
configuration file than the HEX file that is being flashed.
The latter may be overriden by several scripts that merge/transform the
final firmware image.
Signed-off-by: Tomasz Chyrowicz <tomasz.chyrowicz@nordicsemi.no>
lwm2m.h was missing the extern "C" block
and it used a forward declaration to an enum,
which is illegal in c++.
Signed-off-by: David van Rijn <david@refractor.dev>
Remove the logic from the board level about overriding the
flash load size and instead just select to use the DT code
partition if app is not expected to be able to occupy the
whole flash space because of the firmware image being
loaded separately.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
The sx12xx driver does not provide RxError event handler therefore
when such error occurs, the driver does not handle it at all.
As a result, when the lora_recv function is called with infinite timeout,
it never returns as it waits on k_poll forever, with radio operation mode
set to STDBY_RC. Therefore, once the rx error occurs, radio is no longer
able to receive any subsequent incoming transmission. Fix it by adding
RxError event handler which releases modem usage and signals error
allowing lora_recv to return with a value indicating receive error.
Tested on lora e5 mini by transmitting multiple LoRa messages over a
short period of time that caused CRC error, thus RX errors.
Once the fix is applied, the descibed behaviour no longer occurs despite
the CRC errors caused by test.
Signed-off-by: Patryk Biel <pbiel7@gmail.com>
[Description]
Device hang is observed when LE Scan
[Root Cause]
For le_ext_adv_report, Data[i] of one adv report is 0-229,
for the adv_buf of saving, it just is 73 bytes, so sometimes
the bytes of adv report is more than the adv_buf, resulted hang
[Fix]
consider the le ext adv case.
[Testing]
After modified, Device hang is not observed after stress
testing with LE Scan
Signed-off-by: Guotao Zhang <guotao.zhang@nxp.com>
Read CONFIG_SHELL_PROMPT_UART from config file and use them
in shell fixture in pytest-harness package.
Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
Moved helper methods from tests/boot/with_mcumgr to pytest-harness
package. It can be reused by other tests.
Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
When periodic scanning reaches timeout and BIGinfo has not yet been
received, notify with BT_HCI_ERR_CONN_FAIL_TO_ESTAB for sync receiver.
Signed-off-by: Morten Priess <mtpr@oticon.com>
When an ISO stream fails to sync to a broadcaster within the first 6
events, the establishment fails (as expected). However, it did not stop
the ticker, and subsequently it was impossible to establish a new sync
after this.
Make asynchronous call to ticker_stop when establishment fails, and exit
done handling. Cleanup is handled via ll_rx_dequeue().
Signed-off-by: Morten Priess <mtpr@oticon.com>
When the ISO sync receiver has been disabled (terminted), ULL now calls
lll_sync_iso_flush in lower link layer, to allow cleanup and releasing
of resources.
Make sure ISO sync LLL flush is also called when terminating a stream
from local side (app). Add blocking mayfly call to lll_sync_iso_flush in
ll_big_sync_terminate.
Signed-off-by: Morten Priess <mtpr@oticon.com>
If a race condition occurs between stopping CIS stream and tearing down
data path, releasing TX PDUs was not possible for vendor data path, as
the DP configuration is gone.
In that case, call a new vendor specific function for cleaning up and
returning PDUs to correct pool.
Signed-off-by: Morten Priess <mtpr@oticon.com>
The MFIFO holding TX nodes on the ack path back to the host was only
sized to hold the possible number of ACL TX nodes. However, additional
TX nodes are allocated for LLCP and use the same FIFO.
By adding LLCP_TX_CTRL_BUF_COUNT to the size, the FIFO will be able to
hold the worst-case number of TX nodes.
Signed-off-by: Morten Priess <mtpr@oticon.com>
Rename to BT_TICKER_START_REMAINDER better reflect what it
means in terms of providing remainder parameter to ticker
start interface.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Clean up before deprecating legacy device support.
The Linux kernel driver for this example has never been upstreamed or
implemented upstream. In general, 15.4 development does not seem to be a
big success, but if it comes up again, the protocol used by the example
will need to be redesigned anyway.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Clean up before deprecating legacy device support. This sample does not
contain anything special that is not present in the hid-mouse or
hid-keyboard samples. It also makes no sense to port it to a new stack.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Clean up before deprecating legacy device support. Remove
cdc_acm_composite sample, which is not much different than cdc_acm, but
uses two virtual UART interfaces.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Clean up before deprecating legacy device support. Remove configuration
overlay for DFU and MSC, which does not add much value since we have
dedicated samples anyway.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Score was never increased for scan_aux events since they are
one-shot events; Fixed by keeping the scan_aux score as part
of the scan structure
Signed-off-by: Troels Nilsson <trnn@demant.com>
Support for separate SDU interval for C_to_P and P_to_C
directions when setting CIG parameters.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
The TMAG3001 is quite similar to the tmag5273 and can be used with just
some small modifications.
Signed-off-by: Fabian Pflug <fabian.pflug@grandcentrix.net>
This commit modifies the DTS cmake module to capture `stderr`
output of the `gen_defines.py` script and `dtc` program during
their execution. The messages can then be printed as CMake
`message`s, which improves QoL when debugging device tree
errors, and reduces the risk of introducing malformed DTS,
as the warning/error messages are made much more visible.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
Setting SOURCES before calling find_package() was deprecated in #51049.
Cleanup usage of SOURCES and instead use the proper target_sources()
CMake function.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Fixes: #73831
find_package(Zephyr) should be called before first project() call.
Zephyr package will test and force-set the correct toolchain, especially
the C compiler.
The project() will also set the C compiler, if not set already.
If project() is called first, then conflict arises on the C compiler
selection and thus the following message is seen:
> You have changed variables that require your cache to be deleted.
> Configure will be re-run and you may have to reset some variables.
> The following variables have changed:
> CMAKE_C_COMPILER= /usr/bin/gcc
This cache deletion results in other errors, such as a missing BOARD
setting.
Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
Previously, the `soc.c` files for the IMXRT11xx, IMXRT5xx/CM33, and
IMXRT6xx/CM33 did not register the log module. This caused build
errors when DEBUG logging was enabled, as the `power.c` file attempted
to access a non-existent SOC log module for debug messages.
This commit fixes the issue by registering the log module in the
`soc.c` files for the specified SoCs, thereby resolving the build
errors.
Signed-off-by: Apoorv Singh <apoorv.singh@gin.de>
Fix formatting for `soc.c` files for the IMXRT11xx, IMXRT5xx/CM33, and
IMXRT6xx/CM33 by running 'clang-format'.
Signed-off-by: Apoorv Singh <apoorv.singh@gin.de>
The group covered way to many files with way too few
people. The content of the group has been split into
several other groups where we can better assign the
correct people.
This also creates 2 new groups for Bluetooth ISO and
Bluetooth qualification.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Convert NXP System Timer Module driver to a native driver.
Timer prescaler in tests is updated because short relative alarms
sometimes give false positives.
Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
Adjusting T_sco is only support by revision 1p4 and above. Also,
correct the T_sco default time from 10ns to 8ns.
Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
Enabling BT_HCI_SETUP for STM32WB55 to have a
correct and proper initialization procedure to fix
#75318 issue
Signed-off-by: Alessandro Manganaro <alessandro.manganaro@st.com>
Implementing HCI setup function to have a correct and proper
initialization procedure to fix#75318 issue
Signed-off-by: Alessandro Manganaro <alessandro.manganaro@st.com>
"Video subsystem for Zephyr" is actually only defined as a driver
and the examples actually include <zephyr/drivers/video.h>.
Signed-off-by: Josuah Demangeon <me@josuah.net>
Create stubs for getpwnam_r, getpwuid_r, getgrgid_r
& getgrnam_r.
These functions are in the _POSIX_THREAD_SAFE_FUNCTIONS
option group.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
As it was already outlined, installing Python dependencies at a system
level or user level can be dangerous. For this reason, the default setup
instructions already pointed users to use Python virtual environments. On
newer Ubuntu installations (23.04 onwards) system-level pip installs are
not allowed. Let's make Zephyr _Python-safe_ as well by removing dangerous
instructions.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Implementation to take command-line arguments to set log level in run
time for bsim module. Set default log level if no log level is passed
at runtime
Signed-off-by: Guru Mehar Rachaputi <gurumeharrachaputi@gmail.com>
Add commands to allow requesting a subrate change via the BT shell.
A new build configuration has been added to ensure this is tested in CI.
Signed-off-by: Aleksandar Stanoev <aleksandar.stanoev@nordicsemi.no>
Adds support for LE Connection Subrating as defined in Core 5.4
Vol 6, Part B, Section 5.1.19.
As this is primarily a controller feature, the host support is mostly
a wrapper around the relevant HCI commands.
Note that subrating provides a new method to update the connection's
peripheral latency and supervision timeout alongside subrating parameters.
Signed-off-by: Aleksandar Stanoev <aleksandar.stanoev@nordicsemi.no>
The default behavior for thread pending of completions should use
semaphores rather than yield/wait looping when multithreading is
available.
Disable by default only when multithreading isn't available.
Signed-off-by: Tom Burdick <thomas.burdick@intel.com>
Allow developer to use the baremetal Bluetooth functionalities of the
CC13X2 and CC26X2 series SoCs without having to use the full Zephyr
Bluetooth stack.
Signed-off-by: Benedikt Streicher <streicher.b@posteo.de>
The .ref_internal field in the adc_driver_api
struct was previously unset.
Now it's set to the proper value, 1 V.
Signed-off-by: Julia Azziz <juliaazziz7@gmail.com>