Skip to contentSkip to conversation

pinctrl: sunxi: handle probe defferal

PATCH In review Corentin Labbe 3 participants 3 messages Apr 2, 2020 – Apr 16, 2020

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 pinctrl: sunxi: handle probe defferal

When checking the logs on my sun8i-a33-olinuxino I saw:
sun8i-a23-r-pinctrl 1f02c00.pinctrl: Reset controller missing but this driver was working after.
This message is just here because the reset controller was still not probed. So don't say anything if the return code say to wait.

---
 drivers/pinctrl/sunxi/pinctrl-sun8i-a23-r.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
drivers/pinctrl/sunxi/pinctrl-sun8i-a23-r.c +5 -2
index 8a08c4afc6a8..9e5b61449999 100644
@@ -103,8 +103,11 @@ static int sun8i_a23_r_pinctrl_probe(struct platform_device *pdev)
 
 	rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL);
 	if (IS_ERR(rstc)) {
-		dev_err(&pdev->dev, "Reset controller missing\n");
-		return PTR_ERR(rstc);
+		ret = PTR_ERR(rstc);
+		if (ret == -EPROBE_DEFER)
+			return ret;
+		dev_err(&pdev->dev, "Reset controller missing err=%d\n", ret);
+		return ret;
 	}
 
 	ret = reset_control_deassert(rstc);
Signature · 1 line
2.24.1
Acked-by on v1 1/1
#1 lore raw
Quoted 7 lines · Corentin Labbe

When checking the logs on my sun8i-a33-olinuxino I saw:
sun8i-a23-r-pinctrl 1f02c00.pinctrl: Reset controller missing but this driver was working after.
This message is just here because the reset controller was still not probed. So don't say anything if the return code say to wait.

Maxime

#2 lore raw
In reply to Corentin Labbe
Quoted 7 lines · Corentin Labbe

When checking the logs on my sun8i-a33-olinuxino I saw:
sun8i-a23-r-pinctrl 1f02c00.pinctrl: Reset controller missing but this driver was working after.
This message is just here because the reset controller was still not probed. So don't say anything if the return code say to wait.

Patch applied with Maxime's ACK!

Thanks,
Linus Walleij

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel