The declaration for the text region '__text_region_start' and
'__text_region_end' should be consistent with the declaration in the
include file 'zephyr/linker/linker-defs.h'.
The local declarations are:
extern uintptr_t __text_region_start, __text_region_end;
whereas 'linker_defs.h' declares them as:
extern char __text_region_start[];
extern char __text_region_end[];
This may result in conflicting types when 'linker_defs.h' is indirectly
included. Hence, remove the local declarations.
Signed-off-by: Christoph Winklhofer <cj.winklhofer@gmail.com>
The logging module data is assigned to the memory partition
'k_log_partition' so that a user mode thread can access this data (see
k_mem_domain_add_thread()). The 'k_log_partition' is created when:
- CONFIG_USERSPACE=y
- CONFIG_LOG_ALWAYS_RUNTIME=y
The option CONFIG_NO_OPTIMIZATIONS=y forces the logging module to use
the runtime message creation CONFIG_LOG_ALWAYS_RUNTIME=y. This raises a
MPU violation when logging is used in a user mode thread since this
thread is not allowed to access the module data (e.g. __log_level,
__log_current_const_data).
Note that the user mode thread may also require access to the partition
'z_libc_partition'.
Signed-off-by: Christoph Winklhofer <cj.winklhofer@gmail.com>
The runtime message creation (CONFIG_LOG_ALWAYS_RUNTIME=y) in a user-
mode thread raises a MPU violation, e.g. call LOG_INF("Test") in a
user-mode thread.
The function 'z_log_msg_runtime_vcreate' runs in user mode but works
with Kernel data. Hence, create the cbprintf package on the stack (of
the user mode thread) and pass it further to the syscall
'z_log_msg_static_create'.
Signed-off-by: Christoph Winklhofer <cj.winklhofer@gmail.com>
This function is used for testing purposes only, there is no real use
for it in a user application. Remove in favor of implementation in new
device stack.
Also remove the part of the documentation that depends on loopback.
Documentation on how to implement your own USB device function using the
new USB device support will follow during the documentation rework.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Un-ignore diff and patch files for CheckPatch.
This was originally added to avoid throwing false-positives when diff
and patch files were actually in the repo, since it would incorrectly
try to perform code-formatting checks on those files instead of on
the content of the commit.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The low level function names in the stm32l4xx low level driver are
different than all the other stm32's even though the functionality is the
same. This breaks the entropy module for these parts. This patch fixes the
build and has been tested on a custom stm32l4p5 board.
This STM32CubeL4 issue has been reported (ST Internal Reference: 207828).
Fixes: https://github.com/zephyrproject-rtos/zephyr/issues/88621
Signed-off-by: Matt Ihnen <matt.ihnen@gmail.com>
Addressed an issue where alignment of dma desc varaible
of dma0 is corrected to 1024 instead of 512.
Signed-off-by: Sai Santhosh Malae <Santhosh.Malae@silabs.com>
Addressed an issue where regular/non-scatter-gather DMA
transfers were not explicitly using the primary DMA descriptor
structure. This ensures a smooth regular DMA transfer after
any scatter gather transfer.
Signed-off-by: Sai Santhosh Malae <Santhosh.Malae@silabs.com>
Introduced a new variable in the `dma_siwx91x_channel_info`
structure to provide a clean way to differentiate transfer
directions. This enhancement is utilized to trigger software
requests specifically for memory-to-memory transfers
Signed-off-by: Sai Santhosh Malae <Santhosh.Malae@silabs.com>
The mod_src_param was several places stored on the stack.
However this is a complex paramater struct that has
2 Kconfig options that can significantly increase the size,
and the maximum size of the parameter is nearly 8 KiB, and
was always place the in the BT RX thread's stack.
For this reason, the param is now stored in a single
static variable in RAM instead, so that the BT RX thread's stack
does not need to be increased based on the Kconfig options,
as that is quite difficult for users to be aware of.
The add_src_param has been left as is, as that stored in
the calling thread, and it is easier for an application
to determine if the calling thread needs additional stack
space.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Bad Broadcast Code in BASS/Scan Delegator if BIG_Encryption
field value = 0x03 (Bad_Code), Bad_Code shall be set to the
value 0xFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF according to BASS v1.0.1
Signed-off-by: Gudipudi Ramana Kumar <gudipudiramanakumar@gmail.com>
Adds a configuration file which is used with nrfutil to allow
programming the SPI flash on the device
Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
Fixes an issue in which "SDHC" had been incorrectly expanded to
"Secure Digital High Capacity" instead of "SD Host Controller".
Since this page is listed under "Peripherals" and since the
SD Host Controller API is not supposed to be used by applications,
the more generic and recognizable title "SD card interface" is used,
and users are pointed to pages relevant to them (disk access API
and SD card subsystem).
Signed-off-by: Egill Sigurdur <egill@egill.xyz>
In Clang 16 run with some flags, the compiler does not accept a static
const variables as struct initializer. This caused build errors in only
some contexts. Always use the devicetree macros to access the source
device node as a workaround.
Signed-off-by: Josuah Demangeon <me@josuah.net>
In STM32N6, AXISRAM1 is next to the 400kB FLEXRAM.
By default, the FLEXRAM is configured to extend the AXISRAM1 which put
its total size to 1024kB.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Add stub functions for the I2C DMA callbacks, which are invoked
during or upon completion of DMA-based I2C transactions. Without
these, NULL pointer calls occur on DMA transfer complete or error
events, leading to faults within ISR context.
Signed-off-by: Simon Gilbert <srdgilbert@gmail.com>
Use the default kernel clock (HCLK5) for the XSPI instances instead of the
peripheral clock which may not be enabled at all.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Use HSE as system source clock and adjust the different clock parameters
to use the highest admissible frequency (according to datasheet DS14791):
- CPU clock: 800MHz
- NPU clock: 1000MHz
- AXI clock: 800MHz
- AHB clock: 200MHz
Remove the setting of APB prescalers since they are constants set to 1.
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Errata sheet ES0620 indicates that STM32N6 APB prescalers cannot be
modified.
Fixes the value of all APB prescalers to 1 (default value).
Signed-off-by: Guillaume Gautier <guillaume.gautier-ext@st.com>
Commit f7633a55aa moved the tests for the
POSIX_SEMAPHORES Option Group from the tests/posix/common testsuite to
its own dedicated testsuite.
However, there was a copy-paste error. Previously, tests would have been
run only once when dynamic threads were enabled, and then skipped when
dynamic threads were disabled, since that follows the posix programming
model better. However, dynamic threads were never actually enabled after
moving to the new testsuite. So all tests were effectively skipped.
Add the necessary options to prj.conf in order to ensure that there are
sufficient dynamic threads available to run the testsuite.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
There is no reason to use a 5s wait time in tests. This can add up quite
significantly across multiple platforms that execute in real-time under
qemu (or even just on real hardware).
Speedup observed with qemu_cortex_a53/qemu_cortex_a53/smp
Before:
```
START - test_named_semaphore
PASS - test_named_semaphore in 5.688 seconds
```
After:
```
START - test_named_semaphore
PASS - test_named_semaphore in 0.783 seconds
```
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
The implementation of POSIX_SEMAPHORES historically used heap allocation
and has not yet been transitioned to a pool allocator.
However, since 590258b381, the default heap-add with CONFIG_POSIX_API
has been reduced from 1 kiB which causes tests/posix/semaphores to fail
due to NULL being returned from a call to k_calloc().
Create a minimal heap-add for the POSIX_SEMAPHORES Option Group.
This can be removed at a future date if semaphores are changed to use
a pooled allocator and fixed-size name, rather than heap allocation.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
0f05f58bf5 assigned the `arduino_i2c` to the incorrect pins for the Arduino UNO connector. This assigns them back.
signed-off-by: Glenn Andrews <glenn.andrews.42@gmail.com>
This patch allows ti_dmtimer to provide the symbol z_sys_timer_irq_for_test
whenever tests are enabled. Not providing this results in failing some
kernel test cases which require this symbol.
Signed-off-by: Amneesh Singh <a-singh7@ti.com>
Release completion queue events left over from the previous test and
make sure a completion queue event gets released after it is consumed.
Otherwise newer cqes may be unable to be submitted due to completion
queue being full.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Call i2c_rtio_complete with a non-zero status code in case of an error
so that application does not get stuck waiting for the completion queue
event. An example to this situation could be an I2C target device
responding with a NACK to a read or write request by the controller.
Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>