From: Felipe Balbi <balbi-l0cyMroinI0@public.gmane.org>
To: Sergei Shtylyov <sshtylyov-Igf4POYTYCDQT0dZR+AlfA@public.gmane.org>
Cc: Shubhrajyoti D <shubhrajyoti-l0cyMroinI0@public.gmane.org>,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
balbi-l0cyMroinI0@public.gmane.org,
Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org>
Subject: Re: [PATCH RFC] usb: musb: omap: fix the error check for pm_runtime_get_sync
Date: Thu, 22 Mar 2012 14:55:51 +0200 [thread overview]
Message-ID: <20120322125550.GG32368@arwen.pp.htv.fi> (raw)
In-Reply-To: <4F6B1E2D.8020802-Igf4POYTYCDQT0dZR+AlfA@public.gmane.org>
[-- Attachment #1: Type: text/plain, Size: 1429 bytes --]
On Thu, Mar 22, 2012 at 04:42:21PM +0400, Sergei Shtylyov wrote:
> Hello.
>
> On 22-03-2012 11:18, Shubhrajyoti D wrote:
>
> >pm_runtime_get_sync returns a signed integer.In case of errors
> >it returns a negative value.This patch fixes the error check
> >by making it signed instead of unsigned thus preventing register
> >access if get_sync_fails. Also passes the error cause to the
> >debug message.
>
> >Cc: Kishon Vijay Abraham I<kishon-l0cyMroinI0@public.gmane.org>
> >Signed-off-by: Shubhrajyoti D<shubhrajyoti-l0cyMroinI0@public.gmane.org>
> >---
> >Compile tested only
>
> You haven't run it thru scripts/checkpatch.pl either, I guess?
>
> > drivers/usb/musb/omap2430.c | 5 +++--
> > 1 files changed, 3 insertions(+), 2 deletions(-)
>
> >diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c
> >index 2ae0bb3..e5dd18f 100644
> >--- a/drivers/usb/musb/omap2430.c
> >+++ b/drivers/usb/musb/omap2430.c
> [...]
> >@@ -301,7 +302,7 @@ static int omap2430_musb_init(struct musb *musb)
> >
> > status = pm_runtime_get_sync(dev);
> > if (status< 0) {
> >- dev_err(dev, "pm_runtime_get_sync FAILED");
> >+ dev_err(dev, "pm_runtime_get_sync FAILED %d \n",status);
>
> If I don't mistake, scripts/checkpatch.pl should warn about
> unneeded spaces before '\n'. And also about missing spaces after
> commas.
I fixed in my branch, thanks
--
balbi
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2012-03-22 12:55 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-22 7:18 [PATCH RFC] usb: musb: omap: fix the error check for pm_runtime_get_sync Shubhrajyoti D
[not found] ` <1332400686-27674-1-git-send-email-shubhrajyoti-l0cyMroinI0@public.gmane.org>
2012-03-22 8:09 ` Felipe Balbi
2012-03-22 12:42 ` Sergei Shtylyov
[not found] ` <4F6B1E2D.8020802-Igf4POYTYCDQT0dZR+AlfA@public.gmane.org>
2012-03-22 12:55 ` Felipe Balbi [this message]
2012-03-22 13:36 ` Shubhrajyoti
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=20120322125550.GG32368@arwen.pp.htv.fi \
--to=balbi-l0cymroini0@public.gmane.org \
--cc=kishon-l0cyMroinI0@public.gmane.org \
--cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=shubhrajyoti-l0cyMroinI0@public.gmane.org \
--cc=sshtylyov-Igf4POYTYCDQT0dZR+AlfA@public.gmane.org \
/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