]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ARM: dts: socfpga: set desired i2c clock on Cyclone5 and Arria5 devkits
authorDinh Nguyen <dinguyen@kernel.org>
Tue, 13 Dec 2016 22:52:11 +0000 (16:52 -0600)
committerDinh Nguyen <dinguyen@kernel.org>
Thu, 5 Jan 2017 00:11:51 +0000 (18:11 -0600)
The I2C LCD display on the Cyclone5 and Arria5 devkits is only capable of
the standard 100 kHz clock. Set the "clock-frequency" of the I2C node
to be 100000.

Signed-off-by: Dinh Nguyen <dinguyen@kernel.org>
arch/arm/boot/dts/socfpga_arria5_socdk.dts
arch/arm/boot/dts/socfpga_cyclone5_socdk.dts

index fa70c394dcfe557c16307c2b702aee66356f793b..8672edf9ba4ebccb6c4b131909bccd6d9d8070bb 100644 (file)
 
 &i2c0 {
        status = "okay";
+       clock-frequency = <100000>;
+
+       /*
+        * adjust the falling times to decrease the i2c frequency to 50Khz
+        * because the LCD module does not work at the standard 100Khz
+        */
+       i2c-sda-falling-time-ns = <5000>;
+       i2c-scl-falling-time-ns = <5000>;
 
        eeprom@51 {
                compatible = "atmel,24c32";
index 6d3188bfefd838e8b6b5964c73297e60e9098fd8..24650bafcef473c5e19170e8b980a0b20bec0d47 100644 (file)
 
 &i2c0 {
        status = "okay";
+       clock-frequency = <100000>;
+
+       /*
+        * adjust the falling times to decrease the i2c frequency to 50Khz
+        * because the LCD module does not work at the standard 100Khz
+        */
+       i2c-sda-falling-time-ns = <5000>;
+       i2c-scl-falling-time-ns = <5000>;
 
        eeprom@51 {
                compatible = "atmel,24c32";