diff options
author | Olivier Moysan <olivier.moysan@st.com> | 2019-02-26 14:51:10 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-02-26 15:42:10 +0000 |
commit | 7b6b0049e2b70d103adf1b7d0320802f70ddceca (patch) | |
tree | 946c00851c3290ef2e7c1176eca141696565d06d /sound/soc | |
parent | 3005decf4fe43e65d882dce838716bd6715757c1 (diff) | |
download | linux-7b6b0049e2b70d103adf1b7d0320802f70ddceca.tar.gz linux-7b6b0049e2b70d103adf1b7d0320802f70ddceca.tar.bz2 linux-7b6b0049e2b70d103adf1b7d0320802f70ddceca.zip |
ASoC: stm32: i2s: skip useless write in slave mode
Dummy write in capture master mode is used to gate
bus clocks. This write is useless in slave mode
as the clocks are not managed by slave.
Signed-off-by: Olivier Moysan <olivier.moysan@st.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/stm/stm32_i2s.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/stm/stm32_i2s.c b/sound/soc/stm/stm32_i2s.c index 42ce87a35104..47c334de6b09 100644 --- a/sound/soc/stm/stm32_i2s.c +++ b/sound/soc/stm/stm32_i2s.c @@ -623,8 +623,8 @@ static int stm32_i2s_trigger(struct snd_pcm_substream *substream, int cmd, } else { ier = I2S_IER_OVRIE; - if (i2s->refcount == 1) - /* dummy write to trigger capture */ + if (STM32_I2S_IS_MASTER(i2s) && i2s->refcount == 1) + /* dummy write to gate bus clocks */ regmap_write(i2s->regmap, STM32_I2S_TXDR_REG, 0); } |