diff mbox series

[v4,13/13,HACK] dt-bindings: display: bridge: lvds-codec: Absorb thine,thc63lvdm83d.txt

Message ID 1573660292-10629-14-git-send-email-fabrizio.castro@bp.renesas.com
State Not Applicable, archived
Headers show
Series Add LCD panel support to iwg20d | expand

Checks

Context Check Description
robh/checkpatch warning "total: 0 errors, 1 warnings, 17 lines checked"
robh/dt-meta-schema success

Commit Message

Fabrizio Castro Nov. 13, 2019, 3:51 p.m. UTC
At this point in time, compatible string "thine,thc63lvdm83d" is
backed by the lvds-codec driver, and the documentation contained
in thine,thc63lvdm83d.txt is basically the same as the one
contained in lvds-codec.yaml (generic fallback compatible string
aside), therefore absorb thine,thc63lvdm83d.txt.

Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>

---
Hi Laurent,

what do you think about this patch?

Thanks,
Fab

v3->v4:
* New patch
---
 .../bindings/display/bridge/lvds-codec.yaml        |  5 +--
 .../bindings/display/bridge/thine,thc63lvdm83d.txt | 50 ----------------------
 2 files changed, 2 insertions(+), 53 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt

Comments

Rob Herring Nov. 18, 2019, 9:51 p.m. UTC | #1
On Wed, Nov 13, 2019 at 03:51:32PM +0000, Fabrizio Castro wrote:
> At this point in time, compatible string "thine,thc63lvdm83d" is
> backed by the lvds-codec driver, and the documentation contained
> in thine,thc63lvdm83d.txt is basically the same as the one
> contained in lvds-codec.yaml (generic fallback compatible string
> aside), therefore absorb thine,thc63lvdm83d.txt.
> 
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> 
> ---
> Hi Laurent,
> 
> what do you think about this patch?
> 
> Thanks,
> Fab
> 
> v3->v4:
> * New patch
> ---
>  .../bindings/display/bridge/lvds-codec.yaml        |  5 +--
>  .../bindings/display/bridge/thine,thc63lvdm83d.txt | 50 ----------------------
>  2 files changed, 2 insertions(+), 53 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt
> 
> diff --git a/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml b/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
> index 21f8c6e..420bfce 100644
> --- a/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
> +++ b/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
> @@ -30,9 +30,6 @@ description: |
>  
>  properties:
>    compatible:
> -    description: |
> -      Must list the device specific compatible string first, followed by the
> -      generic compatible string.

Probably better to just omit this from the start. 

In any case:

Reviewed-by: Rob Herring <robh@kernel.org>
Laurent Pinchart Nov. 19, 2019, 12:19 a.m. UTC | #2
Hi Fabrizio,

Thank you for the patch.

On Wed, Nov 13, 2019 at 03:51:32PM +0000, Fabrizio Castro wrote:
> At this point in time, compatible string "thine,thc63lvdm83d" is
> backed by the lvds-codec driver, and the documentation contained
> in thine,thc63lvdm83d.txt is basically the same as the one
> contained in lvds-codec.yaml (generic fallback compatible string
> aside), therefore absorb thine,thc63lvdm83d.txt.
> 
> Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com>
> 
> ---
> Hi Laurent,
> 
> what do you think about this patch?

I think it's good :-)

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

It however doesn't address my concern that resulted in patch 12/13. A
DTB could still contain only lvds-encoder or lvds-decoder, even if the
DT bindings forbid it. Adding a check in the driver would enforce the
use of a device-specific compatible string. It adds quite a bit of
complexity though :-S

