From: Marc Dietrich <marvin24@gmx.de>
To: Dan Carpenter <dan.carpenter@oracle.com>,
gregkh@linuxfoundation.org, linux-tegra@vger.kernel.org
Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org,
Sakshi Bansal <sakshi.april5@gmail.com>
Subject: Re: [PATCH] staging: nvec: fixed few coding style warnings
Date: Thu, 15 Oct 2015 10:39:02 +0200 [thread overview]
Message-ID: <1971511.Ec7FdKlGRN@fb07-iapwap2> (raw)
In-Reply-To: <20151014181236.GX7340@mwanda>
[-- Attachment #1.1: Type: text/plain, Size: 749 bytes --]
Am Mittwoch, 14. Oktober 2015, 21:12:36 schrieb Dan Carpenter:
> On Wed, Oct 14, 2015 at 07:38:22PM +0530, Sakshi Bansal wrote:
> > Fixed allignmnet issues and block comments usage
>
> Split it apart by type of fix.
>
> > @@ -617,7 +618,7 @@ static irqreturn_t nvec_interrupt(int irq, void *dev)
> >
> > } else {
> >
> > nvec->rx = nvec_msg_alloc(nvec, NVEC_MSG_RX);
> > /* Should not happen in a normal world */
> >
> > - if (unlikely(nvec->rx == NULL)) {
> > + if (!unlikely(nvec->rx)) {
>
> This isn't right. You intented to say:
>
> if (unlikely(!nvec->rx)) {
>
> But even better to just remove the unlikely entirely.
>
> if (!nvec->rx) {
why? the "unlikely" is there to optimize a critical interrupt path.
Marc
[-- Attachment #1.2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
[-- Attachment #2: Type: text/plain, Size: 169 bytes --]
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
WARNING: multiple messages have this Message-ID (diff)
From: Marc Dietrich <marvin24@gmx.de>
To: Dan Carpenter <dan.carpenter@oracle.com>,
gregkh@linuxfoundation.org, linux-tegra@vger.kernel.org
Cc: Sakshi Bansal <sakshi.april5@gmail.com>,
devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: nvec: fixed few coding style warnings
Date: Thu, 15 Oct 2015 10:39:02 +0200 [thread overview]
Message-ID: <1971511.Ec7FdKlGRN@fb07-iapwap2> (raw)
In-Reply-To: <20151014181236.GX7340@mwanda>
[-- Attachment #1: Type: text/plain, Size: 749 bytes --]
Am Mittwoch, 14. Oktober 2015, 21:12:36 schrieb Dan Carpenter:
> On Wed, Oct 14, 2015 at 07:38:22PM +0530, Sakshi Bansal wrote:
> > Fixed allignmnet issues and block comments usage
>
> Split it apart by type of fix.
>
> > @@ -617,7 +618,7 @@ static irqreturn_t nvec_interrupt(int irq, void *dev)
> >
> > } else {
> >
> > nvec->rx = nvec_msg_alloc(nvec, NVEC_MSG_RX);
> > /* Should not happen in a normal world */
> >
> > - if (unlikely(nvec->rx == NULL)) {
> > + if (!unlikely(nvec->rx)) {
>
> This isn't right. You intented to say:
>
> if (unlikely(!nvec->rx)) {
>
> But even better to just remove the unlikely entirely.
>
> if (!nvec->rx) {
why? the "unlikely" is there to optimize a critical interrupt path.
Marc
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
next prev parent reply other threads:[~2015-10-15 8:39 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-14 14:08 [PATCH] staging: nvec: fixed few coding style warnings Sakshi Bansal
2015-10-14 18:12 ` Dan Carpenter
2015-10-14 18:12 ` Dan Carpenter
2015-10-15 8:39 ` Marc Dietrich [this message]
2015-10-15 8:39 ` Marc Dietrich
2015-10-15 8:48 ` Dan Carpenter
2015-10-15 8:48 ` Dan Carpenter
2015-10-15 9:15 ` Marc Dietrich
2015-10-15 9:15 ` Marc Dietrich
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=1971511.Ec7FdKlGRN@fb07-iapwap2 \
--to=marvin24@gmx.de \
--cc=dan.carpenter@oracle.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=sakshi.april5@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.