reset: renesas: Check return value of reset_control_deassert()
PATCH 1/1 reset: renesas: Check return value of reset_control_deassert()
Deasserting the reset is vital, therefore bail out in case of error.
Suggested-by Biju Das <[email protected]>
Signed-off-by Heiner Kallweit <[email protected]>
--- drivers/reset/reset-rzg2l-usbphy-ctrl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/reset/reset-rzg2l-usbphy-ctrl.c +3 -1
@@ -121,7 +121,9 @@ static int rzg2l_usbphy_ctrl_probe(struct platform_device *pdev)return dev_err_probe (dev,PTR_ERR (priv->rstc),"failed to get reset\n" ); -reset_control_deassert (priv->rstc); + error =reset_control_deassert (priv->rstc); +if (error) +return error; priv->rcdev.ops = &rzg2l_usbphy_ctrl_reset_ops; priv->rcdev.of_reset_n_cells =1 ;
Signature · 1 line
2.34.1
Hi Heiner,
Thanks for the patch
Quoted 7 lines
Subject: [PATCH] reset: renesas: Check return value of
reset_control_deassert()Deasserting the reset is vital, therefore bail out in case of error.
Suggested-by Biju Das <[email protected]>Signed-off-by Heiner Kallweit <[email protected]>
Reviewed-by Biju Das <[email protected]>
Cheers,
Biju
Quoted 23 lines
--- drivers/reset/reset-rzg2l-usbphy-ctrl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)drivers/reset/reset-rzg2l-usbphy-ctrl.c +3
-1@@ -121,7 +121,9 @@ static int rzg2l_usbphy_ctrl_probe(struct platform_device *pdev)return dev_err_probe (dev,PTR_ERR (priv->rstc),"failed to get reset\n" ); -reset_control_deassert (priv->rstc); + error =reset_control_deassert (priv->rstc); +if (error) +return error; priv->rcdev.ops = &rzg2l_usbphy_ctrl_reset_ops;
priv->rcdev.of_reset_n_cells= 1;
--
2.34.1
Quoted 4 lines · Heiner Kallweit
Deasserting the reset is vital, therefore bail out in case of error.
Suggested-by Biju Das <[email protected]>Signed-off-by Heiner Kallweit <[email protected]>
Thank you, applied to reset/next.
regards
Philipp