summaryrefslogtreecommitdiffstats
path: root/drivers/i2c/busses/i2c-uniphier.c
Commit message (Collapse)AuthorAgeFilesLines
* i2c: uniphier: add suspend / resume supportMasahiro Yamada2017-08-121-5/+35
| | | | | | | | When resuming, set up registers that have been lost in the sleep state. Also, add clock handling in the resume / suspend hooks. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier: rename jump label to follow coding style guidelineMasahiro Yamada2016-11-181-3/+3
| | | | | | | | Documentation/CodingStyle recommends to use label names which say what the goto does or why the goto exists. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier: avoid WARN_ON() of clk_disable() in failure pathMasahiro Yamada2016-09-081-42/+31
| | | | | | | | | | | | If clk_prepare_enable() fails, clk_disable_unprepare() is called in the failure path, where the enable_count is still zero, so it hits WARN_ON(core->enable_count == 0) in the clk_core_disable(). To fix this, make the clock setting more linear in the probe function so that it can exploit "goto err" in case of error. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier{-f}: don't print error when adding adapter failsWolfram Sang2016-08-221-5/+0
| | | | | | | | | The core will do this for us now. Signed-off-by: Wolfram Sang <wsa-dev@sang-engineering.com> Acked-by: Masahiro Yamada <yamada.masahiro@socionext.com> Acked-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier: add "\n" at the end of error logMasahiro Yamada2016-04-271-1/+1
| | | | | | | Just in case. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier: fix typos in error messagesMasahiro Yamada2016-02-121-1/+1
| | | | | Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier: error out if bus speed is zeroMasahiro Yamada2015-12-141-0/+5
| | | | | | | | | There is code to divide by "bus_speed" some lines below. To eliminate the possibility of division by zero, bail out if "clock-frequency" is specified as zero. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier: error out if clock rate is zeroMasahiro Yamada2015-12-141-1/+5
| | | | | | | | | | This input clock is used to generate the sampling clock for I2C bus. If the clock rate is zero, there is something wrong with the clock driver. Bail out with the appropriate error message in such a case. It would make it easier to find the root cause of failure. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
* i2c: uniphier: add UniPhier FIFO-less I2C driverMasahiro Yamada2015-10-231-0/+441
Add support for on-chip I2C controller used on old UniPhier SoCs such as PH1-LD4, PH1-sLD8, etc. This adapter is so simple that it has no FIFO in it. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
OpenPOWER on IntegriCloud