Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM dicti… #2047

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

nordic-segl
Copy link
Contributor

@nordic-segl nordic-segl commented Sep 25, 2024

…onary mode

Extend STM logger test.
Use nrfutil trace to decode STM logs in dictionary mode. Add check if timing for a log message is below a threshold. Set thresholds experimentally.

Upstream PR: zephyrproject-rtos/zephyr#78947

manifest-pr-skip

@nordic-segl
Copy link
Contributor Author

One of cherry picked commits uses FLPR.
This PR must wait for upmerge.

@nordic-segl nordic-segl force-pushed the NRFX-6024_Extend-STM-dictionary-mode-testing branch 3 times, most recently from 271756d to 25115d7 Compare October 7, 2024 07:53
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 7, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
@nordic-segl nordic-segl force-pushed the NRFX-6024_Extend-STM-dictionary-mode-testing branch from 25115d7 to e9c272a Compare October 7, 2024 09:35
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 7, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 7, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
@nordic-segl nordic-segl removed the DNM label Oct 7, 2024
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 7, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
nordic-segl and others added 7 commits October 8, 2024 10:32
Add node with STMESP registers.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
(cherry picked from commit 8e22222)
…not needed

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>

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
(cherry picked from commit c2454f2)
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>
(cherry picked from commit c61e92a)
…pr support

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>
(cherry picked from commit d11997d)
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>

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
(cherry picked from commit 3786b61)
…ous API

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>

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
(cherry picked from commit c6f4e71)
…nous API

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>

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
(cherry picked from commit 2423312)
@nordic-segl nordic-segl force-pushed the NRFX-6024_Extend-STM-dictionary-mode-testing branch from e9c272a to d65f44a Compare October 8, 2024 08:32
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 8, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 8, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
@nordic-segl nordic-segl force-pushed the NRFX-6024_Extend-STM-dictionary-mode-testing branch from d65f44a to cc5f516 Compare October 8, 2024 10:53
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 8, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
…onary mode

Extend STM logger test.
Use nrfutil trace to decode STM logs in dictionary mode.

Upstream PR: zephyrproject-rtos/zephyr#78947

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
@nordic-segl nordic-segl force-pushed the NRFX-6024_Extend-STM-dictionary-mode-testing branch from cc5f516 to f451fa5 Compare October 8, 2024 11:02
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 8, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 8, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
nordic-segl added a commit to nordic-segl/sdk-nrf that referenced this pull request Oct 8, 2024
Include:
[nrf fromlist] samples: boards: nordic: coresight_stm: Test STM...
dictionary mode
nrfconnect/sdk-zephyr#2047

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants