701-v6.2-0008-net-dpaa2-switch-replace-direct-MAC-access-with-dpaa.patch 1.0 KB

12345678910111213141516171819202122232425262728
  1. From c838d9fd7e6ba9ddd6006bf0a296396266e9f121 Mon Sep 17 00:00:00 2001
  2. From: Vladimir Oltean <[email protected]>
  3. Date: Tue, 29 Nov 2022 16:12:17 +0200
  4. Subject: [PATCH 10/14] net: dpaa2-switch replace direct MAC access with
  5. dpaa2_switch_port_has_mac()
  6. The helper function will gain a lockdep annotation in a future patch.
  7. Make sure to benefit from it.
  8. Signed-off-by: Vladimir Oltean <[email protected]>
  9. Reviewed-by: Ioana Ciornei <[email protected]>
  10. Tested-by: Ioana Ciornei <[email protected]>
  11. Signed-off-by: Paolo Abeni <[email protected]>
  12. ---
  13. drivers/net/ethernet/freescale/dpaa2/dpaa2-switch-ethtool.c | 2 +-
  14. 1 file changed, 1 insertion(+), 1 deletion(-)
  15. --- a/drivers/net/ethernet/freescale/dpaa2/dpaa2-switch-ethtool.c
  16. +++ b/drivers/net/ethernet/freescale/dpaa2/dpaa2-switch-ethtool.c
  17. @@ -189,7 +189,7 @@ static void dpaa2_switch_ethtool_get_sta
  18. dpaa2_switch_ethtool_counters[i].name, err);
  19. }
  20. - if (port_priv->mac)
  21. + if (dpaa2_switch_port_has_mac(port_priv))
  22. dpaa2_mac_get_ethtool_stats(port_priv->mac, data + i);
  23. }