]> git.karo-electronics.de Git - linux-beck.git/commit
i2c: cadence: Move to sensible power management
authorShubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
Tue, 24 Nov 2015 07:31:56 +0000 (13:01 +0530)
committerWolfram Sang <wsa@the-dreams.de>
Mon, 30 Nov 2015 20:07:40 +0000 (21:07 +0100)
commit7fa32329ca03148fb2c07b4ef3247b8fc0488d6a
tree2022218964e2325cdf2b504ba4731f5a977fd260
parentcfa576db834cacc1bb01bc41b2f61a8b578e67c5
i2c: cadence: Move to sensible power management

Currently the clocks are enabled at probe and disabled at remove.
Which keeps the clocks enabled even if no transaction is going on.
This patch enables the clocks at the start of transfer and disables
after it.

Also adapts to runtime pm.

converts dev pm to const to silence a checkpatch warning.

Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-cadence.c