]> git.baikalelectronics.ru Git - kernel.git/commit
i2c: algo: pca: Fix mode selection for PCA9665
authorThomas Kavanagh <tkavanagh@juniper.net>
Thu, 13 Sep 2012 15:16:55 +0000 (08:16 -0700)
committerWolfram Sang <w.sang@pengutronix.de>
Fri, 14 Sep 2012 13:25:22 +0000 (15:25 +0200)
commitd6408c579cbad9348f83ac8747da7dd4d67c5c88
treef2dd903950cfd5732126210c475b040c940838f1
parentc3bc406d71176cf8e8601dc09601514abcb63197
i2c: algo: pca: Fix mode selection for PCA9665

The code currently always selects turbo mode for PCA9665, no matter which
clock frequency is configured. This is because it compares the clock frequency
against constants reflecting (boundary / 100). Compare against real boundary
frequencies to fix the problem.

Signed-off-by: Thomas Kavanagh <tkavanagh@juniper.net>
Signed-off-by: Guenter Roeck <groeck@juniper.net>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
drivers/i2c/algos/i2c-algo-pca.c