lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aMcFHGa1zNFyFUeh@shell.armlinux.org.uk>
Date: Sun, 14 Sep 2025 19:10:36 +0100
From: "Russell King (Oracle)" <linux@...linux.org.uk>
To: Mohd Ayaan Anwar <mohd.anwar@....qualcomm.com>
Cc: Andrew Lunn <andrew@...n.ch>, Heiner Kallweit <hkallweit1@...il.com>,
	"David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	netdev@...r.kernel.org, linux-arm-msm@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next] net: phy: qcom: qca808x: Add .get_rate_matching
 support

On Sun, Sep 14, 2025 at 08:36:48PM +0530, Mohd Ayaan Anwar wrote:
> Add support for rate matching to the QCA8081 PHY driver to correctly
> report its capabilities. Some boards[0][1] with this PHY currently
> report support only for 2.5G.
> 
> Implement the .get_rate_matching callback to allow phylink to determine
> the actual PHY capabilities and report them accurately.

Sorry, but this is incorrect.

The PHY does not support rate matching, but switches between SGMII
and 2500BASE-X depending on the negotiated speed according to the code:

static void qca808x_fill_possible_interfaces(struct phy_device *phydev)
{
        unsigned long *possible = phydev->possible_interfaces;

        __set_bit(PHY_INTERFACE_MODE_SGMII, possible);

        if (!qca808x_is_1g_only(phydev))
                __set_bit(PHY_INTERFACE_MODE_2500BASEX, possible);
}

static int qca808x_read_status(struct phy_device *phydev)
{
...
        if (phydev->link) {
                if (phydev->speed == SPEED_2500)
                        phydev->interface = PHY_INTERFACE_MODE_2500BASEX;
                else
                        phydev->interface = PHY_INTERFACE_MODE_SGMII;
        } else {

The driver certainly does not support rate-matching, even if the PHY
can support it, and even with your patch. All you are doing is making
ethtool suggest that other speeds are supported, but I think you'll
find that if the PHY negotiates those speeds, it won't work.

So, the bug is likely elsewhere, or your ethernet MAC doesn't support
SGMII and you need to add complete support for  rate-matching to the
driver.

Please enable phylink debugging and send the kernel messages so I can
see what's going on.

Thanks.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