Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1872164ybb; Sat, 21 Mar 2020 07:39:05 -0700 (PDT) X-Google-Smtp-Source: ADFU+vt1wPtDmguGebk34xh7krEqGv67V2Vem9NSmb8HPn3bCfUiBljdrjouecThOVgeGoFdajH/ X-Received: by 2002:aca:450a:: with SMTP id s10mr10464080oia.25.1584801545743; Sat, 21 Mar 2020 07:39:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584801545; cv=none; d=google.com; s=arc-20160816; b=MFsy1An8BkJ3447dZsYrCjj7wXuQ1caGP7VAD8VJIMSEYEqi+c6FL6pobHwOoD/VRC MhGBt+Ki0bBwt7T9gDU3IFyzTmnSMAFiUS3Gu2zpBUaQj9f5pq93OOa+A9QqcS3UpVf5 qWlH6oremDzUwpZkWAP+GNmZ05RrCruOPnB3BHEr5pxgfRptLwoiWLhWYZSUz1WRo6qM wmZ737AiAeODZKnYZiugUa1VV7IN0TjSPWDjPQDGXSc9M+tdpd/R85JrhRzRLdUDlCJ2 ivssdSLQnpBtmWNmfFoxyhkpgKYtu8T+7u3QhFlnwkICVSrj2BeWCL8HRcA1mZDgGf40 IslA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=KHezbaonDObNhrnITsOBJjiiKzk30bQA9Nv61l1omqk=; b=JnFMgOVboKnVrKwzt/T2piHe/K9XvTxD+0G4DC78qIFH6tBihE9EMBp3kJBGLZXS43 9BOen15wTDmqhE3Ah8+svwjz2CDvzcIs0NZrPR4erUHiY37iU/CXkGCbLjvNQ4vZVb4E WvnMqPHYemjJ6o14uDnFYyxczVEXQazU1Rvaw5jclXBhTyftGRLn5q2CZV8gSXsRCnYd WNKhZXtG1T0W2DJzasXqfrcwQumy3Xb1u1HSQxT54IrXsNForZcYEQD6tsvQQpyaJ6eQ T1Gi32a1zfSNFTIhd9i0/UQsDPDhNp8ToUo8FCkVHngcxUIbXr9GtzxQ9Qk2CGpOlMWo N7Rw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=cIcG4ZRm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n198si4323873oig.37.2020.03.21.07.38.53; Sat, 21 Mar 2020 07:39:05 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=cIcG4ZRm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727244AbgCUOih (ORCPT + 99 others); Sat, 21 Mar 2020 10:38:37 -0400 Received: from mail-wr1-f65.google.com ([209.85.221.65]:46414 "EHLO mail-wr1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726607AbgCUOig (ORCPT ); Sat, 21 Mar 2020 10:38:36 -0400 Received: by mail-wr1-f65.google.com with SMTP id j17so7582067wru.13; Sat, 21 Mar 2020 07:38:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=KHezbaonDObNhrnITsOBJjiiKzk30bQA9Nv61l1omqk=; b=cIcG4ZRm5PgmhKA92ygSxLPrxu7LZhPesEZxIfgPAfNuVpC7YynZsD5a/+MzA5EpaG ArirO23mGiHwzZYi/B/SyqQPJCqOCb73+L4OJo+pfY61/k43+TIAY4q2LUuU+rYsFd0j 6KAWqV0zF3TRV7jnt+t+368F/ULon3DMD54hukiqnZ2huZsCrFoU2PopNmc6Apap92ZQ vS4AzOXyyvxnGKgRLMGkMfOFyOR0697PVql8GAy97analmoW7YVKNNG6C0IR1YBfh3Na wKI4PXD9KuA8QMHDrh0rBnyP21DFlRrmmhV++5JKSQXxrOi7dQSVafzDtkGo45gw/HnP 5SHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; bh=KHezbaonDObNhrnITsOBJjiiKzk30bQA9Nv61l1omqk=; b=tbQE8FSjRGmsLM1DHUEfu6Un4ZoRKPGHPi4lh6ZvsDUBAtlSGucZAP/4sE55zfmNwB 8/Oi2UE57JNS6r7jOENTgh16tTRCM4cAe2BYPyhTB/0G3h9mJIQNW3baWJ4sbSTARAbL XYMFV1B31FMP85el3TAhHRAy1bUbQOgvEGYL1cBiGFYYGSghYRTHiaH6bjSfL9b9kHPD DpLJKjrGPp5OJZ1jX5S3/f+UBYJWvbK2rTTUYSrvTTHaK2k9ofdYfZ4yGIUZxtNtEoqz ru26oLomqSot2tDL16X8nXJxXhP+YCgd0lI4APX5ccs4kLRPcjOJy1TaC08DfmDVIdeG S1bA== X-Gm-Message-State: ANhLgQ0xPrSa2+SdvOpKWkvbw9vUGxSgtzxu3pBCGuD4HEKPhw9TXY7v PNmZVWGLLu56C4bjsi/NFFzLw6W7 X-Received: by 2002:adf:9b96:: with SMTP id d22mr19058977wrc.249.1584801514210; Sat, 21 Mar 2020 07:38:34 -0700 (PDT) Received: from localhost.localdomain ([2a01:4262:1ab:c:b4be:c5ec:d5f1:2a7f]) by smtp.gmail.com with ESMTPSA id w204sm13499569wma.1.2020.03.21.07.38.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Mar 2020 07:38:33 -0700 (PDT) From: Emil Renner Berthing To: netdev@vger.kernel.org Cc: David Wu , Giuseppe Cavallaro , Alexandre Torgue , Jose Abreu , "David S . Miller" , linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Emil Renner Berthing Subject: [PATCH] net: stmmac: dwmac-rk: fix error path in rk_gmac_probe Date: Sat, 21 Mar 2020 15:36:19 +0100 Message-Id: <20200321143619.91533-1-kernel@esmil.dk> X-Mailer: git-send-email 2.25.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Make sure we clean up devicetree related configuration also when clock init fails. Fixes: fecd4d7eef8b ("net: stmmac: dwmac-rk: Add integrated PHY support") Signed-off-by: Emil Renner Berthing --- drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c index dc50ba13a746..2d5573b3dee1 100644 --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c @@ -1406,17 +1406,17 @@ static int rk_gmac_probe(struct platform_device *pdev) plat_dat->bsp_priv = rk_gmac_setup(pdev, plat_dat, data); if (IS_ERR(plat_dat->bsp_priv)) { ret = PTR_ERR(plat_dat->bsp_priv); goto err_remove_config_dt; } ret = rk_gmac_clk_init(plat_dat); if (ret) - return ret; + goto err_remove_config_dt; ret = rk_gmac_powerup(plat_dat->bsp_priv); if (ret) goto err_remove_config_dt; ret = stmmac_dvr_probe(&pdev->dev, plat_dat, &stmmac_res); if (ret) goto err_gmac_powerdown; -- 2.25.2