Skip to content
Commit 9e556dcc authored by Huang Shijie's avatar Huang Shijie Committed by Mark Brown
Browse files

spi: spi-imx: only enable the clocks when we start to transfer a message



Current code keeps the clocks enabled all the time, it wastes the power
when there is no operaiton on the spi controller.

In order to save the power, this patch adds the two hooks:
   spi_imx_prepare_message: enable the clocks for this message
   spi_imx_unprepare_message: disable the clocks.

This patch also disables the clocks in the end of the probe.

Signed-off-by: default avatarHuang Shijie <b32955@freescale.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 31d141e3
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment