Repository navigation
Topology: BYT: Adjust SRC pipeline for lower RAM consumption #2555
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -54,22 +54,22 @@ W_DATA(playback_pga_conf, playback_pga_tokens) | |
| # with 2 sink and 0 source periods | ||
| W_PCM_PLAYBACK(PCM_ID, Media Playback, 2, 0) | ||
|
|
||
| # "Playback Volume" has 2 sink period and 2 source periods for host ping-pong | ||
| W_PGA(0, PIPELINE_FORMAT, 2, 2, playback_pga_conf, LIST(` ', "PIPELINE_ID PCM PCM_ID Playback Volume")) | ||
| # "Playback Volume" has 3 sink period and 2 source periods for host ping-pong | ||
| W_PGA(0, PIPELINE_FORMAT, 3, 2, playback_pga_conf, LIST(` ', "PIPELINE_ID PCM PCM_ID Playback Volume")) | ||
|
|
||
| # "SRC 0" has 2 sink and source periods. | ||
| W_SRC(0, PIPELINE_FORMAT, 2, 2, media_src_conf) | ||
| # "SRC 0" has 3 sink and source periods. | ||
| W_SRC(0, PIPELINE_FORMAT, 3, 3, media_src_conf) | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. comment above seems inconsistent?
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think there was a mistake in topology originally. There's similar for W_PGA() above but I didn't change it yet. It could be 3, 3 since the buffers are anyway allocated such way. Maybe I should change it too?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yep, please change comment.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's fixed now. I also changed B0 to 2 periods, no need for 3, and changed for volume component sink to 3 periods to match B1. |
||
|
|
||
| # Media Source Buffers to SRC, make them big enough to deal with 2 * rate. | ||
| W_BUFFER(0, COMP_BUFFER_SIZE(4, | ||
| # Media Source Buffers to SRC | ||
| W_BUFFER(0, COMP_BUFFER_SIZE(2, | ||
| COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS, COMP_PERIOD_FRAMES(PCM_MAX_RATE, SCHEDULE_PERIOD)), | ||
| PLATFORM_HOST_MEM_CAP) | ||
| W_BUFFER(1,COMP_BUFFER_SIZE(4, | ||
| W_BUFFER(1,COMP_BUFFER_SIZE(3, | ||
| COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS, COMP_PERIOD_FRAMES(PCM_MAX_RATE, SCHEDULE_PERIOD)), | ||
| PLATFORM_COMP_MEM_CAP) | ||
|
|
||
| # Buffer B2 is on fixed rate sink side of SRC. | ||
| W_BUFFER(2, COMP_BUFFER_SIZE(4, | ||
| W_BUFFER(2, COMP_BUFFER_SIZE(3, | ||
| COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS, COMP_PERIOD_FRAMES(PCM_MAX_RATE, SCHEDULE_PERIOD)), | ||
| PLATFORM_COMP_MEM_CAP) | ||
|
|
||
|
|
||
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.
humm, how does removing 96kHz -> 48kHz reduce RAM consumption. It's rather straightforward with a 1/2 ratio and subsampling?
Or did you mean that this included 88.2->48kHz which is indeed useless?
Wondering if the range is the problem, and if we need a discrete set of frequencies instead.
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.
@plbossart I guess because buffering is always 1ms so 96000 -> bigger buffers after src...
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.
before src I meant...
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.
Yep, the macro to compute buffer sizes handles this.