netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: stephen@networkplumber.org
Cc: netdev@vger.kernel.org, sebastian.poehn@belden.com
Subject: Re: [Bug 79821] New: ethernet/freescale/gianfar_ethtool.c:1584: possible bad expression ?
Date: Thu, 10 Jul 2014 17:06:10 -0700 (PDT)	[thread overview]
Message-ID: <20140710.170610.787241466056112359.davem@davemloft.net> (raw)
In-Reply-To: <20140710055100.394e6a09@samsung-9>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Thu, 10 Jul 2014 05:51:00 -0700

> [linux-3.16-rc4/drivers/net/ethernet/freescale/gianfar_ethtool.c:1584]: (style)
> Same expression on both sides of '|'.
> 
>     for (; i < MAX_FILER_IDX - 1 && (tab->fe[i].ctrl | tab->fe[i].ctrl);

Probably this is meant to be:

diff --git a/drivers/net/ethernet/freescale/gianfar_ethtool.c b/drivers/net/ethernet/freescale/gianfar_ethtool.c
index 76d7070..f697118 100644
--- a/drivers/net/ethernet/freescale/gianfar_ethtool.c
+++ b/drivers/net/ethernet/freescale/gianfar_ethtool.c
@@ -1581,7 +1581,7 @@ static int gfar_write_filer_table(struct gfar_private *priv,
 		return -EBUSY;
 
 	/* Fill regular entries */
-	for (; i < MAX_FILER_IDX - 1 && (tab->fe[i].ctrl | tab->fe[i].ctrl);
+	for (; i < MAX_FILER_IDX - 1 && (tab->fe[i].ctrl | tab->fe[i].prop);
 	     i++)
 		gfar_write_filer(priv, i, tab->fe[i].ctrl, tab->fe[i].prop);
 	/* Fill the rest with fall-troughs */

But only a Gianfar expert can say for sure.

Sebastian, this is your code, please help us out.

  reply	other threads:[~2014-07-11  0:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-10 12:51 Fw: [Bug 79821] New: ethernet/freescale/gianfar_ethtool.c:1584: possible bad expression ? Stephen Hemminger
2014-07-11  0:06 ` David Miller [this message]
2014-07-11  0:07   ` David Miller
2014-07-11  0:37     ` Fabio Estevam
2014-07-11  8:54       ` Claudiu Manoil

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=20140710.170610.787241466056112359.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=sebastian.poehn@belden.com \
    --cc=stephen@networkplumber.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;
as well as URLs for NNTP newsgroup(s).