net: amd-xgbe: Check only the minimum speed for active/passive cables
authorTom Lendacky <thomas.lendacky@amd.com>
Thu, 8 Dec 2022 16:22:25 +0000 (10:22 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 31 Dec 2022 12:32:27 +0000 (13:32 +0100)
commit8718e17e0fac4c735e283c8540f8dda64bd9a67a
treed0871be880f0ab50519a653e1487d819b390ffa6
parent7a7de9a6f198ce1952229eac9c7b2c63fe468d39
net: amd-xgbe: Check only the minimum speed for active/passive cables

[ Upstream commit f8ab263d4d48e6dab752029bf562f20a2ee630ed ]

There are cables that exist that can support speeds in excess of 10GbE.
The driver, however, restricts the EEPROM advertised nominal bitrate to
a specific range, which can prevent usage of cables that can support,
for example, up to 25GbE.

Rather than checking that an active or passive cable supports a specific
range, only check for a minimum supported speed.

Fixes: abf0a1c2b26a ("amd-xgbe: Add support for SFP+ modules")
Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c