linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: dts: exynos: add flash support to galaxy-s3 boards
@ 2019-06-14 15:54 Denis 'GNUtoo' Carikli
  2019-06-14 16:03 ` Paul Kocialkowski
  2019-06-15 17:04 ` Krzysztof Kozlowski
  0 siblings, 2 replies; 5+ messages in thread
From: Denis 'GNUtoo' Carikli @ 2019-06-14 15:54 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski, Paul Kocialkowski
  Cc: Simon Shields, linux-samsung-soc, Denis 'GNUtoo' Carikli,
	linux-arm-kernel

From: Simon Shields <simon@lineageos.org>

The galaxy s3 boards use an aat1290 to control the flash LED.
This patch adds the relevant device tree configuration to use it.

Signed-off-by: Simon Shields <simon@lineageos.org>
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> [rebase]
---
 arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi | 32 +++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
index 30eee5942eff..375aeca09882 100644
--- a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
+++ b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
@@ -15,6 +15,24 @@
 		i2c10 = &i2c_cm36651;
 	};
 
+	aat1290 {
+		compatible = "skyworks,aat1290";
+		flen-gpios = <&gpj1 1 GPIO_ACTIVE_HIGH>;
+		enset-gpios = <&gpj1 2 GPIO_ACTIVE_HIGH>;
+
+		pinctrl-names = "default", "host", "isp";
+		pinctrl-0 = <&camera_flash_host>;
+		pinctrl-1 = <&camera_flash_host>;
+		pinctrl-2 = <&camera_flash_isp>;
+
+		flash-led {
+			label = "flash";
+			led-max-microamp = <520833>;
+			flash-max-microamp = <1012500>;
+			flash-max-timeout-us = <1940000>;
+		};
+	};
+
 	lcd_vdd3_reg: voltage-regulator-6 {
 		compatible = "regulator-fixed";
 		regulator-name = "LCD_VDD_2.2V";
@@ -131,6 +149,20 @@
 	regulator-max-microvolt = <2800000>;
 };
 
+&pinctrl_0 {
+	camera_flash_host: camera-flash-host {
+		samsung,pins = "gpj1-0";
+		samsung,pin-function = <1>;
+		samsung,pin-val = <0>;
+	};
+
+	camera_flash_isp: camera-flash-isp {
+		samsung,pins = "gpj1-0";
+		samsung,pin-function = <1>;
+		samsung,pin-val = <1>;
+	};
+};
+
 &s5c73m3 {
 	standby-gpios = <&gpm0 1 GPIO_ACTIVE_LOW>;   /* ISP_STANDBY */
 	vdda-supply = <&ldo17_reg>;
-- 
2.21.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH] ARM: dts: exynos: add flash support to galaxy-s3 boards
  2019-06-14 15:54 [PATCH] ARM: dts: exynos: add flash support to galaxy-s3 boards Denis 'GNUtoo' Carikli
@ 2019-06-14 16:03 ` Paul Kocialkowski
  2019-06-15 17:04 ` Krzysztof Kozlowski
  1 sibling, 0 replies; 5+ messages in thread
From: Paul Kocialkowski @ 2019-06-14 16:03 UTC (permalink / raw)
  To: Denis 'GNUtoo' Carikli, Kukjin Kim, Krzysztof Kozlowski
  Cc: Simon Shields, linux-samsung-soc, linux-arm-kernel

Hi,

Le vendredi 14 juin 2019 à 17:54 +0200, Denis 'GNUtoo' Carikli a
écrit :
> From: Simon Shields <simon@lineageos.org>
> 
> The galaxy s3 boards use an aat1290 to control the flash LED.
> This patch adds the relevant device tree configuration to use it.

Looks good to me:
Reviewed-by: Paul Kocialkowski <paul.kocialkowski@bootlin.com>

Cheers,

Paul