> v3->v4:
> * New patch
> ---
>  .../bindings/display/bridge/lvds-codec.yaml        |  5 +--
>  .../bindings/display/bridge/thine,thc63lvdm83d.txt | 50 ----------------------
>  2 files changed, 2 insertions(+), 53 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt
> 
> diff --git a/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml b/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
> index 21f8c6e..420bfce 100644
> --- a/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
> +++ b/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
> @@ -30,9 +30,6 @@ description: |
>  
>  properties:
>    compatible:
> -    description: |
> -      Must list the device specific compatible string first, followed by the
> -      generic compatible string.
>      oneOf:
>        - items:
>          - enum:
> @@ -44,6 +41,8 @@ properties:
>          - enum:
>            - ti,ds90cf384a     # For the DS90CF384A FPD-Link LVDS Receiver
>          - const: lvds-decoder # Generic LVDS decoders compatible fallback
> +      - enum:
> +        - thine,thc63lvdm83d  # For the THC63LVDM83D LVDS serializer
>  
>    ports:
>      type: object
> diff --git a/Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt b/Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt
> deleted file mode 100644
> index fee3c88..0000000
> --- a/Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt
> +++ /dev/null
> @@ -1,50 +0,0 @@
> -THine Electronics THC63LVDM83D LVDS serializer
> -----------------------------------------------
> -
> -The THC63LVDM83D is an LVDS serializer designed to support pixel data
> -transmission between a host and a flat panel.
> -
> -Required properties:
> -
> -- compatible: Should be "thine,thc63lvdm83d"
> -
> -Optional properties:
> -
> -- powerdown-gpios: Power down control GPIO (the /PWDN pin, active low).
> -
> -Required nodes:
> -
> -The THC63LVDM83D has two video ports. Their connections are modeled using the
> -OFgraph bindings specified in Documentation/devicetree/bindings/graph.txt.
> -
> -- Video port 0 for CMOS/TTL input
> -- Video port 1 for LVDS output
> -
> -
> -Example
> --------
> -
> -	lvds_enc: encoder@0 {
> -		compatible = "thine,thc63lvdm83d";
> -
> -		ports {
> -			#address-cells = <1>;
> -			#size-cells = <0>;
> -
> -			port@0 {
> -				reg = <0>;
> -
> -				lvds_enc_in: endpoint@0 {
> -					remote-endpoint = <&rgb_out>;
> -				};
> -			};
> -
> -			port@1 {
> -				reg = <1>;
> -
> -				lvds_enc_out: endpoint@0 {
> -					remote-endpoint = <&panel_in>;
> -				};
> -			};
> -		};
> -	};
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml b/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
index 21f8c6e..420bfce 100644
--- a/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
+++ b/Documentation/devicetree/bindings/display/bridge/lvds-codec.yaml
@@ -30,9 +30,6 @@  description: |
 
 properties:
   compatible:
-    description: |
-      Must list the device specific compatible string first, followed by the
-      generic compatible string.
     oneOf:
       - items:
         - enum:
@@ -44,6 +41,8 @@  properties:
         - enum:
           - ti,ds90cf384a     # For the DS90CF384A FPD-Link LVDS Receiver
         - const: lvds-decoder # Generic LVDS decoders compatible fallback
+      - enum:
+        - thine,thc63lvdm83d  # For the THC63LVDM83D LVDS serializer
 
   ports:
     type: object
diff --git a/Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt b/Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt
deleted file mode 100644
index fee3c88..0000000
--- a/Documentation/devicetree/bindings/display/bridge/thine,thc63lvdm83d.txt
+++ /dev/null
@@ -1,50 +0,0 @@ 
-THine Electronics THC63LVDM83D LVDS serializer
-----------------------------------------------
-
-The THC63LVDM83D is an LVDS serializer designed to support pixel data
-transmission between a host and a flat panel.
-
-Required properties:
-
-- compatible: Should be "thine,thc63lvdm83d"
-
-Optional properties:
-
-- powerdown-gpios: Power down control GPIO (the /PWDN pin, active low).
-
-Required nodes:
-
-The THC63LVDM83D has two video ports. Their connections are modeled using the
-OFgraph bindings specified in Documentation/devicetree/bindings/graph.txt.
-
-- Video port 0 for CMOS/TTL input
-- Video port 1 for LVDS output
-
-
-Example
--------
-
-	lvds_enc: encoder@0 {
-		compatible = "thine,thc63lvdm83d";
-
-		ports {
-			#address-cells = <1>;
-			#size-cells = <0>;
-
-			port@0 {
-				reg = <0>;
-
-				lvds_enc_in: endpoint@0 {
-					remote-endpoint = <&rgb_out>;
-				};
-			};
-
-			port@1 {
-				reg = <1>;
-
-				lvds_enc_out: endpoint@0 {
-					remote-endpoint = <&panel_in>;
-				};
-			};
-		};
-	};