]> git.itanic.dy.fi Git - linux-stable/commit
bus: ti-sysc: Fix bogus resetdone warning on enable for cpsw
authorTony Lindgren <tony@atomide.com>
Mon, 26 Oct 2020 08:08:47 +0000 (10:08 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 2 Dec 2020 07:51:52 +0000 (08:51 +0100)
commita22c73ed9eabba990fca4b99700ea688dd821448
treeac95689f1163878eb4366ceb007bcee1c4ac7db2
parente79c3d983c3e81474c0a718908224e60749d5c42
bus: ti-sysc: Fix bogus resetdone warning on enable for cpsw

[ Upstream commit e7ae08d398e094e1305dee823435b1f996d39106 ]

Bail out early from sysc_wait_softreset() just like we do in sysc_reset()
if there's no sysstatus srst_shift to fix a bogus resetdone warning on
enable as suggested by Grygorii Strashko <grygorii.strashko@ti.com>.

We do not currently handle resets for modules that need writing to the
sysstatus register. If we at some point add that, we also need to add
SYSS_QUIRK_RESETDONE_INVERTED flag for cpsw as the sysstatus bit is low
when reset is done as described in the am335x TRM "Table 14-202
SOFT_RESET Register Field Descriptions"

Fixes: d46f9fbec719 ("bus: ti-sysc: Use optional clocks on for enable and wait for softreset bit")
Suggested-by: Grygorii Strashko <grygorii.strashko@ti.com>
Acked-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/bus/ti-sysc.c