Skip to content

probe: zero-initialize DMA config in probe_dma_init() - #11474

Merged
dbaluta merged 1 commit into
thesofproject:mainfrom
ursus161:probe-dma-cfg-init
Nov 18, 2026
Merged

dbaluta merged 1 commit into
thesofproject:mainfrom
ursus161:probe-dma-cfg-init

Conversation

@ursus161

Copy link
Copy Markdown

dma_cfg and dma_block_cfg are only partly filled before dma_config(), so the remaining fields (callback, burst lengths, next_block, ...) hold stack garbage. Zero-initialize both structs.

@sofci

sofci commented Nov 17, 2026

Copy link
Copy Markdown
Collaborator

Can one of the admins verify this patch?

reply test this please to run this test once

Comment thread src/kernel/probe/probe.c Resolved
@dbaluta

dbaluta commented Nov 17, 2026

Copy link
Copy Markdown
Collaborator

Can one of the admins verify this patch?

reply test this please to run this test once

test this please

dma_cfg and dma_block_cfg are only partly filled in before
dma_config() is called, so the remaining fields (callback, burst
lengths, next_block, ...) hold stack garbage. Zero-initialize both
structs.

Signed-off-by: Stefan Ghetu <stefan.ghetu@nxp.com>
@dbaluta

dbaluta commented Nov 17, 2026

Copy link
Copy Markdown
Collaborator

LGTM now, @lyakh @lgirdwood please have a quick look.

@dbaluta
dbaluta merged commit b00b993 into thesofproject:main Nov 18, 2026
41 checks passed
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.

5 participants