Skip to content

Conversation

@nordic-krch
Copy link
Contributor

Fixes for:

  • unaligned access in STM frontend (RISCV only)
  • ETR processing hanging when there is an incomplete message in the buffer

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.

Upstream PR: zephyrproject-rtos/zephyr#78333

Signed-off-by: Krzysztof Chruściński <[email protected]>
Apply clang-format formatting.

Upstream PR: zephyrproject-rtos/zephyr#78332

Signed-off-by: Krzysztof Chruściński <[email protected]>
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.

Upstream PR: zephyrproject-rtos/zephyr#78332

Signed-off-by: Krzysztof Chruściński <[email protected]>
@rlubos rlubos merged commit 5bb7bb0 into nrfconnect:main Sep 20, 2024
19 checks passed
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.

5 participants