From: Stephen Warren <swarren@wwwdotorg.org>
To: Venu Byravarasu <vbyravarasu@nvidia.com>
Cc: balbi@ti.com, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org
Subject: Re: [PATCH] usb: host: tegra: code clean up
Date: Wed, 12 Sep 2012 12:11:00 -0600 [thread overview]
Message-ID: <5050D034.7030203@wwwdotorg.org> (raw)
In-Reply-To: <1347433362-4669-1-git-send-email-vbyravarasu@nvidia.com>
On 09/12/2012 01:02 AM, Venu Byravarasu wrote:
> As part of code clean up, used devm counterparts for the APIs
> possible.
Almost all of this patch has already been applied as:
bc2ff98 drivers/usb/host/ehci-tegra.c: use devm_ functions
(btw, that patch has a much better patch subject than this one)
The only additions in your patch are shown below, and those changes
should indeed be a separate patch.
> diff --git a/drivers/usb/host/ehci-tegra.c b/drivers/usb/host/ehci-tegra.c
> index 6223d17..dba9f07 100644
> --- a/drivers/usb/host/ehci-tegra.c
> +++ b/drivers/usb/host/ehci-tegra.c
> @@ -701,7 +701,7 @@ static int tegra_ehci_probe(struct platform_device *pdev)
> break;
> default:
> err = -ENODEV;
> - dev_err(&pdev->dev, "unknown usb instance\n");
> + dev_err(&pdev->dev, "unknown usb inst:%d\n", instance);
> goto fail_io;
> }
> }
> @@ -744,7 +744,7 @@ static int tegra_ehci_probe(struct platform_device *pdev)
>
> err = usb_add_hcd(hcd, irq, IRQF_SHARED);
> if (err) {
> - dev_err(&pdev->dev, "Failed to add USB HCD\n");
> + dev_err(&pdev->dev, "usb_add_hcd failed with err 0x%x\n", err);
> goto fail;
> }
>
> @@ -753,7 +753,7 @@ static int tegra_ehci_probe(struct platform_device *pdev)
>
> /* Don't skip the pm_runtime_forbid call if wakeup isn't working */
> /* if (!pdata->power_down_on_bus_suspend) */
> - pm_runtime_forbid(&pdev->dev);
> + pm_runtime_forbid(&pdev->dev);
> pm_runtime_enable(&pdev->dev);
> pm_runtime_put_sync(&pdev->dev);
> return err;
I'm not sure that last change is worth making; hopefully, you'll fix the
bug the causes the "if" to be commented out, and we can re-enabled it
again. Removing the indent makes it much less obvious which lines of
code the "if" was intended to cover.
next prev parent reply other threads:[~2012-09-12 18:11 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-12 7:02 Venu Byravarasu
2012-09-12 13:51 ` Felipe Balbi
2012-09-12 18:11 ` Stephen Warren [this message]
2012-09-13 3:42 ` Venu Byravarasu
2012-09-13 4:50 ` Stephen Warren
-- strict thread matches above, loose matches on Subject: below --
2012-04-05 5:55 Venu Byravarasu
2012-04-05 14:03 ` Alan Stern
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5050D034.7030203@wwwdotorg.org \
--to=swarren@wwwdotorg.org \
--cc=balbi@ti.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=vbyravarasu@nvidia.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome