From: "Randy.Dunlap" <rddunlap@osdl.org>
To: Ganesh Venkatesan <ganesh.venkatesan@intel.com>
Cc: "jgarzik@pobox.com" <jgarzik@pobox.com>, netdev <netdev@oss.sgi.com>
Subject: Re: [PATCH netdev-2.6 8/10] ixgb: Ethtool_ops support
Date: Fri, 29 Oct 2004 08:25:47 -0700 [thread overview]
Message-ID: <418260FB.4080807@osdl.org> (raw)
In-Reply-To: <Pine.LNX.4.44.0410290500450.26064-100000@isotope.jf.intel.com>
> +
> + if(netif_running(adapter->netdev)) {
> ixgb_down(adapter, TRUE);
> + ixgb_reset(adapter);
> ixgb_up(adapter);
> - }
_Many_ cases where "if(" should be "if (" (same for "for").
> +static int
> +ixgb_get_regs_len(struct net_device *netdev)
> +{
> +#define IXGB_REG_DUMP_LEN 136*sizeof(uint32_t)
> + return IXGB_REG_DUMP_LEN;
> +}
Might as well #undef this constant if you want it to be "local".
There are several places where an if () also does an assignment
without doing a comparison. sparse will beep/gong on those.
Have you tried sparse? E.g.:
+ if((err = ixgb_up(adapter)))
+ return err;
Instead of using double parens to appease gcc, do this:
if ((err = ixgb_up(adapter) != 0)
return err;
--
~Randy
prev parent reply other threads:[~2004-10-29 15:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-29 12:12 [PATCH netdev-2.6 8/10] ixgb: Ethtool_ops support Ganesh Venkatesan
2004-10-29 15:25 ` Randy.Dunlap [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=418260FB.4080807@osdl.org \
--to=rddunlap@osdl.org \
--cc=ganesh.venkatesan@intel.com \
--cc=jgarzik@pobox.com \
--cc=netdev@oss.sgi.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;
as well as URLs for NNTP newsgroup(s).