]> git.karo-electronics.de Git - linux-beck.git/commit
spi: imx: set spi_bus_clk for mx21 and mx27
authorRobert Baldyga <r.baldyga@hackerion.com>
Tue, 1 Nov 2016 21:18:39 +0000 (22:18 +0100)
committerMark Brown <broonie@kernel.org>
Wed, 2 Nov 2016 15:30:43 +0000 (09:30 -0600)
commit32df9ff2b88f9b3ef0865837cd6a39c957dab875
treee4f49ad83d6030c856e05fa0e995791bae4dbe26
parent2dd33f9cec90499029fd49ffae2922c3f9ccad11
spi: imx: set spi_bus_clk for mx21 and mx27

Introduce additional output parameter in spi_imx_clkdiv_1()
function to return result frequency and set it to spi_bus_clk.

This fixes division by zero bug, which occurred in
spi_imx_calculate_timeout() function.

Signed-off-by: Robert Baldyga <r.baldyga@hackerion.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-imx.c