Re: [PATCH net-next v5] net: phy: aquantia: Add support for 5GbaseR
From: Andrew Lunn
Date: Wed Nov 04 2026 - 17:28:01 EST
On Wed, Nov 04, 2026 at 05:57:52PM +0800, Hongmei Xu wrote:
> Aquantia PHYs can operate with a 5G USX interface between the PHY
> and MAC, reported as interface type 12 in the PHYXS vendor interface
> status register (MDIO_PHYXS_VEND_IF_STATUS_TYPE_USX_5G).
>
> Without this change, aqr_gen1_read_status() falls through to the
> default case and sets phydev->link = false when the interface type
> is USX 5G, preventing 5G links from coming up.
>
> Add the missing PHY_INTERFACE_MODE_5GBASER handling in three places:
>
> - aqr_gen1_read_status(): map USX 5G interface type to
> PHY_INTERFACE_MODE_5GBASER so the link is correctly reported
> - aqr_gen1_config_init(): accept PHY_INTERFACE_MODE_5GBASER as a
> valid interface mode, otherwise the PHY is rejected with -ENODEV
> - aqr_gen2_get_rate_matching(): return RATE_MATCH_PAUSE for
> PHY_INTERFACE_MODE_5GBASER, consistent with 10GBASER and 2500BASEX,
> since the MAC-side interface runs at a fixed rate and the PHY handles
> rate adaptation via pause frames
>
> Co-developed-by: Sagar Cheluvegowda <sagar.cheluvegowda@xxxxxxxxxxxxxxxx>
> Signed-off-by: Sagar Cheluvegowda <sagar.cheluvegowda@xxxxxxxxxxxxxxxx>
> Signed-off-by: Hongmei Xu <hongmei.xu@xxxxxxxxxxxxxxxx>
Reviewed-by: Andrew Lunn <andrew@xxxxxxx>
Andrew