summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/ak4458.h
diff options
context:
space:
mode:
authorShengjiu Wang <shengjiu.wang@nxp.com>2020-09-15 16:57:00 +0300
committerMark Brown <broonie@kernel.org>2020-09-17 19:40:13 +0300
commit337d348b8399adf1a19c8d65f6407939b4743fc9 (patch)
tree01bae50167a68442e01139e38057c5742ff49089 /sound/soc/codecs/ak4458.h
parentfc50e26de9677206ae43a261ddc4181ed7e4af78 (diff)
downloadlinux-337d348b8399adf1a19c8d65f6407939b4743fc9.tar.xz
ASoC: ak4458: Add DSD support for ak4458 and ak4497
Ak4458 can't support DSD512 format, but ak4497 can, so add a new enum variable (enum ak4458_type) in ak4458_drvdata to distinguish these two platforms. Ak4497 has two kinds of DSD input pin, it can be selected by the dsd-path property from DT. In hw_params(), bit clock is calculated according to different DSD format (DSD64, DSD128, DSD256, DSD512), then registers are configured. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Link: https://lore.kernel.org/r/1600178220-28973-2-git-send-email-shengjiu.wang@nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/ak4458.h')
-rw-r--r--sound/soc/codecs/ak4458.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/sound/soc/codecs/ak4458.h b/sound/soc/codecs/ak4458.h
index f906215f7e4e..9548c5d78621 100644
--- a/sound/soc/codecs/ak4458.h
+++ b/sound/soc/codecs/ak4458.h
@@ -83,4 +83,7 @@
#define AK4458_ATS_SHIFT 6
#define AK4458_ATS_MASK GENMASK(7, 6)
-#endif /* _AK4458_H */
+#define AK4458_DSDSEL_MASK (0x1 << 0)
+#define AK4458_DP_MASK (0x1 << 7)
+
+#endif