mirror of https://github.com/thesofproject/sof.git
[RTNR] Fix buffer size calculation
The correct frame length should be calculated by FRAME_LEN = SAMPLING_RATE * PERIODS / 1000000 The macro COMP_PERIOD_FRAMES does the thing. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org> Signed-off-by: Ming Jen Tai <mingjen_tai@realtek.com>
This commit is contained in:
parent
3e6fd30aa6
commit
a5fd52ec43
|
@ -60,11 +60,11 @@ W_RTNR(0, PIPELINE_FORMAT, 2, DAI_PERIODS, DMIC_PIPELINE_16k_CORE_ID, LIST(` ',
|
|||
# Capture Buffers
|
||||
W_BUFFER(0, COMP_BUFFER_SIZE(4,
|
||||
COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS,
|
||||
eval(PCM_MAX_RATE / SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
COMP_PERIOD_FRAMES(PCM_MAX_RATE, SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
|
||||
W_BUFFER(1, COMP_BUFFER_SIZE(4,
|
||||
COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS,
|
||||
eval(PCM_MAX_RATE / SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
COMP_PERIOD_FRAMES(PCM_MAX_RATE, SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
|
||||
P_GRAPH(pipe-rtnr-capture-PIPELINE_ID, PIPELINE_ID,
|
||||
LIST(` ',
|
||||
|
|
|
@ -60,11 +60,11 @@ W_RTNR(0, PIPELINE_FORMAT, 2, DAI_PERIODS, SCHEDULE_CORE, LIST(` ', "DEF_RTNR_B
|
|||
# Capture Buffers
|
||||
W_BUFFER(0, COMP_BUFFER_SIZE(4,
|
||||
COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS,
|
||||
eval(PCM_MAX_RATE / SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
COMP_PERIOD_FRAMES(PCM_MAX_RATE, SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
|
||||
W_BUFFER(1, COMP_BUFFER_SIZE(4,
|
||||
COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS,
|
||||
eval(PCM_MAX_RATE / SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
COMP_PERIOD_FRAMES(PCM_MAX_RATE, SCHEDULE_PERIOD)), PLATFORM_PASS_MEM_CAP)
|
||||
|
||||
P_GRAPH(pipe-rtnr-capture-PIPELINE_ID, PIPELINE_ID,
|
||||
LIST(` ',
|
||||
|
|
Loading…
Reference in New Issue