From: Dan Carpenter <dan.carpenter@oracle.com>
To: navin patidar <navinp@cdac.in>
Cc: gregkh@linuxfoundation.org, mfm@muteddisk.com,
devel@driverdev.osuosl.org, linux-usb@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] staging: usbip: stub_main: correctly handle return value
Date: Tue, 10 Sep 2013 23:47:59 +0300 [thread overview]
Message-ID: <20130910204759.GA6329@mwanda> (raw)
In-Reply-To: <1378790047-3530-1-git-send-email-navinp@cdac.in>
On Tue, Sep 10, 2013 at 10:44:07AM +0530, navin patidar wrote:
> ret == 0 means success, anything else is failure.
>
Hopefully, it's only returning negative error codes. Otherwise it needs
a different fix.
There isn't an official kernel style on if "if (ret < 0)" is better than
"if (ret)". Some subsystems have a preference but most don't care.
It's up to the maintainer to choose.
Your patch is fine, but the changelog is misleading. It should just say
"I prefer the other style" instead of "This code is wrong and has buggy
error handling".
regards,
dan carpenter
prev parent reply other threads:[~2013-09-10 20:51 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-10 5:14 [PATCH 1/3] staging: usbip: stub_main: correctly handle return value navin patidar
2013-09-10 20:47 ` Dan Carpenter [this message]
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=20130910204759.GA6329@mwanda \
--to=dan.carpenter@oracle.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mfm@muteddisk.com \
--cc=navinp@cdac.in \
/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