diff mbox series

[v9,2/5] dt-bindings: display: mediatek: control dpi pins mode to avoid leakage

Message ID 20200226053238.31646-3-jitao.shi@mediatek.com
State Changes Requested, archived
Headers show
Series mt8183 dpi supports dual edge and pin mode swap | expand

Checks

Context Check Description
robh/checkpatch warning "total: 0 errors, 1 warnings, 19 lines checked"

Commit Message

Jitao Shi Feb. 26, 2020, 5:32 a.m. UTC
Add property "pinctrl-names" to swap pin mode between gpio and dpi mode. Set
pin mode to gpio oupput-low to avoid leakage current when dpi disable.

Reviewed-by: CK Hu <ck.hu@mediatek.com>
Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
---
 .../devicetree/bindings/display/mediatek/mediatek,dpi.txt  | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

Rob Herring Feb. 27, 2020, 5:18 p.m. UTC | #1
On Wed, Feb 26, 2020 at 01:32:35PM +0800, Jitao Shi wrote:
> Add property "pinctrl-names" to swap pin mode between gpio and dpi mode. Set
> pin mode to gpio oupput-low to avoid leakage current when dpi disable.

s/oupput/output/

> Reviewed-by: CK Hu <ck.hu@mediatek.com>
> Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
> ---
>  .../devicetree/bindings/display/mediatek/mediatek,dpi.txt  | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt b/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt
> index 58914cf681b8..a7b1b8bfb65e 100644
> --- a/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt
> +++ b/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt
> @@ -17,6 +17,10 @@ Required properties:
>    Documentation/devicetree/bindings/graph.txt. This port should be connected
>    to the input port of an attached HDMI or LVDS encoder chip.
>  
> +Optional properties:
> +- pinctrl-names: Contain "gpiomode" and "dpimode".
> +  pinctrl-names see Documentation/devicetree/bindings/pinctrlpinctrl-bindings.txt
> +
>  Example:
>  
>  dpi0: dpi@1401d000 {
> @@ -27,6 +31,9 @@ dpi0: dpi@1401d000 {
>  		 <&mmsys CLK_MM_DPI_ENGINE>,
>  		 <&apmixedsys CLK_APMIXED_TVDPLL>;
>  	clock-names = "pixel", "engine", "pll";
> +	pinctrl-names = "gpiomode", "dpimode";

The somewhat standard way to do this is '"default", "sleep"' if I 
remember the names right. And the normal operating mode is usually 
first.

> +	pinctrl-0 = <&dpi_pin_gpio>;
> +	pinctrl-1 = <&dpi_pin_func>;
>  
>  	port {
>  		dpi0_out: endpoint {
> -- 
> 2.21.0
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt b/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt
index 58914cf681b8..a7b1b8bfb65e 100644
--- a/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt
+++ b/Documentation/devicetree/bindings/display/mediatek/mediatek,dpi.txt
@@ -17,6 +17,10 @@  Required properties:
   Documentation/devicetree/bindings/graph.txt. This port should be connected
   to the input port of an attached HDMI or LVDS encoder chip.
 
+Optional properties:
+- pinctrl-names: Contain "gpiomode" and "dpimode".
+  pinctrl-names see Documentation/devicetree/bindings/pinctrlpinctrl-bindings.txt
+
 Example:
 
 dpi0: dpi@1401d000 {
@@ -27,6 +31,9 @@  dpi0: dpi@1401d000 {
 		 <&mmsys CLK_MM_DPI_ENGINE>,
 		 <&apmixedsys CLK_APMIXED_TVDPLL>;
 	clock-names = "pixel", "engine", "pll";
+	pinctrl-names = "gpiomode", "dpimode";
+	pinctrl-0 = <&dpi_pin_gpio>;
+	pinctrl-1 = <&dpi_pin_func>;
 
 	port {
 		dpi0_out: endpoint {