apertus-open-source-cinema / axiom-firmware

AXIOM firmware (linux image, gateware and software tools)
GNU General Public License v3.0
169 stars 53 forks source link

Devicetree using deprecated gpios entry for i2c_gpio #170

Open herbertp opened 3 years ago

herbertp commented 3 years ago

Currently the devicetree contains an entry like this ...

    i2c_gpio: zed_i2c_gpio {
        #address-cells = <1>;
        #size-cells = <0>;
        compatible = "i2c-gpio";
        bus-id = <2>;
        gpios = <&gpio0 9 0 /* sda */
                 &gpio0 0 0 /* scl */ >;

... while it should be ...

        sda-gpios = <&gpio0 9 0>;
        scl-gpios = <&gpio0 0 0>;
herbertp commented 3 years ago

I also propose to change the delay to 3us because this roughly gives 125kHz on the I2C bus which is perfectly fine for all I2C devices there and set a timeout of 100ms to prevent lockups.

        i2c-gpio,delay-us = <3>;   /* ~125 kHz */
        i2c-gpio,timeout-ms = <100>;