Merge branch 'for-3.17/drivers' of git://git.kernel.dk/linux-block
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / media / rcar_vin.txt
1 Renesas RCar Video Input driver (rcar_vin)
2 ------------------------------------------
3
4 The rcar_vin device provides video input capabilities for the Renesas R-Car
5 family of devices. The current blocks are always slaves and suppot one input
6 channel which can be either RGB, YUYV or BT656.
7
8  - compatible: Must be one of the following
9    - "renesas,vin-r8a7791" for the R8A7791 device
10    - "renesas,vin-r8a7790" for the R8A7790 device
11    - "renesas,vin-r8a7779" for the R8A7779 device
12    - "renesas,vin-r8a7778" for the R8A7778 device
13  - reg: the register base and size for the device registers
14  - interrupts: the interrupt for the device
15  - clocks: Reference to the parent clock
16
17 Additionally, an alias named vinX will need to be created to specify
18 which video input device this is.
19
20 The per-board settings:
21  - port sub-node describing a single endpoint connected to the vin
22    as described in video-interfaces.txt[1]. Only the first one will
23    be considered as each vin interface has one input port.
24
25    These settings are used to work out video input format and widths
26    into the system.
27
28
29 Device node example
30 -------------------
31
32         aliases {
33                vin0 = &vin0;
34         };
35
36         vin0: vin@0xe6ef0000 {
37                 compatible = "renesas,vin-r8a7790";
38                 clocks = <&mstp8_clks R8A7790_CLK_VIN0>;
39                 reg = <0 0xe6ef0000 0 0x1000>;
40                 interrupts = <0 188 IRQ_TYPE_LEVEL_HIGH>;
41                 status = "disabled";
42         };
43
44 Board setup example (vin1 composite video input)
45 ------------------------------------------------
46
47 &i2c2   {
48         status = "ok";
49         pinctrl-0 = <&i2c2_pins>;
50         pinctrl-names = "default";
51
52         adv7180@20 {
53                 compatible = "adi,adv7180";
54                 reg = <0x20>;
55                 remote = <&vin1>;
56
57                 port {
58                         adv7180: endpoint {
59                                 bus-width = <8>;
60                                 remote-endpoint = <&vin1ep0>;
61                         };
62                 };
63         };
64 };
65
66 /* composite video input */
67 &vin1 {
68         pinctrl-0 = <&vin1_pins>;
69         pinctrl-names = "default";
70
71         status = "ok";
72
73         port {
74                 #address-cells = <1>;
75                 #size-cells = <0>;
76
77                 vin1ep0: endpoint {
78                         remote-endpoint = <&adv7180>;
79                         bus-width = <8>;
80                 };
81         };
82 };
83
84
85
86 [1] video-interfaces.txt common video media interface