725-net-phy-aquantia-add-PHY_IDs-for-AQR112-variants.patch 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. From 3b92ee7b7899b6beffb2b484c58326e36612a873 Mon Sep 17 00:00:00 2001
  2. From: Daniel Golle <[email protected]>
  3. Date: Thu, 23 Dec 2021 14:52:56 +0000
  4. Subject: [PATCH] net: phy: aquantia: add PHY_ID for AQR112R
  5. As advised by Ian Chang this PHY is used in Puzzle devices.
  6. Signed-off-by: Daniel Golle <[email protected]>
  7. ---
  8. drivers/net/phy/aquantia/aquantia_main.c | 10 ++++++++++
  9. 1 file changed, 10 insertions(+)
  10. --- a/drivers/net/phy/aquantia/aquantia_main.c
  11. +++ b/drivers/net/phy/aquantia/aquantia_main.c
  12. @@ -29,6 +29,8 @@
  13. #define PHY_ID_AQR113 0x31c31c40
  14. #define PHY_ID_AQR113C 0x31c31c12
  15. #define PHY_ID_AQR813 0x31c31cb2
  16. +#define PHY_ID_AQR112C 0x03a1b790
  17. +#define PHY_ID_AQR112R 0x31c31d12
  18. #define MDIO_PHYXS_VEND_IF_STATUS 0xe812
  19. #define MDIO_PHYXS_VEND_IF_STATUS_TYPE_MASK GENMASK(7, 3)
  20. @@ -972,6 +974,30 @@ static struct phy_driver aqr_driver[] =
  21. .get_stats = aqr107_get_stats,
  22. .link_change_notify = aqr107_link_change_notify,
  23. },
  24. +{
  25. + PHY_ID_MATCH_MODEL(PHY_ID_AQR112C),
  26. + .name = "Aquantia AQR112C",
  27. + .probe = aqr107_probe,
  28. + .config_aneg = aqr_config_aneg_set_prot,
  29. + .config_intr = aqr_config_intr,
  30. + .handle_interrupt = aqr_handle_interrupt,
  31. + .read_status = aqr107_read_status,
  32. + .get_sset_count = aqr107_get_sset_count,
  33. + .get_strings = aqr107_get_strings,
  34. + .get_stats = aqr107_get_stats,
  35. +},
  36. +{
  37. + PHY_ID_MATCH_MODEL(PHY_ID_AQR112R),
  38. + .name = "Aquantia AQR112R",
  39. + .probe = aqr107_probe,
  40. + .config_aneg = aqr_config_aneg_set_prot,
  41. + .config_intr = aqr_config_intr,
  42. + .handle_interrupt = aqr_handle_interrupt,
  43. + .read_status = aqr107_read_status,
  44. + .get_sset_count = aqr107_get_sset_count,
  45. + .get_strings = aqr107_get_strings,
  46. + .get_stats = aqr107_get_stats,
  47. +},
  48. };
  49. module_phy_driver(aqr_driver);
  50. @@ -991,6 +1017,8 @@ static struct mdio_device_id __maybe_unu
  51. { PHY_ID_MATCH_MODEL(PHY_ID_AQR113) },
  52. { PHY_ID_MATCH_MODEL(PHY_ID_AQR113C) },
  53. { PHY_ID_MATCH_MODEL(PHY_ID_AQR813) },
  54. + { PHY_ID_MATCH_MODEL(PHY_ID_AQR112C) },
  55. + { PHY_ID_MATCH_MODEL(PHY_ID_AQR112R) },
  56. { }
  57. };