Skip to contentSkip to conversation

ASoC: TSCS42xx: Add CCF support to get sysclk

PATCH Superseded Steven Eckhoff 1 participant 1 message Mar 27, 2018

Subsystems (4)

v2 of 3 Superseded Latest is v3 →

lore
Share & tools
lore

Steven Eckhoff

author maintainer
#0 lore raw

PATCH v2 3/3 ASoC: TSCS42xx: Add CCF support to get sysclk

The TSCS42xx relies on set_sysclk to get a unique clock id and rate, which
prevents it from being used with the simple-card.

Remove set_sysclk callback
Add CCF support to get clock id and rate
Add clocks and clock-names to device tree binding

---
 .../devicetree/bindings/sound/tscs42xx.txt         |   6 ++
 sound/soc/codecs/tscs42xx.c                        | 104 ++++++++++++++-------
 sound/soc/codecs/tscs42xx.h                        |   2 +-
 3 files changed, 75 insertions(+), 37 deletions(-)
Documentation/devicetree/bindings/sound/tscs42xx.txt +6 -0
index 2ac2f0996697..7eea32e9d078 100644
@@ -8,9 +8,15 @@ Required Properties:
 	- reg : 	<0x71> for analog mic
 			<0x69> for digital mic
 
+	- clock-names:	Must one of  the following "mclk1", "xtal", "mclk2"
+
+	- clocks:	phandle of the clock that provides the codec sysclk
+
 Example:
 
 wookie: codec@69 {
 	compatible = "tempo,tscs42A2";
 	reg = <0x69>;
+	clock-names = "xtal";
+	clocks = <&audio_xtal>;
 };
sound/soc/codecs/tscs42xx.c +68 -36

157 lines not on this page · raw message

sound/soc/codecs/tscs42xx.h +1 -1
index d4a30bcbf64b..814c8f3c4a68 100644
@@ -7,10 +7,10 @@
 #define __WOOKIE_H__
 
 enum {
-	TSCS42XX_PLL_SRC_NONE,
 	TSCS42XX_PLL_SRC_XTAL,
 	TSCS42XX_PLL_SRC_MCLK1,
 	TSCS42XX_PLL_SRC_MCLK2,
+	TSCS42XX_PLL_SRC_CNT,
 };
 
 #define R_HPVOLL        0x0
Signature · 1 line
2.15.1