]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
realtek: pcs: rename 'determine_hw_mode' to 'select_hw_mode'
authorJonas Jelonek <jelonek.jonas@gmail.com>
Sun, 21 Jun 2026 14:41:06 +0000 (14:41 +0000)
committerJonas Jelonek <jelonek.jonas@gmail.com>
Mon, 22 Jun 2026 11:02:06 +0000 (13:02 +0200)
Rename the 'determine_hw_mode' to 'select_hw_mode' to better express
what the function does. Based on the requested interface, the number of
links on a SerDes and the capabilities, it selects a suitable hardware
mode. 'determine' is clunkier and less expressive in this case.

Link: https://github.com/openwrt/openwrt/pull/23904
Signed-off-by: Jonas Jelonek <jelonek.jonas@gmail.com>
target/linux/realtek/files-6.18/drivers/net/pcs/pcs-rtl-otto.c

index 627abb65ab1c4a3b1a4ea670ec635870795e5584..0cab0af37d11fcbd09dc3b2130df9c811e3cc8c9 100644 (file)
@@ -450,9 +450,8 @@ static struct rtpcs_link *rtpcs_phylink_pcs_to_link(struct phylink_pcs *pcs)
        return container_of(pcs, struct rtpcs_link, pcs);
 }
 
-static int rtpcs_sds_determine_hw_mode(struct rtpcs_serdes *sds,
-                                       phy_interface_t if_mode,
-                                       enum rtpcs_sds_mode *hw_mode)
+static int rtpcs_sds_select_hw_mode(struct rtpcs_serdes *sds, phy_interface_t if_mode,
+                                   enum rtpcs_sds_mode *hw_mode)
 {
        u8 n_links = sds->num_of_links;
 
@@ -4032,7 +4031,7 @@ static int rtpcs_pcs_config(struct phylink_pcs *pcs, unsigned int neg_mode,
        enum rtpcs_sds_mode hw_mode;
        int ret;
 
-       ret = rtpcs_sds_determine_hw_mode(sds, interface, &hw_mode);
+       ret = rtpcs_sds_select_hw_mode(sds, interface, &hw_mode);
        if (ret < 0) {
                dev_err(ctrl->dev, "SerDes %u doesn't support %s mode\n", sds->id,
                        phy_modes(interface));