Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
[linux.git] / drivers / i2c / busses / i2c-designware-platdrv.c
index d0bdac0498cebafe3def932006c1380cfc318c1f..9c7802614342c5a98a62622c4511be336c9c1017 100644 (file)
@@ -159,6 +159,13 @@ static int dw_i2c_probe(struct platform_device *pdev)
                                        "i2c-sda-hold-time-ns", &ht);
                dev->sda_hold_time = div_u64((u64)ic_clk * ht + 500000,
                                             1000000);
+
+               of_property_read_u32(pdev->dev.of_node,
+                                    "i2c-sda-falling-time-ns",
+                                    &dev->sda_falling_time);
+               of_property_read_u32(pdev->dev.of_node,
+                                    "i2c-scl-falling-time-ns",
+                                    &dev->scl_falling_time);
        }
 
        dev->functionality =
@@ -195,7 +202,7 @@ static int dw_i2c_probe(struct platform_device *pdev)
        adap = &dev->adapter;
        i2c_set_adapdata(adap, dev);
        adap->owner = THIS_MODULE;
-       adap->class = I2C_CLASS_HWMON;
+       adap->class = I2C_CLASS_HWMON | I2C_CLASS_DEPRECATED;
        strlcpy(adap->name, "Synopsys DesignWare I2C adapter",
                        sizeof(adap->name));
        adap->algo = &i2c_dw_algo;