> Signed-off-by: Simon Shields <simon@lineageos.org>
> Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> [rebase]
> ---
>  arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi | 32 +++++++++++++++++++++
>  1 file changed, 32 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
> index 30eee5942eff..375aeca09882 100644
> --- a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
> +++ b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
> @@ -15,6 +15,24 @@
>  		i2c10 = &i2c_cm36651;
>  	};
>  
> +	aat1290 {
> +		compatible = "skyworks,aat1290";
> +		flen-gpios = <&gpj1 1 GPIO_ACTIVE_HIGH>;
> +		enset-gpios = <&gpj1 2 GPIO_ACTIVE_HIGH>;
> +
> +		pinctrl-names = "default", "host", "isp";
> +		pinctrl-0 = <&camera_flash_host>;
> +		pinctrl-1 = <&camera_flash_host>;
> +		pinctrl-2 = <&camera_flash_isp>;
> +
> +		flash-led {
> +			label = "flash";
> +			led-max-microamp = <520833>;
> +			flash-max-microamp = <1012500>;
> +			flash-max-timeout-us = <1940000>;
> +		};
> +	};
> +
>  	lcd_vdd3_reg: voltage-regulator-6 {
>  		compatible = "regulator-fixed";
>  		regulator-name = "LCD_VDD_2.2V";
> @@ -131,6 +149,20 @@
>  	regulator-max-microvolt = <2800000>;
>  };
>  
> +&pinctrl_0 {
> +	camera_flash_host: camera-flash-host {
> +		samsung,pins = "gpj1-0";
> +		samsung,pin-function = <1>;
> +		samsung,pin-val = <0>;
> +	};
> +
> +	camera_flash_isp: camera-flash-isp {
> +		samsung,pins = "gpj1-0";
> +		samsung,pin-function = <1>;
> +		samsung,pin-val = <1>;
> +	};
> +};
> +
>  &s5c73m3 {
>  	standby-gpios = <&gpm0 1 GPIO_ACTIVE_LOW>;   /* ISP_STANDBY */
>  	vdda-supply = <&ldo17_reg>;


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH] ARM: dts: exynos: add flash support to galaxy-s3 boards
  2019-06-14 15:54 [PATCH] ARM: dts: exynos: add flash support to galaxy-s3 boards Denis 'GNUtoo' Carikli
  2019-06-14 16:03 ` Paul Kocialkowski
@ 2019-06-15 17:04 ` Krzysztof Kozlowski
  2019-06-18  0:17   ` [PATCH][v2] " Denis 'GNUtoo' Carikli
  1 sibling, 1 reply; 5+ messages in thread
From: Krzysztof Kozlowski @ 2019-06-15 17:04 UTC (permalink / raw)
  To: Denis 'GNUtoo' Carikli
  Cc: Paul Kocialkowski, linux-samsung-soc, Kukjin Kim, Simon Shields,
	linux-arm-kernel

On Fri, Jun 14, 2019 at 05:54:19PM +0200, Denis 'GNUtoo' Carikli wrote:
> From: Simon Shields <simon@lineageos.org>
> 
> The galaxy s3 boards use an aat1290 to control the flash LED.
> This patch adds the relevant device tree configuration to use it.
> 
> Signed-off-by: Simon Shields <simon@lineageos.org>
> Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> [rebase]
> ---
>  arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi | 32 +++++++++++++++++++++
>  1 file changed, 32 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
> index 30eee5942eff..375aeca09882 100644
> --- a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
> +++ b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
> @@ -15,6 +15,24 @@
>  		i2c10 = &i2c_cm36651;
>  	};
>  
> +	aat1290 {
> +		compatible = "skyworks,aat1290";
> +		flen-gpios = <&gpj1 1 GPIO_ACTIVE_HIGH>;
> +		enset-gpios = <&gpj1 2 GPIO_ACTIVE_HIGH>;
> +
> +		pinctrl-names = "default", "host", "isp";
> +		pinctrl-0 = <&camera_flash_host>;
> +		pinctrl-1 = <&camera_flash_host>;
> +		pinctrl-2 = <&camera_flash_isp>;
> +
> +		flash-led {
> +			label = "flash";
> +			led-max-microamp = <520833>;
> +			flash-max-microamp = <1012500>;
> +			flash-max-timeout-us = <1940000>;
> +		};
> +	};
> +
>  	lcd_vdd3_reg: voltage-regulator-6 {
>  		compatible = "regulator-fixed";
>  		regulator-name = "LCD_VDD_2.2V";
> @@ -131,6 +149,20 @@
>  	regulator-max-microvolt = <2800000>;
>  };
>  
> +&pinctrl_0 {
> +	camera_flash_host: camera-flash-host {
> +		samsung,pins = "gpj1-0";
> +		samsung,pin-function = <1>;
> +		samsung,pin-val = <0>;

Please use the pin macros from:
include/dt-bindings/pinctrl/samsung.h

Best regards,
Krzysztof


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH][v2] ARM: dts: exynos: add flash support to galaxy-s3 boards
  2019-06-15 17:04 ` Krzysztof Kozlowski
