alistair23-linux/drivers/i2c
Max Schwarz 249051f499 i2c: rk3x: handle dynamic clock rate changes correctly
The i2c input clock can change dynamically, e.g. on the RK3066 where
pclk_i2c0 and pclk_i2c1 are connected to the armclk, which changes
rate on cpu frequency scaling.

Until now, we incorrectly called clk_get_rate() while holding the
i2c->lock in rk3x_i2c_xfer() to adapt to clock rate changes.
Thanks to Huang Tao for reporting this issue.

Do it properly now using the clk notifier framework. The callback
logic was taken from i2c-cadence.c.

Also rename all misleading "i2c_rate" variables to "clk_rate", as they
describe the *input* clk rate.

Signed-off-by: Max Schwarz <max.schwarz@online.de>
Tested-by: Doug Anderson <dianders@chromium.org> on RK3288
Reviewed-by: Doug Anderson <dianders@chromium.org>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
2014-11-23 17:27:46 +01:00
..
algos i2c: remove FSF address 2014-11-07 18:35:33 +01:00
busses i2c: rk3x: handle dynamic clock rate changes correctly 2014-11-23 17:27:46 +01:00
muxes Merge branch 'i2c/for-3.17' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux 2014-08-09 09:15:07 -07:00
i2c-boardinfo.c i2c: remove FSF address 2014-11-07 18:35:33 +01:00
i2c-core.c i2c: acpi: remove unneeded variable initialization 2014-11-18 16:03:05 +01:00
i2c-core.h i2c: remove FSF address 2014-11-07 18:35:33 +01:00
i2c-dev.c i2c: remove FSF address 2014-11-07 18:35:33 +01:00
i2c-mux.c i2c: mux: create "channel-n" symlinks for child segments in the mux device 2014-11-18 16:09:49 +01:00
i2c-smbus.c i2c: remove FSF address 2014-11-07 18:35:33 +01:00
i2c-stub.c i2c: remove FSF address 2014-11-07 18:35:33 +01:00
Kconfig i2c: rework kernel config I2C_ACPI 2014-08-19 10:19:39 -05:00
Makefile i2c: move acpi code back into the core 2014-09-25 16:07:15 +02:00