Thread (8 messages) flat view 8 messages, 3 authors, 2011-12-17

Re: drivers/net/usb/asix: bug in asix_get_wol

From: Grant Grundler <hidden>
Date: 2011-12-16 22:16:00

On Thu, Dec 15, 2011 at 9:15 PM, ASIX Allan Email [office]
[off-list ref] wrote:
Resend without attachment due to below email server error.
...
-----Original Message-----
From: ASIX Allan Email [office] [mailto:allan@asix.com.tw]
Sent: Friday, December 16, 2011 11:38 AM
To: 'Grant Grundler'; 'Eugene'
Cc: 'netdev@vger.kernel.org'; 'Freddy Xin'; ASIX Louis [蘇威陸]
Subject: RE: drivers/net/usb/asix: bug in asix_get_wol
Importance: High

Dear Grant and Eugene,

Please refer to the attached file and below statements to modify the
asix_get_wol() routine and let us know if this suggestion can solve
your issues or not? Thanks a lot.
Allan,
Thanks for the response but it doesn't answer my previous question.
Let me ask the same question differently.

Does WOL support in asix driver need more than the four lines of code?
Ie does MONITOR_MODE need to be enabled or anything like that?
================
static void
asix_get_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo)
{
       struct usbnet *dev = netdev_priv(net);
       u8 opt;

       if (asix_read_cmd(dev, AX_CMD_READ_MONITOR_MODE, 0, 0, 1, &opt) < 0) {
               wolinfo->supported = 0;
               wolinfo->wolopts = 0;
               return;
       }
       wolinfo->supported = WAKE_PHY | WAKE_MAGIC;
       wolinfo->wolopts = 0;
       if (opt & AX_MONITOR_LINK)
               wolinfo->wolopts |= WAKE_PHY;
       if (opt & AX_MONITOR_MAGIC)
               wolinfo->wolopts |= WAKE_MAGIC;
}
This looks remarkably similar to the code Eugene said enables WOL for
him (and it works). I not able to find any difference.

If you believe it was a mistake to remove these four lines of code,
please submit a patch (See Documentation/SubmittingPatches)  to add
them back. You can add a "Tested-by: Eugene [off-list ref]"
line after your own "Signed-off-by:" in the patch.

thanks!
grant
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help