]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
spi: imx: fix runtime pm support for !CONFIG_PM
authorSascha Hauer <s.hauer@pengutronix.de>
Wed, 21 Oct 2020 10:45:13 +0000 (12:45 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 18 Nov 2020 18:22:00 +0000 (19:22 +0100)
commit1dfc44fd609fc96cd4a7ec2dbf43ca47759d83db
tree37f8226eb872128a24c6ca1c42051ed19f6f3da1
parent35b83f670a17f2ad8c844ffbcc425facf1a5be7f
spi: imx: fix runtime pm support for !CONFIG_PM

[ Upstream commit 43b6bf406cd0319e522638f97c9086b7beebaeaa ]

525c9e5a32bd introduced pm_runtime support for the i.MX SPI driver. With
this pm_runtime is used to bring up the clocks initially. When CONFIG_PM
is disabled the clocks are no longer enabled and the driver doesn't work
anymore. Fix this by enabling the clocks in the probe function and
telling pm_runtime that the device is active using
pm_runtime_set_active().

Fixes: 525c9e5a32bd spi: imx: enable runtime pm support
Tested-by: Christian Eggers <ceggers@arri.de> [tested for !CONFIG_PM only]
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Link: https://lore.kernel.org/r/20201021104513.21560-1-s.hauer@pengutronix.de
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/spi/spi-imx.c