707-v6.8-10-net-phy-at803x-make-at8031-related-DT-functions-name.patch 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. From a5ab9d8e7ae0da8328ac1637a9755311508dc8ab Mon Sep 17 00:00:00 2001
  2. From: Christian Marangi <[email protected]>
  3. Date: Fri, 8 Dec 2023 15:51:57 +0100
  4. Subject: [PATCH 10/13] net: phy: at803x: make at8031 related DT functions name
  5. more specific
  6. Rename at8031 related DT function name to a more specific name
  7. referencing they are only related to at8031 and not to the generic
  8. at803x PHY family.
  9. Signed-off-by: Christian Marangi <[email protected]>
  10. Signed-off-by: David S. Miller <[email protected]>
  11. ---
  12. drivers/net/phy/at803x.c | 16 ++++++++--------
  13. 1 file changed, 8 insertions(+), 8 deletions(-)
  14. --- a/drivers/net/phy/at803x.c
  15. +++ b/drivers/net/phy/at803x.c
  16. @@ -583,7 +583,7 @@ static int at803x_resume(struct phy_devi
  17. return phy_modify(phydev, MII_BMCR, BMCR_PDOWN | BMCR_ISOLATE, 0);
  18. }
  19. -static int at803x_rgmii_reg_set_voltage_sel(struct regulator_dev *rdev,
  20. +static int at8031_rgmii_reg_set_voltage_sel(struct regulator_dev *rdev,
  21. unsigned int selector)
  22. {
  23. struct phy_device *phydev = rdev_get_drvdata(rdev);
  24. @@ -596,7 +596,7 @@ static int at803x_rgmii_reg_set_voltage_
  25. AT803X_DEBUG_RGMII_1V8, 0);
  26. }
  27. -static int at803x_rgmii_reg_get_voltage_sel(struct regulator_dev *rdev)
  28. +static int at8031_rgmii_reg_get_voltage_sel(struct regulator_dev *rdev)
  29. {
  30. struct phy_device *phydev = rdev_get_drvdata(rdev);
  31. int val;
  32. @@ -610,8 +610,8 @@ static int at803x_rgmii_reg_get_voltage_
  33. static const struct regulator_ops vddio_regulator_ops = {
  34. .list_voltage = regulator_list_voltage_table,
  35. - .set_voltage_sel = at803x_rgmii_reg_set_voltage_sel,
  36. - .get_voltage_sel = at803x_rgmii_reg_get_voltage_sel,
  37. + .set_voltage_sel = at8031_rgmii_reg_set_voltage_sel,
  38. + .get_voltage_sel = at8031_rgmii_reg_get_voltage_sel,
  39. };
  40. static const unsigned int vddio_voltage_table[] = {
  41. @@ -666,7 +666,7 @@ static int at8031_register_regulators(st
  42. return 0;
  43. }
  44. -static int at803x_sfp_insert(void *upstream, const struct sfp_eeprom_id *id)
  45. +static int at8031_sfp_insert(void *upstream, const struct sfp_eeprom_id *id)
  46. {
  47. struct phy_device *phydev = upstream;
  48. __ETHTOOL_DECLARE_LINK_MODE_MASK(phy_support);
  49. @@ -710,10 +710,10 @@ static int at803x_sfp_insert(void *upstr
  50. return 0;
  51. }
  52. -static const struct sfp_upstream_ops at803x_sfp_ops = {
  53. +static const struct sfp_upstream_ops at8031_sfp_ops = {
  54. .attach = phy_sfp_attach,
  55. .detach = phy_sfp_detach,
  56. - .module_insert = at803x_sfp_insert,
  57. + .module_insert = at8031_sfp_insert,
  58. };
  59. static int at803x_parse_dt(struct phy_device *phydev)
  60. @@ -1519,7 +1519,7 @@ static int at8031_parse_dt(struct phy_de
  61. }
  62. /* Only AR8031/8033 support 1000Base-X for SFP modules */
  63. - return phy_sfp_probe(phydev, &at803x_sfp_ops);
  64. + return phy_sfp_probe(phydev, &at8031_sfp_ops);
  65. }
  66. static int at8031_probe(struct phy_device *phydev)