Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp394115rdh; Sat, 23 Sep 2023 15:45:55 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGxtwKKL5PV0CWvRy5+jVL3SmRa84WsF7pNyOna0BX1gQ17WYnlr5FxpdcfxQnpDdCb0usq X-Received: by 2002:a05:6a00:1596:b0:691:27b:15b4 with SMTP id u22-20020a056a00159600b00691027b15b4mr11468927pfk.5.1695509154715; Sat, 23 Sep 2023 15:45:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695509154; cv=none; d=google.com; s=arc-20160816; b=uTiK4OsvO7PiYSQFEbCtdnrr7mnLmqXSugaJ3celRIe9Ba29nS9QhjPoy2e9QPeSJD jOqOm3+tMVWjWTPGkoeVuqQDVBHbnhHSv2H06Ojvkm2Nj81dA2OKnQmFH9FQY9i8ZWsl YWB/NncTijxir5vOg4t0IMD8qNhRJUOdZ8YFIHS7mo/1vdxEcrh885T5OV1xovLnCYLW kQFvzaAOdc4sBZ0hBeiKMPkzRx5BFLUk5FUOvV6ahEE6F10buZ26ceV1o3IhCzYgT+7l OL4lOSvLPHt3Wen87va4+iYYXMCNnBHfclCUFoRCn4gQjiynSsOj+jrxWEGGbFOryLqn irhg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:content-transfer-encoding :mime-version:subject:references:in-reply-to:message-id:date :dkim-signature; bh=ty4sITb12ZDfdB+zVFb8NEwYo4EPSEQnbFMyhWPYw2c=; fh=8Edhlrq5DWtEQB/rRaR26QZNN5ZbfJ7DbHKoRq3yn6Y=; b=y13YYUBfjn225tjeabLtKUaSvbncVu2F2B1WrRpaJ61GoiH8iJmaifAv1fqaMI2s5y V0DLr0OvE8lB7IkI8XFfU4ZqICe/rjE8xD7cklMw9v+ZzmYuK3XS17xxfwnLddzR2bDz +rOAgObEnsNwzbA/9tj9oJ4HUhjBwC4l4uEYqwWjRXp5Rszkevaq34SSEBzi0/vkOGrA P7zrQzKDdnfGaCEKqMt8FaUaLcPy92NBqSj2L0d0gGGEjm79QitQPPv9Jdkr6tePBdWN uqOpVJ9N0i6qV3roSV/VM46gO/r3TdLiwrutXq+DLJlkFl/XYWsHcIZsw7PFVcbuNBxH MPHw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rere.qmqm.pl header.s=1 header.b=S8EWylnI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=rere.qmqm.pl Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id f8-20020a056a001ac800b0068fcc84dda7si6933355pfv.327.2023.09.23.15.45.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 23 Sep 2023 15:45:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@rere.qmqm.pl header.s=1 header.b=S8EWylnI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=rere.qmqm.pl Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 5F0F0810AF59; Sat, 23 Sep 2023 12:42:14 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229655AbjIWTmL (ORCPT + 99 others); Sat, 23 Sep 2023 15:42:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60570 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229459AbjIWTmI (ORCPT ); Sat, 23 Sep 2023 15:42:08 -0400 Received: from rere.qmqm.pl (rere.qmqm.pl [91.227.64.183]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 77860AB for ; Sat, 23 Sep 2023 12:41:59 -0700 (PDT) Received: from remote.user (localhost [127.0.0.1]) by rere.qmqm.pl (Postfix) with ESMTPSA id 4RtKK05YBczDJ; Sat, 23 Sep 2023 21:41:56 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=rere.qmqm.pl; s=1; t=1695498116; bh=kFsKirDvyE7bdimLhfZJhpSM+ljGh33ev81Eebpilkw=; h=Date:In-Reply-To:References:Subject:From:To:Cc:From; b=S8EWylnI32XiWoR2ljwjjzelXKDlOubs3XTeFwGSX3ztDdWvxTh5fULLKkZruaI1y 8o8XD0JbSWC3/IgcpPK+oBLru+W4F7sPgoorM5lYqlxWlRmiS3S9ROuXlHlYyQxB2v wI6SyL+T8YznI+IzoFyKz0+FLEA+b8YrA6XuGO0udfJDfbsBtw2qhhjwnyv+YW1kSE xcgSJGCTZCA7+iyFRHIyArziN+ITt9By1XkJDQ+5lshxWWEwbx79xh+B6D+3pSWWk6 sLc16FfYwZO2Q0DcjHxO+XgROmY31FW2IrSrdw9JZlwFKj2OjO3p4slfXXkVMNXvyv Cu9GtZW2690kA== X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.8 at mail Date: Sat, 23 Sep 2023 21:41:56 +0200 Message-Id: In-Reply-To: References: Subject: [PATCH 3/3] usb: chipidea: tegra: Consistently use dev_err_probe() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: =?UTF-8?q?Micha=C5=82=20Miros=C5=82aw?= To: Peter Chen , Greg Kroah-Hartman , Jonathan Hunter , Dmitry Osipenko , Peter Geis , Thierry Reding Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org, linux-usb@vger.kernel.org X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Sat, 23 Sep 2023 12:42:14 -0700 (PDT) Convert all error exits from probe() to dev_err_probe(). Signed-off-by: Michał Mirosław --- drivers/usb/chipidea/ci_hdrc_tegra.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/drivers/usb/chipidea/ci_hdrc_tegra.c b/drivers/usb/chipidea/ci_hdrc_tegra.c index 8e78bf643e25..2cc305803217 100644 --- a/drivers/usb/chipidea/ci_hdrc_tegra.c +++ b/drivers/usb/chipidea/ci_hdrc_tegra.c @@ -293,14 +293,12 @@ static int tegra_usb_probe(struct platform_device *pdev) usb->phy = devm_usb_get_phy_by_phandle(&pdev->dev, "nvidia,phy", 0); if (IS_ERR(usb->phy)) return dev_err_probe(&pdev->dev, PTR_ERR(usb->phy), - "failed to get PHY\n"); + "failed to get PHY"); usb->clk = devm_clk_get(&pdev->dev, NULL); - if (IS_ERR(usb->clk)) { - err = PTR_ERR(usb->clk); - dev_err(&pdev->dev, "failed to get clock: %d\n", err); - return err; - } + if (IS_ERR(usb->clk)) + return dev_err_probe(&pdev->dev, PTR_ERR(usb->clk), + "failed to get clock"); err = devm_tegra_core_dev_init_opp_table_common(&pdev->dev); if (err) @@ -316,7 +314,7 @@ static int tegra_usb_probe(struct platform_device *pdev) err = tegra_usb_reset_controller(&pdev->dev); if (err) { - dev_err(&pdev->dev, "failed to reset controller: %d\n", err); + dev_err_probe(&pdev->dev, err, "failed to reset controller"); goto fail_power_off; } @@ -347,8 +345,8 @@ static int tegra_usb_probe(struct platform_device *pdev) usb->dev = ci_hdrc_add_device(&pdev->dev, pdev->resource, pdev->num_resources, &usb->data); if (IS_ERR(usb->dev)) { - err = PTR_ERR(usb->dev); - dev_err(&pdev->dev, "failed to add HDRC device: %d\n", err); + err = dev_err_probe(&pdev->dev, PTR_ERR(usb->dev), + "failed to add HDRC device"); goto phy_shutdown; } -- 2.39.2