summaryrefslogtreecommitdiff
path: root/sound/soc/fsl/fsl_easrc.c
diff options
context:
space:
mode:
authorShengjiu Wang <shengjiu.wang@nxp.com>2019-09-12 17:55:19 +0800
committerDong Aisheng <aisheng.dong@nxp.com>2019-11-25 15:48:51 +0800
commit1eee7abe7c39268b1782b216c1bb7009f4b4777e (patch)
tree67f09896411df919e86846eb6729d96310d6dc23 /sound/soc/fsl/fsl_easrc.c
parente5b7fd131b892dc52049640eadc8accaadf41f7f (diff)
MLK-22575-2: ASoC: fsl_easrc: disable PF_BYPASS_MODE
When run conversion in parrallel, one is down sampling, another is up sampling, so one enables PF_BYPASS_MODE, another disable PF_BYPASS_MODE, when the allocated slots in a same context processor, there is noise in the result of down sampling. If we alway disable PF_BYPASS_MODE, the issue can't be reproduced. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> (cherry picked from commit 3a1a4abc02cfef9fddf0ceef2045c46eaa960c5c)
Diffstat (limited to 'sound/soc/fsl/fsl_easrc.c')
-rw-r--r--sound/soc/fsl/fsl_easrc.c24
1 files changed, 4 insertions, 20 deletions
diff --git a/sound/soc/fsl/fsl_easrc.c b/sound/soc/fsl/fsl_easrc.c
index d45f4cc75065..7da6902fa6fa 100644
--- a/sound/soc/fsl/fsl_easrc.c
+++ b/sound/soc/fsl/fsl_easrc.c
@@ -565,27 +565,11 @@ static int fsl_easrc_prefilter_config(struct fsl_easrc *easrc,
ctx->st2_num_taps = 0;
ctx->st1_addexp -= ctx->in_params.fmt.addexp;
} else {
- /* set pf in bypass mode */
- ret = regmap_update_bits(easrc->regmap,
- REG_EASRC_CCE1(ctx_id),
- EASRC_CCE1_PF_BYPASS_MASK,
- EASRC_CCE1_PF_BYPASS);
- if (ret)
- return ret;
-
- /* PF_EXPANSION_FACTOR must be set to 0x0 when
- * operating in bypass mode
- */
- ret = regmap_update_bits(easrc->regmap,
- REG_EASRC_CCE1(ctx_id),
- EASRC_CCE1_PF_EXP_MASK,
- EASRC_CCE1_PF_EXP(0));
- if (ret)
- return ret;
-
- return 0;
+ ctx->st1_num_taps = 1;
+ ctx->st1_coeff = &coeff;
+ ctx->st1_num_exp = 1;
+ ctx->st2_num_taps = 0;
}
-
} else {
inrate = ctx->in_params.norm_rate;
outrate = ctx->out_params.norm_rate;