phy: aquantia: Fix AN when higher speeds than 1G are not advertised
authorClaudiu Manoil <claudiu.manoil@nxp.com>
Fri, 10 Jun 2022 08:40:37 +0000 (11:40 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 29 Jun 2022 07:03:22 +0000 (09:03 +0200)
commitd7fe6be43cfaaa10a9cc48a5baf202c387caeefd
tree45f5ae356e23b35658b22d174cfb5db082650852
parent8e74f5ceea52fb76fe77ab5f22b8e667a93518aa
phy: aquantia: Fix AN when higher speeds than 1G are not advertised

[ Upstream commit 9b7fd1670a94a57d974795acebde843a5c1a354e ]

Even when the eth port is resticted to work with speeds not higher than 1G,
and so the eth driver is requesting the phy (via phylink) to advertise up
to 1000BASET support, the aquantia phy device is still advertising for 2.5G
and 5G speeds.
Clear these advertising defaults when requested.

Cc: Ondrej Spacek <ondrej.spacek@nxp.com>
Fixes: 09c4c57f7bc41 ("net: phy: aquantia: add support for auto-negotiation configuration")
Signed-off-by: Claudiu Manoil <claudiu.manoil@nxp.com>
Link: https://lore.kernel.org/r/20220610084037.7625-1-claudiu.manoil@nxp.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/phy/aquantia_main.c