]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
realtek: 6.12: replace ethtool_eee with ethtool_keee
authorMarkus Stockhausen <markus.stockhausen@gmx.de>
Tue, 27 May 2025 18:35:53 +0000 (14:35 -0400)
committerRobert Marko <robimarko@gmail.com>
Wed, 11 Jun 2025 20:27:22 +0000 (22:27 +0200)
EEE functions are now called with ethtool_keee instead of
ethtool_eee. Replace all occurrences. This will fix function
signature checks but still produces compilation errors due
to structure changes.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/18935
Signed-off-by: Robert Marko <robimarko@gmail.com>
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/dsa.c
target/linux/realtek/files-6.12/drivers/net/phy/rtl83xx-phy.c
target/linux/realtek/patches-6.12/706-include-linux-add-phy-ops-for-rtl838x.patch

index 30be051d3d581fdcc501ebe137e224884f44bf4b..0a542624ed7c72dc04550bb972cb07a6bc338dc3 100644 (file)
@@ -1111,8 +1111,7 @@ static void rtl83xx_port_disable(struct dsa_switch *ds, int port)
        priv->ports[port].enable = false;
 }
 
-static int rtl83xx_set_mac_eee(struct dsa_switch *ds, int port,
-                              struct ethtool_eee *e)
+static int rtl83xx_set_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e)
 {
        struct rtl838x_switch_priv *priv = ds->priv;
 
@@ -1131,8 +1130,7 @@ static int rtl83xx_set_mac_eee(struct dsa_switch *ds, int port,
        return 0;
 }
 
-static int rtl83xx_get_mac_eee(struct dsa_switch *ds, int port,
-                              struct ethtool_eee *e)
+static int rtl83xx_get_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e)
 {
        struct rtl838x_switch_priv *priv = ds->priv;
 
@@ -1147,8 +1145,7 @@ static int rtl83xx_get_mac_eee(struct dsa_switch *ds, int port,
        return 0;
 }
 
-static int rtl93xx_get_mac_eee(struct dsa_switch *ds, int port,
-                              struct ethtool_eee *e)
+static int rtl93xx_get_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e)
 {
        struct rtl838x_switch_priv *priv = ds->priv;
 
index c4a2bac3131077a115cfcc72ffc7dd2a729ecfde..ab8126f82ad2d9ee54bf648a3292428d42ff4fc0 100644 (file)
@@ -630,8 +630,7 @@ out:
        return ret;
 }
 
-static int rtl8226_get_eee(struct phy_device *phydev,
-                          struct ethtool_eee *e)
+static int rtl8226_get_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        u32 val;
        int addr = phydev->mdio.addr;
@@ -651,7 +650,7 @@ static int rtl8226_get_eee(struct phy_device *phydev,
        return 0;
 }
 
-static int rtl8226_set_eee(struct phy_device *phydev, struct ethtool_eee *e)
+static int rtl8226_set_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        int port = phydev->mdio.addr;
        u64 poll_state;
@@ -1182,8 +1181,7 @@ static void rtl8218d_eee_set(struct phy_device *phydev, bool enable)
        phy_write_paged(phydev, RTL821X_PAGE_GPHY, RTL821XEXT_MEDIA_PAGE_SELECT, RTL821X_MEDIA_PAGE_AUTO);
 }
 
-static int rtl8218b_get_eee(struct phy_device *phydev,
-                           struct ethtool_eee *e)
+static int rtl8218b_get_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        u32 val;
        int addr = phydev->mdio.addr;
@@ -1210,8 +1208,7 @@ static int rtl8218b_get_eee(struct phy_device *phydev,
        return 0;
 }
 
-static int rtl8218d_get_eee(struct phy_device *phydev,
-                           struct ethtool_eee *e)
+static int rtl8218d_get_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        u32 val;
        int addr = phydev->mdio.addr;
@@ -1232,8 +1229,7 @@ static int rtl8218d_get_eee(struct phy_device *phydev,
        return 0;
 }
 
-static int rtl8214fc_set_eee(struct phy_device *phydev,
-                            struct ethtool_eee *e)
+static int rtl8214fc_set_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        u32 poll_state;
        int port = phydev->mdio.addr;
@@ -1289,8 +1285,7 @@ static int rtl8214fc_set_eee(struct phy_device *phydev,
        return 0;
 }
 
-static int rtl8214fc_get_eee(struct phy_device *phydev,
-                            struct ethtool_eee *e)
+static int rtl8214fc_get_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        int addr = phydev->mdio.addr;
 
@@ -1303,7 +1298,7 @@ static int rtl8214fc_get_eee(struct phy_device *phydev,
        return rtl8218b_get_eee(phydev, e);
 }
 
-static int rtl8218b_set_eee(struct phy_device *phydev, struct ethtool_eee *e)
+static int rtl8218b_set_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        int port = phydev->mdio.addr;
        u64 poll_state;
@@ -1357,7 +1352,7 @@ static int rtl8218b_set_eee(struct phy_device *phydev, struct ethtool_eee *e)
        return 0;
 }
 
-static int rtl8218d_set_eee(struct phy_device *phydev, struct ethtool_eee *e)
+static int rtl8218d_set_eee(struct phy_device *phydev, struct ethtool_keee *e)
 {
        int addr = phydev->mdio.addr;
        u64 poll_state;
index 3404d55ed3cd5621fd44891f411dfb404d5ddd0a..9a0252ea49219d28d54c608fc8106fe47fde9f7c 100644 (file)
@@ -21,12 +21,12 @@ Submitted-by: John Crispin <john@phrozen.org>
 
 --- a/include/linux/phy.h
 +++ b/include/linux/phy.h
-@@ -1181,6 +1181,8 @@ struct phy_driver {
+@@ -1229,6 +1229,8 @@ struct phy_driver {
         */
        int (*led_polarity_set)(struct phy_device *dev, int index,
                                unsigned long modes);
-+      int (*get_eee)(struct phy_device *dev, struct ethtool_eee *e);
-+      int (*set_eee)(struct phy_device *dev, struct ethtool_eee *e);
++      int (*get_eee)(struct phy_device *dev, struct ethtool_keee *e);
++      int (*set_eee)(struct phy_device *dev, struct ethtool_keee *e);
  };
- #define to_phy_driver(d) container_of(to_mdio_common_driver(d),               \
+ #define to_phy_driver(d) container_of_const(to_mdio_common_driver(d),         \
                                      struct phy_driver, mdiodrv)