Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

spi: spi-txx9: Add missing clock (un)prepare calls for CCF

While the custom minimal TXx9 clock implementation doesn't need or use
clock (un)prepare calls (they are dummies if !CONFIG_HAVE_CLK_PREPARE),
they are mandatory when using the Common Clock Framework.

Hence add them, to prepare for the advent of CCF.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Geert Uytterhoeven and committed by
Mark Brown
1ae4ec14 29b4817d

+3 -3
+3 -3
drivers/spi/spi-txx9.c
··· 346 346 c->clk = NULL; 347 347 goto exit; 348 348 } 349 - ret = clk_enable(c->clk); 349 + ret = clk_prepare_enable(c->clk); 350 350 if (ret) { 351 351 c->clk = NULL; 352 352 goto exit; ··· 395 395 exit_busy: 396 396 ret = -EBUSY; 397 397 exit: 398 - clk_disable(c->clk); 398 + clk_disable_unprepare(c->clk); 399 399 spi_master_put(master); 400 400 return ret; 401 401 } ··· 406 406 struct txx9spi *c = spi_master_get_devdata(master); 407 407 408 408 flush_work(&c->work); 409 - clk_disable(c->clk); 409 + clk_disable_unprepare(c->clk); 410 410 return 0; 411 411 } 412 412