summaryrefslogtreecommitdiff
path: root/sound/soc/rockchip/rockchip_max98090.c
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2019-08-20 20:28:43 +0300
committerMark Brown <broonie@kernel.org>2019-08-20 20:28:43 +0300
commitdd28d54c248fa37794dfa3d23a24ff99a1d3b6ac (patch)
tree066b7a24eb08527f47da41ac3fd3621d073a24d6 /sound/soc/rockchip/rockchip_max98090.c
parentd5e120422db8808e1c8b1507900ca393a877c58f (diff)
parentbf283a05c09b58db83afbb1a8a3c6a684c56c1bb (diff)
downloadlinux-dd28d54c248fa37794dfa3d23a24ff99a1d3b6ac.tar.xz
Merge branch 'asoc-5.3' into asoc-5.4
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 7b0c21fa6dca..0097df1fae66 100644
--- a/sound/soc/rockchip/rockchip_max98090.c
+++ b/sound/soc/rockchip/rockchip_max98090.c
@@ -137,8 +137,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,