Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp1143733rdh; Mon, 25 Sep 2023 04:48:32 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHidkKiKPKSsGXtkC6IwHDqsiMIyHNAGri9j2qaGBpD1lML4511GFhQh7jZIt7wTuKEhmWG X-Received: by 2002:a05:6a00:14cc:b0:68f:cbd3:5b01 with SMTP id w12-20020a056a0014cc00b0068fcbd35b01mr16986552pfu.13.1695642512039; Mon, 25 Sep 2023 04:48:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695642512; cv=none; d=google.com; s=arc-20160816; b=cXMNEFjnwP+eC7hp1rj5vJSJmTo48+fADXNrTZ7NFiBH4HB5iIYTIjmjz4BoNwYD30 iEmJWI5IxOIUzs1DqQSz0LXv+rtqZ/nAnN6oBUAGuvQ3zPMn5gFgQ6wBjXJDmR85SMcr 5EF2vxhpAwFdWzc3ChDP3tmj9mYHSLbcKBIgOYdLWZN0TTUi4N7WwVUSmABP9HtrMRIa aEnzIyxe+Kys/PNESI9kto1i/w8Sp34b2F+H29XuyJbHywBvdV4iOaE/Vgal/cgJTV7A XaPQwMu7KLbcENTS9clG6Uq8SuDAWSQSWrvNnCXH8wdo2rc2v19se0AIYZgDWWXA70yk nXKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=O3H7BwaFV9b+M5nuulawbeynVX4wPDEukZLHDv42cz0=; fh=MgVHZMmQUm/gRWfyK6lEz60QTv8AGcl71kJIbDjGYms=; b=C9yVEpNByQwc+ybVjp91+SVSuy4N5pMREuzQWqr59OLWukV8qSHviz1jbpsKLjIbyI KD3pGu+6FLQvvLAyI1EQW4R5QCHNoap5tozMTnrNNhjfRqkpnO5A0c8t1nFVPTKxtMbo eE9JiixN8DXJEl7q23JXbAeBTqcJSH2aORjW9XIMVyVUw15cbHq0c9CyeFImAYREjOEE HmxT8DI54h8zxrSH/GVbqAt0RMfOaenSW3w1m1DdzpwxOZJzFZXfmhTNciV8JwStNruc LIKHtlc7bEYSo5zMDWelcTr6zymL0UJ+afjn4r5VBh1XRbyxbHYJ00prx50z9Con8peJ jibw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=X01+Zj2Z; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id by26-20020a056a02059a00b005774978dd75si10879826pgb.175.2023.09.25.04.48.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Sep 2023 04:48:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=X01+Zj2Z; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 293568131C2E; Mon, 25 Sep 2023 04:48:09 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230232AbjIYLsI (ORCPT + 99 others); Mon, 25 Sep 2023 07:48:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37716 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229905AbjIYLsH (ORCPT ); Mon, 25 Sep 2023 07:48:07 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2ADB3DA; Mon, 25 Sep 2023 04:48:00 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0CD65C433C7; Mon, 25 Sep 2023 11:47:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1695642479; bh=ayg5LSBYCOKl5a+6j88Yxa0oPYcMm7YpRHXlMokcXvg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=X01+Zj2ZMU+MKGstqxrUpscxFHm/e4CYLScXBUrDNhleoVE9Z7mMQqJqbSBVXDQdl OvmKv7rV+dlq+NLgUSzkq6yh3l8Uv2td1Lh0OSLPVIyd/r2gK4Gx6MoMYAj6iwOgyw mBnQzn1u8/b77rpZyHOLpy5OzRN3cqfNj1tJFPYQw/8LaxFCZEY2yydkLfHnk0B56y 5E1B3iQv3gJJ2m2EUCWLw/AXMY4NE0cPJoIlU20c4tkSBTL+Xo+vLEDX4WJiD1Xwhp DApOd1l8cHANQTlNMmEjKqa/bvVHx5WR5e3IL2cT8ICqXHw4X6yUd0gfnBD6rZzSJ5 prYRLeMEw7lgg== Date: Mon, 25 Sep 2023 19:47:48 +0800 From: Peter Chen To: =?utf-8?B?TWljaGHFgiBNaXJvc8WCYXc=?= Cc: Greg Kroah-Hartman , Jonathan Hunter , Dmitry Osipenko , Peter Geis , Thierry Reding , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org, linux-usb@vger.kernel.org Subject: Re: [PATCH 3/3] usb: chipidea: tegra: Consistently use dev_err_probe() Message-ID: <20230925114748.GB2070044@nchen-desktop> References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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 pete.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 (pete.vger.email [0.0.0.0]); Mon, 25 Sep 2023 04:48:09 -0700 (PDT) On 23-09-23 21:41:56, Michał Mirosław wrote: > Convert all error exits from probe() to dev_err_probe(). > > Signed-off-by: Michał Mirosław Acked-by: Peter Chen Peter > --- > 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 > -- Thanks, Peter Chen