Repeated references to _current won't produce a different result as the
executing thread instance is always the same. Use the const attribute to
let the compiler know it may reuse a previously obtained value. This offset
the penalty for moving z_smp_current_get() out of line and provides yet
more binary size reduction.
This change is isolated in its own commit to ease bisecting in case some
unexpected misbehavior is eventually observed.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Define the generic _current directly and get rid of the generic
arch_current_get().
The SMP default implementation is now known as z_smp_current_get().
It is no longer inlined which saves significant binary size (about 10%
for some random test case I checked).
Introduce z_current_thread_set() and use it in place of
arch_current_thread_set() for updating the current thread pointer
given this is not necessarily an architecture specific operation.
The architecture specific optimization, when enabled, should only care
about its own things and not have to also update the generic
_current_cpu->current copy.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Mostly a revert of commit b1def7145f ("arch: deprecate `_current`").
This commit was part of PR #80716 whose initial purpose was about providing
an architecture specific optimization for _current. The actual deprecation
was sneaked in later on without proper discussion.
The Zephyr core always used _current before and that was fine. It is quite
prevalent as well and the alternative is proving rather verbose.
Furthermore, as a concept, the "current thread" is not something that is
necessarily architecture specific. Therefore the primary abstraction
should not carry the arch_ prefix.
Hence this revert.
Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
Add support for the open hardware CANbardo Universal Serial Bus (USB) to
Controller Area Network (CAN) adapter board.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Add check that should enable MFP when connect to WPA3 network,
as MFP required is mandatory for WPA3 network.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
Support printing WPA3 enterprise type in scan result for more
accurate display, including the suiteb, suiteb-192 and WPA3
enterprise only.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
For 'wifi status' and 'wifi ap status' cmd of the hostap case,
originally only support getting 'EAP-TLS' for the enterprise
mode, which is not correct. Now support getting the specific
enterprise mode, including the WPA3 enterprise mode and
the EAP method type.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
Change Wi-Fi suiteb type into WPA3 enterprise security type, it
includes suiteB, suiteB-192 and WPA3 enterprise only mode.
Support setting WPA3 enterprise only mode, which should use
cipher_config->key_mgmt as WPA-EAP-SHA256, and the AKM in RSN
IE will show 00-0F-AC:5.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
Remove EAP TLS SHA256 security, as it was added to support the AKM
of 00-0F-AC:5 in RSN IE, but actually this AKM is used by WPA3
enterprise only mode.
Signed-off-by: Maochen Wang <maochen.wang@nxp.com>
The check combination of "is zero" and then "less than zero" leaves open
the theoretical possibility of a positive return value, which would
continue on with an uinitialized 'sym'.
Checking for "not zero" has the same effect and covers all situations.
Commit 56fd85442 did the same thing for 'rela' a few lines above, but
missed this instance. No other places in the llext code have this issue.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Previously, filesystems could not be mounted at '/' because
mount points were restricted to being at least 2 characters.
Since '/' corresponds to the standard POSIX root filesystem
location, reduce the minimum length of a mount point to
1 character.
With that, we can mount a POSIX root filesystem.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
not force host variant if environment is setting something different in
the case of posix arch.
Fixes#83766
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
The Espressif branch of OpenOCD uses the version string "v0.12.0" instead
of "0.12.0" causing the version regex match to fail.
Add an optional 'v' prefix to avoid the failure.
Fixes: #83373
Signed-off-by: Eric Holmberg <eric.holmberg@northriversystems.co.nz>
The bus recovery feature utilizing bit-bang operations, which sends
SCL clock pulses to recover the bus and checks if the line is down.
Upon recovery, it disables the system test register before resuming
the transactions.
Signed-off-by: Dhruv Menon <dhruvmenon1104@gmail.com>
The OMAP I2C provides support for I2C serial interface on TI K3 series.
It is compatible with Philips I2C physical layer.
The commit includes:
Zephyr i2c api implementation
Polling Mode
Signed-off-by: Dhruv Menon <dhruvmenon1104@gmail.com>
The dma callback functions were written in a very confusing way, clean
them up, and this change also saves some bytes of ROM.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
move copy pasted code into common spot for when there is an invalid
configuration passed to the config function
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
There's no need to put an if before i2s_purge_stream_buffers,
because this is handled already by the boolean values entered to the
function
Also remove the inline of the function, which allowed the compiler to
make optimizations and save some bytes.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Put DT_DRV_COMPAT at top of file by custom
Consolidate logging macros
Clean up checks and use build assert
Remove header file which was not necessary
Remove unnecessary forward declarations
Fix the type of the stream state to be more precise, it is used as the
enum i2s_state type. This requires handling all the enum cases in switch
statements
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
In order to be functional and avoid linker errors, use a
default setting for BACKING_STORE_CHOICE that is something other
than "this is not implemented".
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The Xtensa linker scripts seem to be injecting syntax errors when
MMU is enabled. Disable the implication in Kconfig.mem for Xtensa
until linker issues are resolved.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Add possibility to set channel in diag mode by implementing
`platformRadioChannelSet` API.
Signed-off-by: Maciej Baczmanski <maciej.baczmanski@nordicsemi.no>
Fix platform radio state machine to be compliant with one shown in
OpenThread's `include/openthread/platform/radio.h`
Align twister tests to verify proper behavior of the
state machine.
Signed-off-by: Maciej Baczmanski <maciej.baczmanski@nordicsemi.no>
Both the TMAP kconfig file and public header file defined
which roles were supported.
The Kconfig file options were recently added and were more
up to date (and correct), and allows for other Kconfig files
to use these values, thus allowing for more flexibility when
implementing applications.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Change entries of the form:
"Proper Name <proper@email.xx> <proper@email.xx>"
to:
"Proper Name <proper@email.xx>"
This makes it clearer that no e-mail address mapping takes place in these
entries, only the "Proper Name" is mapped based on "<proper@email.xx>".
Normalize all e-mail mapping entries to:
"Proper Name <proper@email.xx> <other@email.xx>"
This makes it clearer which e-mail address is being mapped and follows the
formats listed in the gitmailmap documentation.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
Ensure that HTTP resources can only be served to a client connected on
the specific service(s) that the resource was registered against using
the HTTP_RESOURCE_DEFINE macro.
This allows different resources to be registered to different services,
for example to make some resources only available via an HTTPS service
and not via unencrypted HTTP.
Signed-off-by: Matt Rodgers <mrodgers@witekio.com>
add CONFIG_HAWKBIT_SAVE_PROGRESS_INTERVAL, to
be able to set a interval, how often the progress is saved.
Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
Previously, there were two separate Kconfig definitions
of ARM_MPU located at:
- arch/arm/core/mpu/Kconfig
- arch/arm64/core/cortex_r/Kconfig
This lead to incomplete default settings and unexpected
missing configurations.
This commit combines the two into a single unified definition
now located at arch/common/Kconfig to prevent this.
Signed-off-by: Samuel Chee <samche01@arm.com>