ASoC: rockchip: i2s: Add SNDRV_PCM_FMTBIT_S32_LE support
authorMichael Trimarchi <michael@amarulasolutions.com>
Sat, 9 Jan 2016 22:47:58 +0000 (23:47 +0100)
committerMark Brown <broonie@kernel.org>
Sun, 10 Jan 2016 11:57:26 +0000 (11:57 +0000)
Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/rockchip/rockchip_i2s.c

index 8b0a588ed6220b3a3ab7845a3b6af3e55ae51ac6..6561c4cc2eddbac035cec09ddd51dead9d3d8c22 100644 (file)
@@ -242,6 +242,9 @@ static int rockchip_i2s_hw_params(struct snd_pcm_substream *substream,
        case SNDRV_PCM_FORMAT_S24_LE:
                val |= I2S_TXCR_VDW(24);
                break;
+       case SNDRV_PCM_FORMAT_S32_LE:
+               val |= I2S_TXCR_VDW(32);
+               break;
        default:
                return -EINVAL;
        }
@@ -360,7 +363,8 @@ static struct snd_soc_dai_driver rockchip_i2s_dai = {
                .formats = (SNDRV_PCM_FMTBIT_S8 |
                            SNDRV_PCM_FMTBIT_S16_LE |
                            SNDRV_PCM_FMTBIT_S20_3LE |
-                           SNDRV_PCM_FMTBIT_S24_LE),
+                           SNDRV_PCM_FMTBIT_S24_LE |
+                           SNDRV_PCM_FMTBIT_S32_LE),
        },
        .capture = {
                .stream_name = "Capture",
@@ -370,7 +374,8 @@ static struct snd_soc_dai_driver rockchip_i2s_dai = {
                .formats = (SNDRV_PCM_FMTBIT_S8 |
                            SNDRV_PCM_FMTBIT_S16_LE |
                            SNDRV_PCM_FMTBIT_S20_3LE |
-                           SNDRV_PCM_FMTBIT_S24_LE),
+                           SNDRV_PCM_FMTBIT_S24_LE |
+                           SNDRV_PCM_FMTBIT_S32_LE),
        },
        .ops = &rockchip_i2s_dai_ops,
        .symmetric_rates = 1,