@ 2019-06-18  0:17   ` Denis 'GNUtoo' Carikli
  2019-06-19 17:19     ` Krzysztof Kozlowski
  0 siblings, 1 reply; 5+ messages in thread
From: Denis 'GNUtoo' Carikli @ 2019-06-18  0:17 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Simon Shields, linux-samsung-soc, Paul Kocialkowski, Kukjin Kim,
	Denis 'GNUtoo' Carikli, linux-arm-kernel

From: Simon Shields <simon@lineageos.org>

The galaxy s3 boards use an aat1290 to control the flash LED.
This patch adds the relevant device tree configuration to use it.

Signed-off-by: Simon Shields <simon@lineageos.org>
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> [rebase]
---
 arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi | 32 +++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
index 30eee5942eff..ce87d2ff27aa 100644
--- a/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
+++ b/arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi
@@ -15,6 +15,24 @@
 		i2c10 = &i2c_cm36651;
 	};
 
+	aat1290 {
+		compatible = "skyworks,aat1290";
+		flen-gpios = <&gpj1 1 GPIO_ACTIVE_HIGH>;
+		enset-gpios = <&gpj1 2 GPIO_ACTIVE_HIGH>;
+
+		pinctrl-names = "default", "host", "isp";
+		pinctrl-0 = <&camera_flash_host>;
+		pinctrl-1 = <&camera_flash_host>;
+		pinctrl-2 = <&camera_flash_isp>;
+
+		flash-led {
+			label = "flash";
+			led-max-microamp = <520833>;
+			flash-max-microamp = <1012500>;
+			flash-max-timeout-us = <1940000>;
+		};
+	};
+
 	lcd_vdd3_reg: voltage-regulator-6 {
 		compatible = "regulator-fixed";
 		regulator-name = "LCD_VDD_2.2V";
@@ -131,6 +149,20 @@
 	regulator-max-microvolt = <2800000>;
 };
 
+&pinctrl_0 {
+	camera_flash_host: camera-flash-host {
+		samsung,pins = "gpj1-0";
+		samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>;
+		samsung,pin-val = <0>;
+	};
+
+	camera_flash_isp: camera-flash-isp {
+		samsung,pins = "gpj1-0";
+		samsung,pin-function = <EXYNOS_PIN_FUNC_OUTPUT>;
+		samsung,pin-val = <1>;
+	};
+};
+
 &s5c73m3 {
 	standby-gpios = <&gpm0 1 GPIO_ACTIVE_LOW>;   /* ISP_STANDBY */
 	vdda-supply = <&ldo17_reg>;
-- 
2.21.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH][v2] ARM: dts: exynos: add flash support to galaxy-s3 boards
  2019-06-18  0:17   ` [PATCH][v2] " Denis 'GNUtoo' Carikli
@ 2019-06-19 17:19     ` Krzysztof Kozlowski
  0 siblings, 0 replies; 5+ messages in thread
From: Krzysztof Kozlowski @ 2019-06-19 17:19 UTC (permalink / raw)
  To: Denis 'GNUtoo' Carikli
  Cc: Paul Kocialkowski, linux-samsung-soc, Kukjin Kim, Simon Shields,
	linux-arm-kernel

On Tue, Jun 18, 2019 at 02:17:42AM +0200, Denis 'GNUtoo' Carikli wrote:
> From: Simon Shields <simon@lineageos.org>
> 
> The galaxy s3 boards use an aat1290 to control the flash LED.
> This patch adds the relevant device tree configuration to use it.
> 
> Signed-off-by: Simon Shields <simon@lineageos.org>
> Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> [rebase]
> ---
>  arch/arm/boot/dts/exynos4412-galaxy-s3.dtsi | 32 +++++++++++++++++++++
>  1 file changed, 32 insertions(+)

Thanks, applied.

Best regards,
Krzysztof


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2019-06-19 17:19 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-14 15:54 [PATCH] ARM: dts: exynos: add flash support to galaxy-s3 boards Denis 'GNUtoo' Carikli
2019-06-14 16:03 ` Paul Kocialkowski
2019-06-15 17:04 ` Krzysztof Kozlowski
2019-06-18  0:17   ` [PATCH][v2] " Denis 'GNUtoo' Carikli
2019-06-19 17:19     ` Krzysztof Kozlowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).