From 1eee7abe7c39268b1782b216c1bb7009f4b4777e Mon Sep 17 00:00:00 2001 From: Shengjiu Wang Date: Thu, 12 Sep 2019 17:55:19 +0800 Subject: 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 (cherry picked from commit 3a1a4abc02cfef9fddf0ceef2045c46eaa960c5c) --- sound/soc/fsl/fsl_easrc.c | 24 ++++-------------------- 1 file changed, 4 insertions(+), 20 deletions(-) (limited to 'sound/soc/fsl/fsl_easrc.c') 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; -- cgit v1.2.3