summaryrefslogtreecommitdiff
path: root/sound/soc/rockchip/rockchip_max98090.c
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2019-09-09 16:55:18 +0300
committerMark Brown <broonie@kernel.org>2019-09-09 16:55:18 +0300
commit6652ddbb5d83ecfc2591b92be063519714e40ebf (patch)
treeb1d088382aadb792e703b2f4035e0fc6584ca3c1 /sound/soc/rockchip/rockchip_max98090.c
parentf74c2bb98776e2de508f4d607cd519873065118e (diff)
parent73681f4f1426847b421649c6aa6c2dc303acc7c8 (diff)
downloadlinux-6652ddbb5d83ecfc2591b92be063519714e40ebf.tar.xz
Merge branch 'asoc-5.3' into asoc-linus
Diffstat (limited to 'sound/soc/rockchip/rockchip_max98090.c')
-rw-r--r--sound/soc/rockchip/rockchip_max98090.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/sound/soc/rockchip/rockchip_max98090.c b/sound/soc/rockchip/rockchip_max98090.c
index 782e534d4c0d..d54f672d38d8 100644
--- a/sound/soc/rockchip/rockchip_max98090.c
+++ b/sound/soc/rockchip/rockchip_max98090.c
@@ -138,8 +138,19 @@ static int rk_aif1_hw_params(struct snd_pcm_substream *substream,
return ret;
}
+static int rk_aif1_startup(struct snd_pcm_substream *substream)
+{
+ /*
+ * Set period size to 240 because pl330 has issue
+ * dealing with larger period in stress testing.
+ */
+ return snd_pcm_hw_constraint_minmax(substream->runtime,
+ SNDRV_PCM_HW_PARAM_PERIOD_SIZE, 240, 240);
+}
+
static const struct snd_soc_ops rk_aif1_ops = {
.hw_params = rk_aif1_hw_params,
+ .startup = rk_aif1_startup,
};
SND_SOC_DAILINK_DEFS(hifi,