All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] Add support for es8323 on the firefly-rk3288
@ 2017-01-17  9:12 Romain Perier
  2017-01-17  9:12 ` [PATCH 1/2] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
  2017-01-17  9:12 ` [PATCH 2/2] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
  0 siblings, 2 replies; 3+ messages in thread
From: Romain Perier @ 2017-01-17  9:12 UTC (permalink / raw)
  To: Heiko Stuebner, devicetree, Rob Herring, Ian Campbell,
	Pawel Moll, Mark Rutland, Kumar Gala, Jaroslav Kysela,
	Takashi Iwai, alsa-devel
  Cc: Romain Perier, linux-rockchip, Sjoerd Simons, linux-arm-kernel

This set of patches enables support for the es8323 codecs on the
firefly-rk3288. It adds the required DT definitions to link rockchip-i2s
to the es8388 analog output.

Romain Perier (2):
  SoC: es8328-i2c: Add compatible for ES8323
  arm: dts: Add support for ES8323 to the Firefly-RK3288

 Documentation/devicetree/bindings/sound/es8328.txt |  5 ++++-
 arch/arm/boot/dts/rk3288-firefly.dtsi              | 25 ++++++++++++++++++++++
 sound/soc/codecs/es8328-i2c.c                      |  2 ++
 3 files changed, 31 insertions(+), 1 deletion(-)

-- 
2.9.3

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH 1/2] SoC: es8328-i2c: Add compatible for ES8323
  2017-01-17  9:12 [PATCH 0/2] Add support for es8323 on the firefly-rk3288 Romain Perier
@ 2017-01-17  9:12 ` Romain Perier
  2017-01-17  9:12 ` [PATCH 2/2] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
  1 sibling, 0 replies; 3+ messages in thread
From: Romain Perier @ 2017-01-17  9:12 UTC (permalink / raw)
  To: Heiko Stuebner, devicetree, Rob Herring, Ian Campbell,
	Pawel Moll, Mark Rutland, Kumar Gala, Jaroslav Kysela,
	Takashi Iwai, alsa-devel
  Cc: Romain Perier, linux-rockchip, Sjoerd Simons, linux-arm-kernel

This commit adds a compatible string for everest,es8323. This is an
audio codec that is compatible with es8328 and can be found for example
on the Firefly-RK3288 board.

Signed-off-by: Romain Perier <romain.perier@collabora.com>
---
 Documentation/devicetree/bindings/sound/es8328.txt | 5 ++++-
 sound/soc/codecs/es8328-i2c.c                      | 2 ++
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/sound/es8328.txt b/Documentation/devicetree/bindings/sound/es8328.txt
index 33fbf05..86b6d6e 100644
--- a/Documentation/devicetree/bindings/sound/es8328.txt
+++ b/Documentation/devicetree/bindings/sound/es8328.txt
@@ -4,7 +4,10 @@ This device supports both I2C and SPI.
 
 Required properties:
 
-  - compatible  : Should be "everest,es8328" or "everest,es8388"
+  - compatible  : Should be one of the following:
+	- "everest,es8323"
+	- "everest,es8328"
+	- "everest,es8388"
   - DVDD-supply : Regulator providing digital core supply voltage 1.8 - 3.6V
   - AVDD-supply : Regulator providing analog supply voltage 3.3V
   - PVDD-supply : Regulator providing digital IO supply voltage 1.8 - 3.6V
diff --git a/sound/soc/codecs/es8328-i2c.c b/sound/soc/codecs/es8328-i2c.c
index 318ab28..be3f03c 100644
--- a/sound/soc/codecs/es8328-i2c.c
+++ b/sound/soc/codecs/es8328-i2c.c
@@ -19,6 +19,7 @@
 #include "es8328.h"
 
 static const struct i2c_device_id es8328_id[] = {
+	{ "es8323", 0 },
 	{ "es8328", 0 },
 	{ "es8388", 0 },
 	{ }
@@ -26,6 +27,7 @@ static const struct i2c_device_id es8328_id[] = {
 MODULE_DEVICE_TABLE(i2c, es8328_id);
 
 static const struct of_device_id es8328_of_match[] = {
+	{ .compatible = "everest,es8323", },
 	{ .compatible = "everest,es8328", },
 	{ .compatible = "everest,es8388", },
 	{ }
-- 
2.9.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [PATCH 2/2] arm: dts: Add support for ES8323 to the Firefly-RK3288
  2017-01-17  9:12 [PATCH 0/2] Add support for es8323 on the firefly-rk3288 Romain Perier
  2017-01-17  9:12 ` [PATCH 1/2] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
@ 2017-01-17  9:12 ` Romain Perier
  1 sibling, 0 replies; 3+ messages in thread
From: Romain Perier @ 2017-01-17  9:12 UTC (permalink / raw)
  To: Heiko Stuebner, devicetree, Rob Herring, Ian Campbell,
	Pawel Moll, Mark Rutland, Kumar Gala, Jaroslav Kysela,
	Takashi Iwai, alsa-devel
  Cc: Romain Perier, linux-rockchip, Sjoerd Simons, linux-arm-kernel

This commit adds the DT definition of the es8388 i2c device found at
address 0x10. It also adds the definition for connecting the Rockchip
I2S to the es8388 analog output.

Signed-off-by: Romain Perier <romain.perier@collabora.com>
---
 arch/arm/boot/dts/rk3288-firefly.dtsi | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/arch/arm/boot/dts/rk3288-firefly.dtsi b/arch/arm/boot/dts/rk3288-firefly.dtsi
index 44935af..bbe2d67 100644
--- a/arch/arm/boot/dts/rk3288-firefly.dtsi
+++ b/arch/arm/boot/dts/rk3288-firefly.dtsi
@@ -103,6 +103,16 @@
 		};
 	};
 
+	sound_es8323 {
+		compatible = "rockchip,rockchip-audio-es8388";
+		rockchip,model = "Analog audio output";
+		rockchip,i2s-controller = <&i2s>;
+		rockchip,audio-codec = <&es8323>;
+		/* tsadc and headphone use the same pins */
+		rockchip,hp-en-gpios = <&gpio0 RK_PB2 GPIO_ACTIVE_HIGH>;
+		rockchip,hp-det-gpios = <&gpio7 RK_PB7 GPIO_ACTIVE_HIGH>;
+	};
+
 	vbat_wl: vcc_sys: vsys-regulator {
 		compatible = "regulator-fixed";
 		regulator-name = "vcc_sys";
@@ -371,6 +381,17 @@
 
 &i2c2 {
 	status = "okay";
+
+	es8323: es8323@10 {
+		compatible = "everest,es8323", "everest,es8328";
+		reg = <0x10>;
+		AVDD-supply = <&vcca_33>;
+		DVDD-supply = <&vcca_33>;
+		HPVDD-supply = <&vcca_33>;
+		PVDD-supply = <&vcca_33>;
+		clocks = <&cru SCLK_I2S0_OUT>;
+		clock-names = "i2s_clk_out";
+	};
 };
 
 &i2c4 {
@@ -381,6 +402,10 @@
 	status = "okay";
 };
 
+&i2s {
+	status = "okay";
+};
+
 &io_domains {
 	status = "okay";
 
-- 
2.9.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-01-17  9:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-17  9:12 [PATCH 0/2] Add support for es8323 on the firefly-rk3288 Romain Perier
2017-01-17  9:12 ` [PATCH 1/2] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
2017-01-17  9:12 ` [PATCH 2/2] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.