* [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi Romain Perier
` (9 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
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 33fbf058c997..86b6d6e99732 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 318ab28c5351..be3f03c35137 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.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
2017-07-26 13:55 ` [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
` (8 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
The tsadc supports two reset methods: the cru and the otp_gpio. All
boards except veyron and the evb simply use the cru-method and reuse the
pin for something else. On the Firefly-RK3288 this is for example the
case with the headphone. To prevent pinctrl-conflicts with these don't
set the otp-gpio pinctrl by default but only in the boards using it.
Signed-off-by: Romain Perier <romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
arch/arm/boot/dts/rk3288-evb.dtsi | 4 ++++
arch/arm/boot/dts/rk3288-veyron.dtsi | 4 ++++
arch/arm/boot/dts/rk3288.dtsi | 4 ----
3 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/arch/arm/boot/dts/rk3288-evb.dtsi b/arch/arm/boot/dts/rk3288-evb.dtsi
index 0dec94c3583b..28a69334b2d1 100644
--- a/arch/arm/boot/dts/rk3288-evb.dtsi
+++ b/arch/arm/boot/dts/rk3288-evb.dtsi
@@ -290,6 +290,10 @@
};
&tsadc {
+ pinctrl-names = "init", "default", "sleep";
+ pinctrl-0 = <&otp_gpio>;
+ pinctrl-1 = <&otp_out>;
+ pinctrl-2 = <&otp_gpio>;
rockchip,hw-tshut-mode = <0>; /* tshut mode 0:CRU 1:GPIO */
rockchip,hw-tshut-polarity = <0>; /* tshut polarity 0:LOW 1:HIGH */
status = "okay";
diff --git a/arch/arm/boot/dts/rk3288-veyron.dtsi b/arch/arm/boot/dts/rk3288-veyron.dtsi
index d709fa1847f9..697c9a78cb7e 100644
--- a/arch/arm/boot/dts/rk3288-veyron.dtsi
+++ b/arch/arm/boot/dts/rk3288-veyron.dtsi
@@ -398,6 +398,10 @@
&tsadc {
status = "okay";
+ pinctrl-names = "init", "default", "sleep";
+ pinctrl-0 = <&otp_gpio>;
+ pinctrl-1 = <&otp_out>;
+ pinctrl-2 = <&otp_gpio>;
rockchip,hw-tshut-mode = <1>; /* tshut mode 0:CRU 1:GPIO */
rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */
};
diff --git a/arch/arm/boot/dts/rk3288.dtsi b/arch/arm/boot/dts/rk3288.dtsi
index 2484f11761ea..3a752c0cbc73 100644
--- a/arch/arm/boot/dts/rk3288.dtsi
+++ b/arch/arm/boot/dts/rk3288.dtsi
@@ -541,10 +541,6 @@
clock-names = "tsadc", "apb_pclk";
resets = <&cru SRST_TSADC>;
reset-names = "tsadc-apb";
- pinctrl-names = "init", "default", "sleep";
- pinctrl-0 = <&otp_gpio>;
- pinctrl-1 = <&otp_out>;
- pinctrl-2 = <&otp_gpio>;
#thermal-sensor-cells = <1>;
rockchip,hw-tshut-temp = <95000>;
status = "disabled";
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
2017-07-26 13:55 ` [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 0/3] Add support for es8323 and hdmi audio to the firefly-rk3288 Romain Perier
` (7 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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 es8323 analog output.
Signed-off-by: Romain Perier <romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
arch/arm/boot/dts/rk3288-firefly.dtsi | 38 +++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)
diff --git a/arch/arm/boot/dts/rk3288-firefly.dtsi b/arch/arm/boot/dts/rk3288-firefly.dtsi
index 32dabae12e67..24e3fe77bc42 100644
--- a/arch/arm/boot/dts/rk3288-firefly.dtsi
+++ b/arch/arm/boot/dts/rk3288-firefly.dtsi
@@ -116,6 +116,19 @@
};
};
+ sound-i2s {
+ compatible = "rockchip,rk3288-hdmi-analog";
+ pinctrl-names = "default";
+ pinctrl-0 = <&phone_ctl>, <&hp_det>;
+ rockchip,audio-codec = <&es8323>;
+ rockchip,hp-det-gpios = <&gpio7 15 GPIO_ACTIVE_HIGH>;
+ rockchip,hp-en-gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ rockchip,i2s-controller = <&i2s>;
+ rockchip,model = "I2S";
+ rockchip,routing = "Analog", "LOUT2",
+ "Analog", "ROUT2";
+ };
+
vbat_wl: vcc_sys: vsys-regulator {
compatible = "regulator-fixed";
regulator-name = "vcc_sys";
@@ -389,6 +402,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 {
@@ -399,6 +423,10 @@
status = "okay";
};
+&i2s {
+ status = "okay";
+};
+
&io_domains {
status = "okay";
@@ -501,6 +529,16 @@
};
};
+ headphone {
+ hp_det: hp-det {
+ rockchip,pins = <7 15 RK_FUNC_GPIO &pcfg_pull_none>;
+ };
+
+ phone_ctl: phone-ctl {
+ rockchip,pins = <0 10 RK_FUNC_GPIO &pcfg_pull_up>;
+ };
+ };
+
usb_host {
host_vbus_drv: host-vbus-drv {
rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>;
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 0/3] Add support for es8323 and hdmi audio to the firefly-rk3288
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (2 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
` (6 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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. As the support for HDMI audio is also
built-in in the corresponding ASoC machine driver, HDMI audio output is
also enabled.
Changes in v3:
- Synced DT with the one of the Rock2, the properties have been
lexically re-ordered in the right order, I have splitted the
headphone pinctrl in two: phone_ctl and hp_det
Changes in v2:
- Adapted DT for the firefly-rk3288 to the ASoC machine driver
rk3288-hdmi-analog
- Added patch 02/03 to this series
- Re-wrote this cover letter
Romain Perier (3):
SoC: es8328-i2c: Add compatible for ES8323
arm: dts: rockchip: Don't set otp-gpio pinctrl by default in
rk3288.dtsi
arm: dts: Add support for ES8323 to the Firefly-RK3288
Documentation/devicetree/bindings/sound/es8328.txt | 5 ++-
arch/arm/boot/dts/rk3288-evb.dtsi | 4 +++
arch/arm/boot/dts/rk3288-firefly.dtsi | 38 ++++++++++++++++++++++
arch/arm/boot/dts/rk3288-veyron.dtsi | 4 +++
arch/arm/boot/dts/rk3288.dtsi | 4 ---
sound/soc/codecs/es8328-i2c.c | 2 ++
6 files changed, 52 insertions(+), 5 deletions(-)
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 14+ messages in thread* [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (3 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 0/3] Add support for es8323 and hdmi audio to the firefly-rk3288 Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi Romain Perier
` (5 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
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 33fbf058c997..86b6d6e99732 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 318ab28c5351..be3f03c35137 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.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (4 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
` (4 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
The tsadc supports two reset methods: the cru and the otp_gpio. All
boards except veyron and the evb simply use the cru-method and reuse the
pin for something else. On the Firefly-RK3288 this is for example the
case with the headphone. To prevent pinctrl-conflicts with these don't
set the otp-gpio pinctrl by default but only in the boards using it.
Signed-off-by: Romain Perier <romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
arch/arm/boot/dts/rk3288-evb.dtsi | 4 ++++
arch/arm/boot/dts/rk3288-veyron.dtsi | 4 ++++
arch/arm/boot/dts/rk3288.dtsi | 4 ----
3 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/arch/arm/boot/dts/rk3288-evb.dtsi b/arch/arm/boot/dts/rk3288-evb.dtsi
index 0dec94c3583b..28a69334b2d1 100644
--- a/arch/arm/boot/dts/rk3288-evb.dtsi
+++ b/arch/arm/boot/dts/rk3288-evb.dtsi
@@ -290,6 +290,10 @@
};
&tsadc {
+ pinctrl-names = "init", "default", "sleep";
+ pinctrl-0 = <&otp_gpio>;
+ pinctrl-1 = <&otp_out>;
+ pinctrl-2 = <&otp_gpio>;
rockchip,hw-tshut-mode = <0>; /* tshut mode 0:CRU 1:GPIO */
rockchip,hw-tshut-polarity = <0>; /* tshut polarity 0:LOW 1:HIGH */
status = "okay";
diff --git a/arch/arm/boot/dts/rk3288-veyron.dtsi b/arch/arm/boot/dts/rk3288-veyron.dtsi
index d709fa1847f9..697c9a78cb7e 100644
--- a/arch/arm/boot/dts/rk3288-veyron.dtsi
+++ b/arch/arm/boot/dts/rk3288-veyron.dtsi
@@ -398,6 +398,10 @@
&tsadc {
status = "okay";
+ pinctrl-names = "init", "default", "sleep";
+ pinctrl-0 = <&otp_gpio>;
+ pinctrl-1 = <&otp_out>;
+ pinctrl-2 = <&otp_gpio>;
rockchip,hw-tshut-mode = <1>; /* tshut mode 0:CRU 1:GPIO */
rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */
};
diff --git a/arch/arm/boot/dts/rk3288.dtsi b/arch/arm/boot/dts/rk3288.dtsi
index 2484f11761ea..3a752c0cbc73 100644
--- a/arch/arm/boot/dts/rk3288.dtsi
+++ b/arch/arm/boot/dts/rk3288.dtsi
@@ -541,10 +541,6 @@
clock-names = "tsadc", "apb_pclk";
resets = <&cru SRST_TSADC>;
reset-names = "tsadc-apb";
- pinctrl-names = "init", "default", "sleep";
- pinctrl-0 = <&otp_gpio>;
- pinctrl-1 = <&otp_out>;
- pinctrl-2 = <&otp_gpio>;
#thermal-sensor-cells = <1>;
rockchip,hw-tshut-temp = <95000>;
status = "disabled";
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (5 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 0/3] Add support for es8323 and hdmi audio to the firefly-rk3288 Romain Perier
` (3 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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 es8323 analog output.
Signed-off-by: Romain Perier <romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
arch/arm/boot/dts/rk3288-firefly.dtsi | 38 +++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)
diff --git a/arch/arm/boot/dts/rk3288-firefly.dtsi b/arch/arm/boot/dts/rk3288-firefly.dtsi
index 32dabae12e67..24e3fe77bc42 100644
--- a/arch/arm/boot/dts/rk3288-firefly.dtsi
+++ b/arch/arm/boot/dts/rk3288-firefly.dtsi
@@ -116,6 +116,19 @@
};
};
+ sound-i2s {
+ compatible = "rockchip,rk3288-hdmi-analog";
+ pinctrl-names = "default";
+ pinctrl-0 = <&phone_ctl>, <&hp_det>;
+ rockchip,audio-codec = <&es8323>;
+ rockchip,hp-det-gpios = <&gpio7 15 GPIO_ACTIVE_HIGH>;
+ rockchip,hp-en-gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ rockchip,i2s-controller = <&i2s>;
+ rockchip,model = "I2S";
+ rockchip,routing = "Analog", "LOUT2",
+ "Analog", "ROUT2";
+ };
+
vbat_wl: vcc_sys: vsys-regulator {
compatible = "regulator-fixed";
regulator-name = "vcc_sys";
@@ -389,6 +402,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 {
@@ -399,6 +423,10 @@
status = "okay";
};
+&i2s {
+ status = "okay";
+};
+
&io_domains {
status = "okay";
@@ -501,6 +529,16 @@
};
};
+ headphone {
+ hp_det: hp-det {
+ rockchip,pins = <7 15 RK_FUNC_GPIO &pcfg_pull_none>;
+ };
+
+ phone_ctl: phone-ctl {
+ rockchip,pins = <0 10 RK_FUNC_GPIO &pcfg_pull_up>;
+ };
+ };
+
usb_host {
host_vbus_drv: host-vbus-drv {
rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>;
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 0/3] Add support for es8323 and hdmi audio to the firefly-rk3288
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (6 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
` (2 subsequent siblings)
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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. As the support for HDMI audio is also
built-in in the corresponding ASoC machine driver, HDMI audio output is
also enabled.
Changes in v3:
- Synced DT with the one of the Rock2, the properties have been
lexically re-ordered in the right order, I have splitted the
headphone pinctrl in two: phone_ctl and hp_det
Changes in v2:
- Adapted DT for the firefly-rk3288 to the ASoC machine driver
rk3288-hdmi-analog
- Added patch 02/03 to this series
- Re-wrote this cover letter
Romain Perier (3):
SoC: es8328-i2c: Add compatible for ES8323
arm: dts: rockchip: Don't set otp-gpio pinctrl by default in
rk3288.dtsi
arm: dts: Add support for ES8323 to the Firefly-RK3288
Documentation/devicetree/bindings/sound/es8328.txt | 5 ++-
arch/arm/boot/dts/rk3288-evb.dtsi | 4 +++
arch/arm/boot/dts/rk3288-firefly.dtsi | 38 ++++++++++++++++++++++
arch/arm/boot/dts/rk3288-veyron.dtsi | 4 +++
arch/arm/boot/dts/rk3288.dtsi | 4 ---
sound/soc/codecs/es8328-i2c.c | 2 ++
6 files changed, 52 insertions(+), 5 deletions(-)
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 14+ messages in thread* [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (7 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 0/3] Add support for es8323 and hdmi audio to the firefly-rk3288 Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
[not found] ` <20170726135526.475-10-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
2017-07-26 13:55 ` [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
10 siblings, 1 reply; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
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 33fbf058c997..86b6d6e99732 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 318ab28c5351..be3f03c35137 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.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (8 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 1/3] SoC: es8328-i2c: Add compatible for ES8323 Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
2017-07-26 13:55 ` [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288 Romain Perier
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
The tsadc supports two reset methods: the cru and the otp_gpio. All
boards except veyron and the evb simply use the cru-method and reuse the
pin for something else. On the Firefly-RK3288 this is for example the
case with the headphone. To prevent pinctrl-conflicts with these don't
set the otp-gpio pinctrl by default but only in the boards using it.
Signed-off-by: Romain Perier <romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
arch/arm/boot/dts/rk3288-evb.dtsi | 4 ++++
arch/arm/boot/dts/rk3288-veyron.dtsi | 4 ++++
arch/arm/boot/dts/rk3288.dtsi | 4 ----
3 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/arch/arm/boot/dts/rk3288-evb.dtsi b/arch/arm/boot/dts/rk3288-evb.dtsi
index 0dec94c3583b..28a69334b2d1 100644
--- a/arch/arm/boot/dts/rk3288-evb.dtsi
+++ b/arch/arm/boot/dts/rk3288-evb.dtsi
@@ -290,6 +290,10 @@
};
&tsadc {
+ pinctrl-names = "init", "default", "sleep";
+ pinctrl-0 = <&otp_gpio>;
+ pinctrl-1 = <&otp_out>;
+ pinctrl-2 = <&otp_gpio>;
rockchip,hw-tshut-mode = <0>; /* tshut mode 0:CRU 1:GPIO */
rockchip,hw-tshut-polarity = <0>; /* tshut polarity 0:LOW 1:HIGH */
status = "okay";
diff --git a/arch/arm/boot/dts/rk3288-veyron.dtsi b/arch/arm/boot/dts/rk3288-veyron.dtsi
index d709fa1847f9..697c9a78cb7e 100644
--- a/arch/arm/boot/dts/rk3288-veyron.dtsi
+++ b/arch/arm/boot/dts/rk3288-veyron.dtsi
@@ -398,6 +398,10 @@
&tsadc {
status = "okay";
+ pinctrl-names = "init", "default", "sleep";
+ pinctrl-0 = <&otp_gpio>;
+ pinctrl-1 = <&otp_out>;
+ pinctrl-2 = <&otp_gpio>;
rockchip,hw-tshut-mode = <1>; /* tshut mode 0:CRU 1:GPIO */
rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */
};
diff --git a/arch/arm/boot/dts/rk3288.dtsi b/arch/arm/boot/dts/rk3288.dtsi
index 2484f11761ea..3a752c0cbc73 100644
--- a/arch/arm/boot/dts/rk3288.dtsi
+++ b/arch/arm/boot/dts/rk3288.dtsi
@@ -541,10 +541,6 @@
clock-names = "tsadc", "apb_pclk";
resets = <&cru SRST_TSADC>;
reset-names = "tsadc-apb";
- pinctrl-names = "init", "default", "sleep";
- pinctrl-0 = <&otp_gpio>;
- pinctrl-1 = <&otp_out>;
- pinctrl-2 = <&otp_gpio>;
#thermal-sensor-cells = <1>;
rockchip,hw-tshut-temp = <95000>;
status = "disabled";
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH RESEND v3 3/3] arm: dts: Add support for ES8323 to the Firefly-RK3288
[not found] ` <20170726135526.475-1-romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
` (9 preceding siblings ...)
2017-07-26 13:55 ` [PATCH RESEND v3 2/3] arm: dts: rockchip: Don't set otp-gpio pinctrl by default in rk3288.dtsi Romain Perier
@ 2017-07-26 13:55 ` Romain Perier
10 siblings, 0 replies; 14+ messages in thread
From: Romain Perier @ 2017-07-26 13:55 UTC (permalink / raw)
To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, Heiko Stuebner
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Ian Campbell,
Pawel Moll, Mark Rutland, Kumar Gala,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Romain Perier
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 es8323 analog output.
Signed-off-by: Romain Perier <romain.perier-ZGY8ohtN/8qB+jHODAdFcQ@public.gmane.org>
---
arch/arm/boot/dts/rk3288-firefly.dtsi | 38 +++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)
diff --git a/arch/arm/boot/dts/rk3288-firefly.dtsi b/arch/arm/boot/dts/rk3288-firefly.dtsi
index 32dabae12e67..24e3fe77bc42 100644
--- a/arch/arm/boot/dts/rk3288-firefly.dtsi
+++ b/arch/arm/boot/dts/rk3288-firefly.dtsi
@@ -116,6 +116,19 @@
};
};
+ sound-i2s {
+ compatible = "rockchip,rk3288-hdmi-analog";
+ pinctrl-names = "default";
+ pinctrl-0 = <&phone_ctl>, <&hp_det>;
+ rockchip,audio-codec = <&es8323>;
+ rockchip,hp-det-gpios = <&gpio7 15 GPIO_ACTIVE_HIGH>;
+ rockchip,hp-en-gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>;
+ rockchip,i2s-controller = <&i2s>;
+ rockchip,model = "I2S";
+ rockchip,routing = "Analog", "LOUT2",
+ "Analog", "ROUT2";
+ };
+
vbat_wl: vcc_sys: vsys-regulator {
compatible = "regulator-fixed";
regulator-name = "vcc_sys";
@@ -389,6 +402,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 {
@@ -399,6 +423,10 @@
status = "okay";
};
+&i2s {
+ status = "okay";
+};
+
&io_domains {
status = "okay";
@@ -501,6 +529,16 @@
};
};
+ headphone {
+ hp_det: hp-det {
+ rockchip,pins = <7 15 RK_FUNC_GPIO &pcfg_pull_none>;
+ };
+
+ phone_ctl: phone-ctl {
+ rockchip,pins = <0 10 RK_FUNC_GPIO &pcfg_pull_up>;
+ };
+ };
+
usb_host {
host_vbus_drv: host-vbus-drv {
rockchip,pins = <0 14 RK_FUNC_GPIO &pcfg_pull_none>;
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 14+ messages in thread