From a19b55088945ce86051ea4eab22df27805a30c71 Mon Sep 17 00:00:00 2001 From: Samuel Holland Date: Sun, 13 Jun 2021 23:41:44 -0500 Subject: [PATCH 044/117] hwspinlock: sun6i: Fix driver to match binding The binding for this device does not allow using the clock-names and reset-names properties, so the driver should not reference the clock or reset by name. Fixes: 3c881e05c814 ("hwspinlock: add sun6i hardware spinlock support") Signed-off-by: Samuel Holland --- drivers/hwspinlock/sun6i_hwspinlock.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) --- a/drivers/hwspinlock/sun6i_hwspinlock.c +++ b/drivers/hwspinlock/sun6i_hwspinlock.c @@ -104,14 +104,12 @@ static int sun6i_hwspinlock_probe(struct if (!priv) return -ENOMEM; - priv->ahb_clk = devm_clk_get(&pdev->dev, "ahb"); - if (IS_ERR(priv->ahb_clk)) { - err = PTR_ERR(priv->ahb_clk); - dev_err(&pdev->dev, "unable to get AHB clock (%d)\n", err); - return err; - } + priv->ahb_clk = devm_clk_get(&pdev->dev, NULL); + if (IS_ERR(priv->ahb_clk)) + return dev_err_probe(&pdev->dev, PTR_ERR(priv->ahb_clk), + "unable to get AHB clock\n"); - priv->reset = devm_reset_control_get(&pdev->dev, "ahb"); + priv->reset = devm_reset_control_get(&pdev->dev, NULL); if (IS_ERR(priv->reset)) return dev_err_probe(&pdev->dev, PTR_ERR(priv->reset), "unable to get reset control\n");