In message: [linux-yocto] [linux-yocto-dev standard/xlnx-soc][PATCH] net: macb: 
drop wol modifications from upstream
on 15/07/2020 [email protected] wrote:

> From: Quanyang Wang <[email protected]>
> 
> The v5.8-rc5 kernel applies the commit 253fe0943504 ("net: macb: fix
> macb_get/set_wol() when moving to phylink") and the commit ced4799d0637
> ("net: macb: mark device wake capable when magic-packet property present")
> on the magic packet WOL feature of macb. But in the SDK commit 88abc38a8b99
> ("net: macb: Use WOL via ARP"), the magic packet WOL support is removed and
> using ARP WOL instead.


I wondered about this. But leaving the functions in place shouldn't
be a problem if they aren't actually called. It leaves a route back
to a more standard implementation in the future. Or are they actually
causing a build failure ?

Either either way, I've merged the patch .. I was just looking for
more information for future merges when similar conflicts pop up
again.

> 
> So drop these 2 upstream patches from xlnx-soc branch.
> 
> Signed-off-by: Quanyang Wang <[email protected]>
> ---
>  drivers/net/ethernet/cadence/macb_main.c | 50 ------------------------
>  1 file changed, 50 deletions(-)
> 
> diff --git a/drivers/net/ethernet/cadence/macb_main.c 
> b/drivers/net/ethernet/cadence/macb_main.c
> index 2f7a9dcf9060..69c5f267625f 100644
> --- a/drivers/net/ethernet/cadence/macb_main.c
> +++ b/drivers/net/ethernet/cadence/macb_main.c
> @@ -2932,46 +2932,6 @@ static void macb_get_regs(struct net_device *dev, 
> struct ethtool_regs *regs,
>               regs_buff[13] = gem_readl(bp, DMACFG);
>  }
>  
> -static void macb_get_wol(struct net_device *netdev, struct ethtool_wolinfo 
> *wol)
> -{
> -     struct macb *bp = netdev_priv(netdev);
> -
> -     if (bp->wol & MACB_WOL_HAS_MAGIC_PACKET) {
> -             phylink_ethtool_get_wol(bp->phylink, wol);
> -             wol->supported |= WAKE_MAGIC;
> -
> -             if (bp->wol & MACB_WOL_ENABLED)
> -                     wol->wolopts |= WAKE_MAGIC;
> -     }
> -}
> -
> -static int macb_set_wol(struct net_device *netdev, struct ethtool_wolinfo 
> *wol)
> -{
> -     struct macb *bp = netdev_priv(netdev);
> -     int ret;
> -
> -     /* Pass the order to phylink layer */
> -     ret = phylink_ethtool_set_wol(bp->phylink, wol);
> -     /* Don't manage WoL on MAC if handled by the PHY
> -      * or if there's a failure in talking to the PHY
> -      */
> -     if (!ret || ret != -EOPNOTSUPP)
> -             return ret;
> -
> -     if (!(bp->wol & MACB_WOL_HAS_MAGIC_PACKET) ||
> -         (wol->wolopts & ~WAKE_MAGIC))
> -             return -EOPNOTSUPP;
> -
> -     if (wol->wolopts & WAKE_MAGIC)
> -             bp->wol |= MACB_WOL_ENABLED;
> -     else
> -             bp->wol &= ~MACB_WOL_ENABLED;
> -
> -     device_set_wakeup_enable(&bp->pdev->dev, bp->wol & MACB_WOL_ENABLED);
> -
> -     return 0;
> -}
> -
>  static int macb_get_link_ksettings(struct net_device *netdev,
>                                  struct ethtool_link_ksettings *kset)
>  {
> @@ -4574,17 +4534,7 @@ static int macb_probe(struct platform_device *pdev)
>       bp->tx_clk = tx_clk;
>       bp->rx_clk = rx_clk;
>       bp->tsu_clk = tsu_clk;
> -<<<<<<< HEAD
>       bp->jumbo_max_len = macb_config->jumbo_max_len;
> -=======
> -     if (macb_config)
> -             bp->jumbo_max_len = macb_config->jumbo_max_len;
> -
> -     bp->wol = 0;
> -     if (of_get_property(np, "magic-packet", NULL))
> -             bp->wol |= MACB_WOL_HAS_MAGIC_PACKET;
> -     device_set_wakeup_capable(&pdev->dev, bp->wol & 
> MACB_WOL_HAS_MAGIC_PACKET);
> ->>>>>>> standard/base

That should have never slipped in. I swear that I fixed it, but I can see
that I didn't actually commit the file.

Thanks for catching it, and fixing it up!

Bruce

>  
>       spin_lock_init(&bp->lock);
>  
> -- 
> 2.17.1
> 
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#8836): 
https://lists.yoctoproject.org/g/linux-yocto/message/8836
Mute This Topic: https://lists.yoctoproject.org/mt/75513918/21656
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub  
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to