2008-08-07 13:13:50

by Roel Kluin

[permalink] [raw]
Subject: [PATCH?] atl1e: WAKE_MCAST 2x. 1st WAKE_UCAST?

untested, is it right?
---
WAKE_MCAST bit tested twice, test WAKE_UCAST first.

Signed-off-by: Roel Kluin <[email protected]>
diff --git a/drivers/net/atl1e/atl1e_ethtool.c b/drivers/net/atl1e/atl1e_ethtool.c
index cdc3b85..619c658 100644
--- a/drivers/net/atl1e/atl1e_ethtool.c
+++ b/drivers/net/atl1e/atl1e_ethtool.c
@@ -355,7 +355,7 @@ static int atl1e_set_wol(struct net_device *netdev, struct ethtool_wolinfo *wol)
struct atl1e_adapter *adapter = netdev_priv(netdev);

if (wol->wolopts & (WAKE_ARP | WAKE_MAGICSECURE |
- WAKE_MCAST | WAKE_BCAST | WAKE_MCAST))
+ WAKE_UCAST | WAKE_MCAST | WAKE_BCAST))
return -EOPNOTSUPP;
/* these settings will always override what we currently have */
adapter->wol = 0;


2008-08-08 01:25:26

by Jie Yang

[permalink] [raw]
Subject: RE: [PATCH?] atl1e: WAKE_MCAST 2x. 1st WAKE_UCAST?

On Friday, August 08, 2008 12:25 AM
roel kluin <[email protected]> wrote:
> untested, is it right?
> ---
> WAKE_MCAST bit tested twice, test WAKE_UCAST first.
>
> Signed-off-by: Roel Kluin <[email protected]> diff --git
> a/drivers/net/atl1e/atl1e_ethtool.c
> b/drivers/net/atl1e/atl1e_ethtool.c
> index cdc3b85..619c658 100644
> --- a/drivers/net/atl1e/atl1e_ethtool.c
> +++ b/drivers/net/atl1e/atl1e_ethtool.c
> @@ -355,7 +355,7 @@ static int atl1e_set_wol(struct
> net_device *netdev, struct ethtool_wolinfo *wol)
> struct atl1e_adapter *adapter = netdev_priv(netdev);
>
> if (wol->wolopts & (WAKE_ARP | WAKE_MAGICSECURE |
> - WAKE_MCAST | WAKE_BCAST | WAKE_MCAST))
> + WAKE_UCAST | WAKE_MCAST | WAKE_BCAST))
> return -EOPNOTSUPP;
> /* these settings will always override what we
> currently have */
> adapter->wol = 0;
>

Yes, It should be this! Thanks!

Best wishes
jie

2008-08-08 03:12:36

by Jie Yang

[permalink] [raw]
Subject: RE: [PATCH?] atl1e: WAKE_MCAST 2x. 1st WAKE_UCAST?

On Friday, August 08, 2008 12:25 AM
roel kluin <[email protected]> wrote

>
> untested, is it right?
> ---
> WAKE_MCAST bit tested twice, test WAKE_UCAST first.
>
> Signed-off-by: Roel Kluin <[email protected]> diff --git
> a/drivers/net/atl1e/atl1e_ethtool.c
> b/drivers/net/atl1e/atl1e_ethtool.c
> index cdc3b85..619c658 100644
> --- a/drivers/net/atl1e/atl1e_ethtool.c
> +++ b/drivers/net/atl1e/atl1e_ethtool.c
> @@ -355,7 +355,7 @@ static int atl1e_set_wol(struct
> net_device *netdev, struct ethtool_wolinfo *wol)
> struct atl1e_adapter *adapter = netdev_priv(netdev);
>
> if (wol->wolopts & (WAKE_ARP | WAKE_MAGICSECURE |
> - WAKE_MCAST | WAKE_BCAST | WAKE_MCAST))
> + WAKE_UCAST | WAKE_MCAST | WAKE_BCAST))
> return -EOPNOTSUPP;
> /* these settings will always override what we
> currently have */
> adapter->wol = 0;
>

Yes, it should be this, thanks!

Acked-by: Jie Yang <[email protected]>

BTW: resend on the comments from Jay Cliburn <[email protected]>

Thanks Jay

2008-08-14 08:45:23

by Jeff Garzik

[permalink] [raw]
Subject: Re: [PATCH?] atl1e: WAKE_MCAST 2x. 1st WAKE_UCAST?

roel kluin wrote:
> untested, is it right?
> ---
> WAKE_MCAST bit tested twice, test WAKE_UCAST first.
>
> Signed-off-by: Roel Kluin <[email protected]>
> diff --git a/drivers/net/atl1e/atl1e_ethtool.c b/drivers/net/atl1e/atl1e_ethtool.c
> index cdc3b85..619c658 100644
> --- a/drivers/net/atl1e/atl1e_ethtool.c
> +++ b/drivers/net/atl1e/atl1e_ethtool.c
> @@ -355,7 +355,7 @@ static int atl1e_set_wol(struct net_device *netdev, struct ethtool_wolinfo *wol)
> struct atl1e_adapter *adapter = netdev_priv(netdev);
>
> if (wol->wolopts & (WAKE_ARP | WAKE_MAGICSECURE |
> - WAKE_MCAST | WAKE_BCAST | WAKE_MCAST))
> + WAKE_UCAST | WAKE_MCAST | WAKE_BCAST))
> return -EOPNOTSUPP;
> /* these settings will always override what we currently have */

applied