7226-dpaa_eth-fix-adjust_link-for-10G-2.5G.patch 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. From 09a3bd3bb7e59703bfa5fa580436b4a85b15cfb0 Mon Sep 17 00:00:00 2001
  2. From: Shaohui Xie <Shaohui.Xie@nxp.com>
  3. Date: Fri, 22 Apr 2016 11:26:14 +0800
  4. Subject: [PATCH] dpaa_eth: fix adjust_link for 10G & 2.5G
  5. We don't support adjust link for 10G & 2.5G.
  6. Signed-off-by: Shaohui Xie <Shaohui.Xie@nxp.com>
  7. ---
  8. drivers/net/ethernet/freescale/sdk_dpaa/mac-api.c | 8 ++++++--
  9. 1 file changed, 6 insertions(+), 2 deletions(-)
  10. --- a/drivers/net/ethernet/freescale/sdk_dpaa/mac-api.c
  11. +++ b/drivers/net/ethernet/freescale/sdk_dpaa/mac-api.c
  12. @@ -409,6 +409,10 @@ void get_pause_cfg(struct mac_device *ma
  13. }
  14. EXPORT_SYMBOL(get_pause_cfg);
  15. +static void adjust_link_void(struct net_device *net_dev)
  16. +{
  17. +}
  18. +
  19. static void adjust_link(struct net_device *net_dev)
  20. {
  21. struct dpa_priv_s *priv = netdev_priv(net_dev);
  22. @@ -473,7 +477,7 @@ static int xgmac_init_phy(struct net_dev
  23. mac_dev->phy_if);
  24. else
  25. phy_dev = of_phy_connect(net_dev, mac_dev->phy_node,
  26. - &adjust_link, 0, mac_dev->phy_if);
  27. + &adjust_link_void, 0, mac_dev->phy_if);
  28. if (unlikely(phy_dev == NULL) || IS_ERR(phy_dev)) {
  29. netdev_err(net_dev, "Could not attach to PHY %s\n",
  30. mac_dev->phy_node ?
  31. @@ -506,7 +510,7 @@ static int memac_init_phy(struct net_dev
  32. return 0;
  33. } else
  34. phy_dev = of_phy_connect(net_dev, mac_dev->phy_node,
  35. - &adjust_link, 0,
  36. + &adjust_link_void, 0,
  37. mac_dev->phy_if);
  38. } else {
  39. if (!mac_dev->phy_node)