100 lines · yaml
1# SPDX-License-Identifier: GPL-2.02%YAML 1.23---4$id: http://devicetree.org/schemas/i2c/i2c-gpio.yaml#5$schema: http://devicetree.org/meta-schemas/core.yaml#6 7title: GPIO bitbanged I2C8 9maintainers:10 - Wolfram Sang <wsa@kernel.org>11 12allOf:13 - $ref: /schemas/i2c/i2c-controller.yaml#14 15properties:16 compatible:17 items:18 - const: i2c-gpio19 20 sda-gpios:21 description:22 gpio used for the sda signal, this should be flagged as23 active high using open drain with (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)24 from <dt-bindings/gpio/gpio.h> since the signal is by definition25 open drain.26 maxItems: 127 28 scl-gpios:29 description:30 gpio used for the scl signal, this should be flagged as31 active high using open drain with (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)32 from <dt-bindings/gpio/gpio.h> since the signal is by definition33 open drain.34 maxItems: 135 36 i2c-gpio,sda-output-only:37 description: sda as output only38 type: boolean39 40 i2c-gpio,scl-output-only:41 description: scl as output only42 type: boolean43 44 i2c-gpio,delay-us:45 description: delay between GPIO operations (may depend on each platform)46 47 i2c-gpio,timeout-ms:48 description: timeout to get data49 50 # Deprecated properties, do not use in new device tree sources:51 gpios:52 minItems: 253 maxItems: 254 description: sda and scl gpio, alternative for {sda,scl}-gpios55 56 i2c-gpio,sda-open-drain:57 type: boolean58 deprecated: true59 description: this means that something outside of our control has put60 the GPIO line used for SDA into open drain mode, and that something is61 not the GPIO chip. It is essentially an inconsistency flag.62 63 i2c-gpio,scl-open-drain:64 type: boolean65 deprecated: true66 description: this means that something outside of our control has put the67 GPIO line used for SCL into open drain mode, and that something is not68 the GPIO chip. It is essentially an inconsistency flag.69 70 i2c-gpio,sda-has-no-pullup:71 type: boolean72 description: sda is used in a non-compliant way and has no pull-up.73 Therefore disable open-drain. This property is mutually-exclusive74 with i2c-gpio,sda-open-drain.75 76 i2c-gpio,scl-has-no-pullup:77 type: boolean78 description: scl is used in a non-compliant way and has no pull-up.79 Therefore disable open-drain. This property is mutually-exclusive80 with i2c-gpio,scl-open-drain.81 82dependencies:83 i2c-gpio,sda-has-no-pullup:84 not:85 required:86 - i2c-gpio,sda-open-drain87 i2c-gpio,scl-has-no-pullup:88 not:89 required:90 - i2c-gpio,scl-open-drain91 92required:93 - compatible94 - sda-gpios95 - scl-gpios96 97unevaluatedProperties: false98 99...100