Commit f33eb7f2 authored by Jim Quinlan's avatar Jim Quinlan Committed by Philipp Zabel

reset: brcmstb-rescal: fix incorrect polarity of status bit

The readl_poll_timeout() should complete when the status bit
is a 1, not 0.

Fixes: 4cf176e5 ("reset: Add Broadcom STB RESCAL reset controller")
Signed-off-by: default avatarJim Quinlan <jim2101024@gmail.com>
Signed-off-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Link: https://lore.kernel.org/r/20210914221122.62315-1-f.fainelli@gmail.comSigned-off-by: default avatarPhilipp Zabel <p.zabel@pengutronix.de>
parent 6880fa6c
......@@ -38,7 +38,7 @@ static int brcm_rescal_reset_set(struct reset_controller_dev *rcdev,
}
ret = readl_poll_timeout(base + BRCM_RESCAL_STATUS, reg,
!(reg & BRCM_RESCAL_STATUS_BIT), 100, 1000);
(reg & BRCM_RESCAL_STATUS_BIT), 100, 1000);
if (ret) {
dev_err(data->dev, "time out on SATA/PCIe rescal\n");
return ret;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment