-
Notifications
You must be signed in to change notification settings - Fork 325
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
Audio: Volume: Clear peak meter channel max values in prepare() #9411
Audio: Volume: Clear peak meter channel max values in prepare() #9411
Conversation
@kv2019i pls review/merge |
src/audio/volume/volume_ipc4.c
Outdated
@@ -147,6 +147,7 @@ int volume_init(struct processing_module *mod) | |||
return -ENOMEM; | |||
} | |||
|
|||
memset(cd->peak_vol, 0, vol_size); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just rzalloc()
above. BTW, is the .peak_vol
allocation needed if CONFIG_COMP_PEAK_VOL
is undefined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's spread to nearly every volume source file, I'll add it to another commit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have always for IPC4 systems CONFIG_COMP_PEAK_VOL=y, I don't think it makes sense to make a quite large patch in rush for 2.11. It would make sense if we would have another volume component for ChromeOS and Linux those do not use the peak values reporting from volume.
This patch avoids garbage values to be sent to mailbox by peak_vol_update() as very first peak volume measurement in stream start. The data structures cd->peak_vol and cd->peak_regs.peak_meter were not cleared. Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
9cb1ee4
to
09417f5
Compare
Ack @lgirdwood -- I couldn't get any PRs through on Friday (waiting on 9472) through Intel internal CI, so that's a potential problem for today as well. So in practise it depends on now 9472. We can't tag rc1 before that is in, so if we have other PRs ready before that, we can include. |
This patch avoids garbage values to be sent to mailbox by peak_vol_update() as very first peak volume measurement in stream start. The data structures cd->peak_vol and cd->peak_regs.peak_meter were not cleared.