Skip to content
Snippets Groups Projects
Commit 066a94e2 authored by Rob Herring's avatar Rob Herring Committed by Mauro Carvalho Chehab
Browse files

media: dt-bindings: media: Use graph and video-interfaces schemas


Now that we have graph and video-interfaces schemas, rework the media
related schemas to use them.

Cc: Jacopo Mondi <jacopo@jmondi.org>
Signed-off-by: default avatarRob Herring <robh@kernel.org>
Reviewed-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: default avatarMaxime Ripard <mripard@kernel.org>
Acked-by: default avatarSakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent 41f42b6e
No related branches found
No related tags found
No related merge requests found
......@@ -46,24 +46,19 @@ properties:
maxItems: 1
ports:
type: object
description:
A node containing input and output port nodes with endpoint definitions
as documented in
Documentation/devicetree/bindings/media/video-interfaces.txt
$ref: /schemas/graph.yaml#/properties/ports
properties:
port@0:
type: object
$ref: /schemas/graph.yaml#/$defs/port-base
unevaluatedProperties: false
description:
Input port node, single endpoint describing the CSI-2 transmitter.
properties:
reg:
const: 0
endpoint:
type: object
$ref: video-interfaces.yaml#
unevaluatedProperties: false
properties:
clock-lanes:
......@@ -72,50 +67,19 @@ properties:
data-lanes:
maxItems: 1
remote-endpoint: true
required:
- clock-lanes
- data-lanes
- remote-endpoint
additionalProperties: false
additionalProperties: false
port@1:
type: object
$ref: /schemas/graph.yaml#/properties/port
description:
Output port node, multiple endpoints describing all the R-Car VIN
modules connected the CSI-2 receiver.
properties:
'#address-cells':
const: 1
'#size-cells':
const: 0
reg:
const: 1
patternProperties:
"^endpoint@[0-9a-f]$":
type: object
properties:
reg:
maxItems: 1
remote-endpoint: true
required:
- reg
- remote-endpoint
additionalProperties: false
additionalProperties: false
- port@0
- port@1
required:
- compatible
......
......@@ -69,15 +69,15 @@ properties:
#The per-board settings for Gen2 and RZ/G1 platforms:
port:
type: object
$ref: /schemas/graph.yaml#/$defs/port-base
unevaluatedProperties: false
description:
A node containing a parallel input with a single endpoint definitions as
documented in
Documentation/devicetree/bindings/media/video-interfaces.txt
A node containing a parallel input
properties:
endpoint:
type: object
$ref: video-interfaces.yaml#
unevaluatedProperties: false
properties:
hsync-active:
......@@ -106,15 +106,6 @@ properties:
data-active: true
remote-endpoint: true
required:
- remote-endpoint
additionalProperties: false
additionalProperties: false
#The per-board settings for Gen3 and RZ/G2 platforms:
renesas,id:
description: VIN channel number
......@@ -123,23 +114,18 @@ properties:
maximum: 15
ports:
type: object
description:
A node containing input nodes with endpoint definitions as documented in
Documentation/devicetree/bindings/media/video-interfaces.txt
$ref: /schemas/graph.yaml#/properties/ports
properties:
port@0:
type: object
$ref: /schemas/graph.yaml#/properties/port
description:
Input port node, single endpoint describing a parallel input source.
properties:
reg:
const: 0
endpoint:
type: object
$ref: video-interfaces.yaml#
unevaluatedProperties: false
properties:
hsync-active:
......@@ -168,98 +154,29 @@ properties:
data-active: true
remote-endpoint: true
required:
- remote-endpoint
additionalProperties: false
required:
- endpoint
additionalProperties: false
port@1:
type: object
$ref: /schemas/graph.yaml#/properties/port
description:
Input port node, multiple endpoints describing all the R-Car CSI-2
modules connected the VIN.
properties:
'#address-cells':
const: 1
'#size-cells':
const: 0
reg:
const: 1
endpoint@0:
type: object
$ref: /schemas/graph.yaml#/properties/endpoint
description: Endpoint connected to CSI20.
properties:
reg:
const: 0
remote-endpoint: true
required:
- reg
- remote-endpoint
additionalProperties: false
endpoint@1:
type: object
$ref: /schemas/graph.yaml#/properties/endpoint
description: Endpoint connected to CSI21.
properties:
reg:
const: 1
remote-endpoint: true
required:
- reg
- remote-endpoint
additionalProperties: false
endpoint@2:
type: object
$ref: /schemas/graph.yaml#/properties/endpoint
description: Endpoint connected to CSI40.
properties:
reg:
const: 2
remote-endpoint: true
required:
- reg
- remote-endpoint
additionalProperties: false
endpoint@3:
type: object
$ref: /schemas/graph.yaml#/properties/endpoint
description: Endpoint connected to CSI41.
properties:
reg:
const: 3
remote-endpoint: true
required:
- reg
- remote-endpoint
additionalProperties: false
anyOf:
- required:
- endpoint@0
......@@ -270,8 +187,6 @@ properties:
- required:
- endpoint@3
additionalProperties: false
required:
- compatible
- reg
......
......@@ -56,56 +56,26 @@ properties:
power-domains:
maxItems: 1
# See ./video-interfaces.txt for details
ports:
type: object
additionalProperties: false
$ref: /schemas/graph.yaml#/properties/ports
properties:
"#address-cells":
const: 1
"#size-cells":
const: 0
port@0:
type: object
$ref: /schemas/graph.yaml#/$defs/port-base
unevaluatedProperties: false
description: connection point for sensors at MIPI-DPHY RX0
additionalProperties: false
properties:
"#address-cells":
const: 1
"#size-cells":
const: 0
reg:
const: 0
patternProperties:
endpoint:
type: object
additionalProperties: false
$ref: video-interfaces.yaml#
unevaluatedProperties: false
properties:
reg:
maxItems: 1
data-lanes:
minItems: 1
maxItems: 4
remote-endpoint: true
required:
- reg
- "#address-cells"
- "#size-cells"
required:
- "#address-cells"
- "#size-cells"
- port@0
required:
......
......@@ -37,16 +37,15 @@ properties:
maxItems: 1
port:
type: object
$ref: /schemas/graph.yaml#/$defs/port-base
unevaluatedProperties: false
description:
DCMI supports a single port node with parallel bus. It should contain
one 'port' child node with child 'endpoint' node. Please refer to the
bindings defined in
Documentation/devicetree/bindings/media/video-interfaces.txt.
DCMI supports a single port node with parallel bus.
properties:
endpoint:
type: object
$ref: video-interfaces.yaml#
unevaluatedProperties: false
properties:
bus-type:
......@@ -57,8 +56,6 @@ properties:
enum: [8, 10, 12, 14]
default: 8
remote-endpoint: true
allOf:
- if:
properties:
......@@ -73,14 +70,9 @@ properties:
enum: [8]
required:
- remote-endpoint
- bus-type
- pclk-sample
unevaluatedProperties: false
additionalProperties: false
required:
- compatible
- reg
......
......@@ -15,10 +15,7 @@ description: |-
processing capability to connect CSI2 image-sensor modules to the
DRA72x device.
CAL supports 2 camera port nodes on MIPI bus. Each CSI2 camera port nodes
should contain a 'port' child node with child 'endpoint' node. Please
refer to the bindings defined in
Documentation/devicetree/bindings/media/video-interfaces.txt.
CAL supports 2 camera port nodes on MIPI bus.
properties:
compatible:
......@@ -67,31 +64,19 @@ properties:
Documentation/devicetree/bindings/power/power_domain.txt
maxItems: 1
# See ./video-interfaces.txt for details
ports:
type: object
additionalProperties: false
$ref: /schemas/graph.yaml#/properties/ports
properties:
"#address-cells":
const: 1
"#size-cells":
const: 0
port@0:
type: object
additionalProperties: false
properties:
reg:
const: 0
$ref: /schemas/graph.yaml#/$defs/port-base
unevaluatedProperties: false
description: CSI2 Port #0
patternProperties:
properties:
endpoint:
type: object
additionalProperties: false
$ref: video-interfaces.yaml#
unevaluatedProperties: false
properties:
clock-lanes:
......@@ -101,24 +86,15 @@ properties:
minItems: 1
maxItems: 4
remote-endpoint: true
required:
- reg
port@1:
type: object
additionalProperties: false
properties:
reg:
const: 1
$ref: /schemas/graph.yaml#/$defs/port-base
unevaluatedProperties: false
description: CSI2 Port #1
patternProperties:
properties:
endpoint:
type: object
additionalProperties: false
$ref: video-interfaces.yaml#
unevaluatedProperties: false
properties:
clock-lanes:
......@@ -128,14 +104,7 @@ properties:
minItems: 1
maxItems: 4
remote-endpoint: true
required:
- reg
required:
- "#address-cells"
- "#size-cells"
- port@0
required:
......
......@@ -97,24 +97,21 @@ properties:
maxItems: 1
ports:
type: object
$ref: /schemas/graph.yaml#/properties/ports
properties:
port@0:
type: object
$ref: /schemas/graph.yaml#/$defs/port-base
description: |
Input / sink port node, single endpoint describing the
CSI-2 transmitter.
properties:
reg:
const: 0
endpoint:
type: object
$ref: /schemas/media/video-interfaces.yaml#
unevaluatedProperties: false
properties:
data-lanes:
description: |
This is required only in the sink port 0 endpoint which
......@@ -130,41 +127,17 @@ properties:
- const: 3
- const: 4
remote-endpoint: true
required:
- data-lanes
- remote-endpoint
additionalProperties: false
additionalProperties: false
unevaluatedProperties: false
port@1:
type: object
$ref: /schemas/graph.yaml#/properties/port
description: |
Output / source port node, endpoint describing modules
connected the CSI-2 receiver.
properties:
reg:
const: 1
endpoint:
type: object
properties:
remote-endpoint: true
required:
- remote-endpoint
additionalProperties: false
additionalProperties: false
required:
- compatible
- reg
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment