spi: imx: use prepare_transfer_hardware() for lpspi
authorGao Pan <pandy.gao@nxp.com>
Thu, 24 Nov 2016 11:04:44 +0000 (19:04 +0800)
committerMark Brown <broonie@kernel.org>
Fri, 25 Nov 2016 13:04:41 +0000 (13:04 +0000)
commit3ffa1a5dc696f661754bf145813433fda92371b2
tree00dadd3ad3a993a6d3c8fe64377ef5262b289a55
parenta17efbc5ef9468aae32c7799a0ebc329c15cd0dc
spi: imx: use prepare_transfer_hardware() for lpspi

The old driver enable clk in fsl_lpspi_prepare_message() and
disable clk in fsl_lpspi_unprepare_message().

Rather than doing this per message it's a bit better to do it
in prepare_transfer_hardware(), that way if there's a sequence
of messages queued one after another we don't turn the clock on
and off all the time.

Signed-off-by: Gao Pan <pandy.gao@nxp.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-fsl-lpspi.c