Commit 799f532d authored by Rengarajan S's avatar Rengarajan S Committed by Jakub Kicinski

lan78xx: Enable Auto Speed and Auto Duplex configuration for LAN7801 if NO EEPROM is detected

Enabled ASD/ADD configuration for LAN7801 in the absence of EEPROM.
After the lite reset these contents go back to defaults where ASD/
ADD is disabled. The check is already available for LAN7800.
Reviewed-by: default avatarSimon Horman <horms@kernel.org>
Signed-off-by: default avatarRengarajan S <rengarajan.s@microchip.com>
Link: https://lore.kernel.org/r/20240529140256.1849764-3-rengarajan.s@microchip.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 5160b129
...@@ -3031,8 +3031,11 @@ static int lan78xx_reset(struct lan78xx_net *dev) ...@@ -3031,8 +3031,11 @@ static int lan78xx_reset(struct lan78xx_net *dev)
return ret; return ret;
/* LAN7801 only has RGMII mode */ /* LAN7801 only has RGMII mode */
if (dev->chipid == ID_REV_CHIP_ID_7801_) if (dev->chipid == ID_REV_CHIP_ID_7801_) {
buf &= ~MAC_CR_GMII_EN_; buf &= ~MAC_CR_GMII_EN_;
/* Enable Auto Duplex and Auto speed */
buf |= MAC_CR_AUTO_DUPLEX_ | MAC_CR_AUTO_SPEED_;
}
if (dev->chipid == ID_REV_CHIP_ID_7800_ || if (dev->chipid == ID_REV_CHIP_ID_7800_ ||
dev->chipid == ID_REV_CHIP_ID_7850_) { dev->chipid == ID_REV_CHIP_ID_7850_) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment