Skip to content

debug: telemetry: prevent system workqueue stack overflow - #11553

Open
piotrhoppeintel wants to merge 1 commit into
thesofproject:mainfrom
piotrhoppeintel:error/21046322281_lnl_adsp-ipc-fialure-4-core
Open

piotrhoppeintel wants to merge 1 commit into
thesofproject:mainfrom
piotrhoppeintel:error/21046322281_lnl_adsp-ipc-fialure-4-core

Conversation

@piotrhoppeintel

Copy link
Copy Markdown
Contributor

Move telemetry collection buffers from the stack to static storage. Increase the system workqueue stack size to accommodate Xtensa interrupt frames during telemetry processing.

Move telemetry collection buffers from the stack to static storage.
Increase the system workqueue stack size to accommodate Xtensa interrupt
frames during telemetry processing.
@piotrhoppeintel
piotrhoppeintel force-pushed the error/21046322281_lnl_adsp-ipc-fialure-4-core branch from 9f34ed6 to b38a2b7 Compare November 27, 2026 19:13
@abonislawski
abonislawski marked this pull request as ready for review November 30, 2026 08:57
Copilot AI balanced review requested due to automatic review settings November 30, 2026 08:58

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Unsynchronized concurrent pipeline rebuilds can overwrite the shared staging buffer, publish incomplete telemetry slots, and lose saved XRUN counts.

1 open issue
What changed in this PR

This PR reduces telemetry’s system workqueue stack usage by moving collection buffers to static storage, helping prevent stack overflow during telemetry processing.

Changes:

  • Move pipeline staging slots and the thread collection context off the stack.
  • Update buffer initialization and context access for static storage.
  • The supplied diff does not include the stack-size increase mentioned in the description.
File Description
src/​kernel/​debug/​telemetry/​telemetry.c Moves pipeline and thread collection buffers to static storage and updates their usage.

Review effort: Balanced

struct sof_tel_ppl_section *psec = &wnd->ppl_sec;
struct sof_tel_hot_line0 *hot0 = telemetry_get_hot_line0();
struct tel_ppl_slot new_slots[SOF_TEL_MAX_PIPELINES];
struct tel_ppl_slot *new_slots = tel_ppl_slots_staging;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants