soc: imx8m: Enable OCOTP clock before reading the register
authorXiaolei Wang <xiaolei.wang@windriver.com>
Fri, 28 Oct 2022 04:14:18 +0000 (12:14 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 26 Nov 2022 08:24:39 +0000 (09:24 +0100)
commit19feb6cf41368e9c8237c8a6be158f161ad2f2d9
treeb59521cc41f3ebaecc26171f5950293e327e8907
parent8c54d706d829ccbfebcf112745c2281430dee574
soc: imx8m: Enable OCOTP clock before reading the register

[ Upstream commit 836fb30949d9edf91d7de696a884ceeae7e426d2 ]

Commit 7d981405d0fd ("soc: imx8m: change to use platform driver") ever
removed the dependency on bootloader for enabling OCOTP clock.  It
helped to fix a kexec kernel hang issue.  But unfortunately it caused
a regression on CAAM driver and got reverted.

This is the second try to enable the OCOTP clock by directly calling
clock API instead of indirectly enabling the clock via nvmem API.

Fixes: ac34de14ac30 ("Revert "soc: imx8m: change to use platform driver"")
Signed-off-by: Xiaolei Wang <xiaolei.wang@windriver.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/soc/imx/soc-imx8m.c