Commit d22e28cc authored by Nicolin Chen's avatar Nicolin Chen Committed by Mark Brown

ASoC: fsl_sai: Drop useless channels check in hw_params()

SAi only supports two data channels on hardware level and the driver also does
register the min->1 and max->2, so no need to check channels.
Signed-off-by: default avatarNicolin Chen <Guangyu.Chen@freescale.com>
Reviewed-by: default avatarXiubo Li <Li.Xiubo@freescale.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 1d700309
......@@ -278,10 +278,7 @@ static int fsl_sai_hw_params(struct snd_pcm_substream *substream,
val_cr5 |= FSL_SAI_CR5_FBT(0);
val_cr4 |= FSL_SAI_CR4_FRSZ(channels);
if (channels == 2 || channels == 1)
val_mr = ~0UL - ((1 << channels) - 1);
else
return -EINVAL;
val_mr = ~0UL - ((1 << channels) - 1);
sai_writel(sai, val_cr4, sai->base + reg_cr4);
sai_writel(sai, val_cr5, sai->base + reg_cr5);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment