Merge branch 'master' into test
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / media / cec-gpio.txt
1 * HDMI CEC GPIO driver
2
3 The HDMI CEC GPIO module supports CEC implementations where the CEC line
4 is hooked up to a pull-up GPIO line and - optionally - the HPD line is
5 hooked up to another GPIO line.
6
7 Please note: the maximum voltage for the CEC line is 3.63V, for the HPD
8 line it is 5.3V. So you may need some sort of level conversion circuitry
9 when connecting them to a GPIO line.
10
11 Required properties:
12   - compatible: value must be "cec-gpio".
13   - cec-gpios: gpio that the CEC line is connected to. The line should be
14     tagged as open drain.
15
16 If the CEC line is associated with an HDMI receiver/transmitter, then the
17 following property is also required:
18
19   - hdmi-phandle - phandle to the HDMI controller, see also cec.txt.
20
21 If the CEC line is not associated with an HDMI receiver/transmitter, then
22 the following property is optional:
23
24   - hpd-gpios: gpio that the HPD line is connected to.
25
26 Example for the Raspberry Pi 3 where the CEC line is connected to
27 pin 26 aka BCM7 aka CE1 on the GPIO pin header and the HPD line is
28 connected to pin 11 aka BCM17 (some level shifter is needed for this!):
29
30 #include <dt-bindings/gpio/gpio.h>
31
32 cec-gpio {
33        compatible = "cec-gpio";
34        cec-gpios = <&gpio 7 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
35        hpd-gpios = <&gpio 17 GPIO_ACTIVE_HIGH>;
36 };