From: "Michał Mirosław" <mirqus@gmail.com>
To: Mahesh Bandewar <maheshb@google.com>
Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>,
e1000-devel <e1000-devel@lists.sourceforge.net>,
David Miller <davem@davemloft.net>,
netdev <netdev@vger.kernel.org>,
Tom Herbert <therbert@google.com>
Subject: Re: [PATCHv1] e1000e: Allow ethtool to enable/disable loopback.
Date: Wed, 11 May 2011 21:15:49 +0200 [thread overview]
Message-ID: <BANLkTikXbL2arWSYW1aPV02C8dDdHTUG6Q@mail.gmail.com> (raw)
In-Reply-To: <1305140625-25888-1-git-send-email-maheshb@google.com>
2011/5/11 Mahesh Bandewar <maheshb@google.com>:
> This patch adds e1000_set_features() to handle loopback mode. When loopback
> is enabled, it enables internal-MAC loopback.
Please wait for this driver's conversion to hw_features. One comment
below, though.
[...]
> --- a/drivers/net/e1000e/netdev.c
> +++ b/drivers/net/e1000e/netdev.c
[...]
> +static int e1000_set_features(struct net_device *dev, u32 features)
> +{
> + u32 changed = dev->features ^ features;
> +
> + if ((changed & NETIF_F_LOOPBACK) && netif_running(dev))
> + e1000_set_loopback(dev, features);
> +
> + return 0;
> +}
[...]
If e1000_set_loopback() fails, this should set dev->features to passed
features (but keeping NETIF_F_LOOPBACK unchanged in dev->features) to
keep the state consistent.
Best Regards,
Michał Mirosław
next prev parent reply other threads:[~2011-05-11 19:16 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-11 19:03 [PATCHv1] e1000e: Allow ethtool to enable/disable loopback Mahesh Bandewar
2011-05-11 19:15 ` Michał Mirosław [this message]
2011-05-11 23:11 ` Mahesh Bandewar
2011-05-12 4:45 ` David Miller
2011-05-12 5:50 ` Michał Mirosław
2011-05-12 21:41 ` Mahesh Bandewar
2011-05-13 7:49 ` Michał Mirosław
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=BANLkTikXbL2arWSYW1aPV02C8dDdHTUG6Q@mail.gmail.com \
--to=mirqus@gmail.com \
--cc=davem@davemloft.net \
--cc=e1000-devel@lists.sourceforge.net \
--cc=jeffrey.t.kirsher@intel.com \
--cc=maheshb@google.com \
--cc=netdev@vger.kernel.org \
--cc=therbert@google.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).