ASoC: mediatek: HDMI audio LR channel swapped
authorPC Liao <pc.liao@mediatek.com>
Tue, 26 Apr 2016 06:30:18 +0000 (14:30 +0800)
committerMark Brown <broonie@kernel.org>
Tue, 26 Apr 2016 10:25:51 +0000 (11:25 +0100)
Because LRCK of TDM use High to Low as default setting, this patch
changes the TDM setting to inverse LRCK.

Signed-off-by: PC Liao <pc.liao@mediatek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/mediatek/mtk-afe-pcm.c

index f1c58a2c12fbbd8420614c576f75a19cf90c08e6..2b5df2ef51a332d99bd2182c0f88a0b58e1cbfb3 100644 (file)
 #define AFE_TDM_CON1_WLEN_32BIT                (0x2 << 8)
 #define AFE_TDM_CON1_MSB_ALIGNED       (0x1 << 4)
 #define AFE_TDM_CON1_1_BCK_DELAY       (0x1 << 3)
+#define AFE_TDM_CON1_LRCK_INV          (0x1 << 2)
 #define AFE_TDM_CON1_BCK_INV           (0x1 << 1)
 #define AFE_TDM_CON1_EN                        (0x1 << 0)
 
@@ -449,6 +450,7 @@ static int mtk_afe_hdmi_prepare(struct snd_pcm_substream *substream,
                              runtime->rate * runtime->channels * 32);
 
        val = AFE_TDM_CON1_BCK_INV |
+             AFE_TDM_CON1_LRCK_INV |
              AFE_TDM_CON1_1_BCK_DELAY |
              AFE_TDM_CON1_MSB_ALIGNED | /* I2S mode */
              AFE_TDM_CON1_WLEN_32BIT |