0001 * HDMI CEC GPIO driver
0002
0003 The HDMI CEC GPIO module supports CEC implementations where the CEC line
0004 is hooked up to a pull-up GPIO line and - optionally - the HPD line is
0005 hooked up to another GPIO line.
0006
0007 Please note: the maximum voltage for the CEC line is 3.63V, for the HPD and
0008 5V lines it is 5.3V. So you may need some sort of level conversion circuitry
0009 when connecting them to a GPIO line.
0010
0011 Required properties:
0012 - compatible: value must be "cec-gpio".
0013 - cec-gpios: gpio that the CEC line is connected to. The line should be
0014 tagged as open drain.
0015
0016 If the CEC line is associated with an HDMI receiver/transmitter, then the
0017 following property is also required:
0018
0019 - hdmi-phandle - phandle to the HDMI controller, see also cec.txt.
0020
0021 If the CEC line is not associated with an HDMI receiver/transmitter, then
0022 the following property is optional and can be used for debugging HPD changes:
0023
0024 - hpd-gpios: gpio that the HPD line is connected to.
0025
0026 This property is optional and can be used for debugging changes on the 5V line:
0027
0028 - v5-gpios: gpio that the 5V line is connected to.
0029
0030 Example for the Raspberry Pi 3 where the CEC line is connected to
0031 pin 26 aka BCM7 aka CE1 on the GPIO pin header, the HPD line is
0032 connected to pin 11 aka BCM17 and the 5V line is connected to pin
0033 15 aka BCM22 (some level shifter is needed for the HPD and 5V lines!):
0034
0035 #include <dt-bindings/gpio/gpio.h>
0036
0037 cec-gpio {
0038 compatible = "cec-gpio";
0039 cec-gpios = <&gpio 7 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
0040 hpd-gpios = <&gpio 17 GPIO_ACTIVE_HIGH>;
0041 v5-gpios = <&gpio 22 GPIO_ACTIVE_HIGH>;
0042 };