aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPuyou Lu <[email protected]>2020-07-02 10:30:56 +0800
committerMark Brown <[email protected]>2020-07-09 19:55:28 +0100
commit01283d56f0ea0040b64dc785542f3ad3fb8b3e68 (patch)
tree7161e9fd0cc6b9d77b321fd031953f6af019824c
parent574ea5c80eb18edd0d93864985650efec63347c0 (diff)
ASoC: wm8974: remove unsupported clock mode
In DSP_A mode, BIT7 of IFACE should bit 0 according to datasheet (ie. inverted frame clock is not support in this mode). Signed-off-by: Puyou Lu <[email protected]> Acked-by: Charles Keepax <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
-rw-r--r--sound/soc/codecs/wm8974.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sound/soc/codecs/wm8974.c b/sound/soc/codecs/wm8974.c
index 764bf93fb58a..7cfc89602fc3 100644
--- a/sound/soc/codecs/wm8974.c
+++ b/sound/soc/codecs/wm8974.c
@@ -474,6 +474,10 @@ static int wm8974_set_dai_fmt(struct snd_soc_dai *codec_dai,
iface |= 0x0008;
break;
case SND_SOC_DAIFMT_DSP_A:
+ if ((fmt & SND_SOC_DAIFMT_INV_MASK) == SND_SOC_DAIFMT_IB_IF ||
+ (fmt & SND_SOC_DAIFMT_INV_MASK) == SND_SOC_DAIFMT_NB_IF) {
+ return -EINVAL;
+ }
iface |= 0x00018;
break;
default: