MWDT toolchain adds additional suffix to sections name in case of
ffunction-sections / fdata-sections are enabled.
Let's pick a single set of rules and syntax that work for all
toolchain.
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
MWDT toolchain adds additional suffix to sections name in case of
ffunction-sections / fdata-sections are enabled.
Let's pick a single set of rules and syntax that work for all
toolchain.
Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
In previous batch of fixes it was overlooked that streams are
HTTP2-specific concept. While for HTTP2 we need to track headers reply
state for each individual stream, at HTTP1 level we need to track this
at the client level. Hence, reintroduce respective flags to track
headers reply state, but only for HTTP1.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Review and improve comments in source code to better describe the API
and the functionality provided by the llext library.
No actual code changes are performed in this commit.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Even just making minor edits to fcb, warnings are triggered
from Coding Guidelines of the form
Violation to rule 5.7 (Tag name should be unique) tag: fcb
Rename pointer variable names to fcbp.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Add few missing button codes, these matches the ones used in Linux to
cover HID mouse buttons 1 to 8.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Utilize a code spell-checking tool to scan for and correct spelling errors
in all files within the `include/zephyr` directory.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Utilize a code spell-checking tool to scan for and correct spelling errors
in all files within the `include/zephyr/logging` and `mgmt`.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Utilize a code spell-checking tool to scan for and correct spelling errors
in various files within the `include/zephyr/arch` directory.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Utilize a code spell-checking tool to scan for and correct spelling errors
in various files within the `include/zephyr/net` directory.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Utilize a code spell-checking tool to scan for and correct spelling errors
in various files within the `include/zephyr/dt-bindings` directory.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Fixed a few bad or missing documentation parts of iso.h
Also formatted some parts to be consistent with not just
the file itself, but also with bluetooth.h
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add missing documentation to USBD_DEVICE_DEFINE,
USBD_CONFIGURATION_DEFINE and USBD_DEFINE_CLASS macros.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
The POSIX macros PAGE_SIZE and PAGESIZE (queriable through
sysconf()) were conditionally defined only if an existing definition
did not already exist. These should be defined unconditionally in their
header to ensure they get the correct values.
If these macros are defined elsewhere with a different meaning, that's a
problem. There was an issue where PAGESIZE was already defined with a
different meaning. See #74623 and #74428.
The POSIX macro ATEXIT_MAX is also conditionally defined and should be
unconditionally defined, but there is currently a definition in picolibc
(picolibc/newlib/libc/include/stdlib.h) so this change will be done
separately.
This commit defines PAGE_SIZE and PAGESIZE unconditionally.
Signed-off-by: Ben Marsh <ben.marsh@helvar.com>
As found in PR #75525, we should not modify the polled fd array
in multiple places. Because of this fix, the async version of
the socket service could start to trigger while it is being handled
by the async handler. This basically means that the async version
cannot work as intended so remove its support.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Adds ability to process synchronous requests in an asynchronous
fashion, relying on dedicated P4WQ's and pre-allocated work items.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
In order to decouple the read request from its implementation, we need
to be able to yield to potential lower-priority threads, which is not
possible with k_yield() itself. As such, using RTIO Consume semaphore
enables us to achieve this.
This patch also refactors blocking API (sensor_read) to also block upon
consumption, so as not to require RTIO_SUBMIT_SEM enabled.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
The information about replied headers or END_OF_STREAM flag are
stream-specific and not general for a client. Hence, need to move them
to the stream context.
For the upgrade case, we need to allocate a new stream now when HTTP1
request /w upgrade field is received. The stream ID in such case is
assumed to be 1 according to RFC.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
In case client decides to send a trailing headers frame, the last data
frame will not carry END_STREAM flag. In result, with current logic
server would not include END_STREAM flag either, causing the connection
to stall. This commit fixes this logic, so that the server replies
accordingly in case END_STREAM flag is present in the trailing headers
frame.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
CONTINUATION frames are tricky, because individual header fields can be
split between HEADERS frame and CONTINUATION frame, or two CONTINUATION
frames. Therefore, some extra logic is needed when header parsing
returns -EAGAIN, as we may need to remove the CONTINUATION frame header
from the stream before proceeding with headers parsing.
This commit implements the above logic and additionally adds more checks
to detect when CONTINUATION frame is expected. Not receiving a
CONTINUATION frame when expect should be treated as a protocol error.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
In case RST_STREAM frame is received it should not be ignored, but the
corresponding stream should be closed.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
In case priority flag is present in the HTTP2 headers frame header, we
should expect additional priority fields before the actual frame
content.
The stream priority signalling has been deprecated by RFC 9113, however
we should still be able to handle this in case some implementation
(nghttp for instance) sends them.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Data and header frames can contain padding - we need to take this into
account when parsing them, otherwise the stream is broken.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
For HTTP2-specific structures and enums, use "http2_" prefix to clearly
indicate the distinction from the generic HTTP stuff.
Additionally, some structures/enums describing HTTP2 protocol details
had "server" in the name, while in reality they describe nothing
server-specific. Hence, drop the "server" part where applicable.
Remove unused macros.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
* Remove unneeded variable.
* Use system utilities to read big endian numbers instead of parsing
manually.
* Remove `payload` member from the http_frame structure. It's not used
for anything useful, and could actually be misleading, as in case of
large frames, where not entire frame is parsed at once it will point
to incorrect location.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
If newly introduced interface type is unset then return the first Wi-Fi
interface as a fallback, this fixes backward compatibility.
Also, add NM APIs and use them for type checks, rather than directly
using the type enumeration.
Fixes#75332.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
BT_TBS_TECHNOLOGY_IP is not a valid technology value
for TBS since it's not defined by the spec.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Utilize a code spell-checking tool to scan for and correct spelling errors
in all files within the `include/zephyr/bluetooth` and `subsys/bluetooth`
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
When userspace is used and frontend was used for logging then runtime
filtering was failing because in user context filtering data was
accessed and filtering data is in the kernel space. Fixing that and
adding runtime filtering to the pre frontend function which is
already executed in the kernel space and filter data can be
accessed.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Fixes the following error appearing in the test coverage added by the
next commit:
In file included from zephyr/tests/lib/cpp/cxx/src/main.cpp:18:
```
zephyr/include/zephyr/pm/device.h:275:9: error: designator order for
field 'pm_device_base::state' does not match declaration order
in 'pm_device_base'
275 | }
| ^
zephyr/include/zephyr/pm/device.h:315:17: note: in expansion of
macro 'Z_PM_DEVICE_INIT'
315 | Z_PM_DEVICE_INIT(Z_PM_DEVICE_NAME(dev_id), node_id,
```
Note this failure is observed with any g++ -std=c++NN standard value -
even before C++20.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Conditionally remove braces for designated initializers of anonymous
unions. This makes it compatible with C++20 while not breaking pre-C11
gcc.
This does for device.h what commit c15f029a71 ("init.h: restore
designated initializers in SYS_INIT_NAMED()") did for init.h
See https://docs.zephyrproject.org/latest/develop/languages/cpp/ and
long discussion in #69411 for more obscure C/C++ compatibility details.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Some public API functions do not modify the net_buf instances and can
declare these arguments as const.
Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
native_posix (unlike native_sim) or its breathen (NATIVE_APPLICATION)
link together the "runner" code and the embedded code.
This means that when CONFIG_STATIC_INIT_GNU is set,
any host library code (like the llvm fuzzer) constructors will get
postponed to the Zephyr initialization.
These libraries are unlikely to work if we do this.
(the llvm fuzzer does not)
So let's instead not enable STATIC_INIT_GNU for these targets.
This means possible embedded library constructors will continue to be
picked during the link and be still called during the native runner
initialization instead of during the Zephyr OS initialization as they
were just before we introduced STATIC_INIT_GNU in
6e977ae2d5
Note that native_posix will be deprecated shortly and its users
are strongly encouraged to move to native_sim.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Utilize a code spell-checking tool to scan for and correct spelling errors
in all files within the `include/zephyr/drivers` directory.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
The subscribe parameters shall be a struct that has previously
been subscribed to, as it works as a linked list.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
When this bit is not set, it defaults to 0 (little endian). This
causes issues for big-endian devices, as data will be accessed using
little endian.
Signed-off-by: Sigmund Klåpbakken <sigmundklaa@outlook.com>
Fix missing CONFIG_ prefix for log format section strip check.
Logging was still operating on invalid flash addresses.
Fixes#75161
Signed-off-by: Joakim Andersson <joerchan@gmail.com>
This reverts commit 93973e2ead.
PR #73978 introduced a regression.
Unfortunately this PR cannot be reverted without reverting also
Let's revert both PRs to stabilize main again towards the 3.7 release.
For more details on the issue see
https://github.com/zephyrproject-rtos/zephyr/issues/75205
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This reverts commit 49ac1912b2.
PR #73978 introduced a regression.
Unfortunately this PR cannot be reverted without reverting also
Let's revert both PRs to stabilize main again towards the 3.7 release.
For more details on the issue see
https://github.com/zephyrproject-rtos/zephyr/issues/75205
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This reverts commit 305ec62a6b.
PR #73978 introduced a regression.
Unfortunately this PR cannot be reverted without reverting also
Let's revert both PRs to stabilize main again towards the 3.7 release.
For more details on the issue see
https://github.com/zephyrproject-rtos/zephyr/issues/75205
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This reverts commit 499a633976.
PR #73978 introduced a regression.
Unfortunately this PR cannot be reverted without reverting also
Let's revert both PRs to stabilize main again towards the 3.7 release.
For more details on the issue see
https://github.com/zephyrproject-rtos/zephyr/issues/75205
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This reverts commit b2243af32d.
PR #73978 introduced a regression.
Unfortunately this PR cannot be reverted without reverting also
Let's revert both PRs to stabilize main again towards the 3.7 release.
For more details on the issue see
https://github.com/zephyrproject-rtos/zephyr/issues/75205
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Macros like `BIT()` & `BIT64()` from the `util_macro.h` are
used, include their header to compile properly.
Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Packet buffer can be used for sharing data between cores. In that
case when any core has data cache then data cache handling must
be enabled in the module. However, it shall never be enabled when
the packet buffer is used on a single core. Adding that information
to the documentation.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>