IN EFI_SIMPLE_NETWORK_PROTOCOL *Snp\r
)\r
{\r
- UINTN Timeout;\r
+ UINTN Retries;\r
UINT64 DefaultMacAddress;\r
\r
// Attempt to wake-up the device if it is in a lower power state\r
}\r
\r
// Check that device is active\r
- Timeout = 20;\r
- while ((MmioRead32 (LAN9118_PMT_CTRL) & MPTCTRL_READY) == 0 && --Timeout) {\r
+ Retries = 20;\r
+ while ((MmioRead32 (LAN9118_PMT_CTRL) & MPTCTRL_READY) == 0 && --Retries) {\r
gBS->Stall (LAN9118_STALL);\r
MemoryFence();\r
}\r
- if (!Timeout) {\r
+ if (!Retries) {\r
return EFI_TIMEOUT;\r
}\r
\r
// Check that EEPROM isn't active\r
- Timeout = 20;\r
- while ((MmioRead32 (LAN9118_E2P_CMD) & E2P_EPC_BUSY) && --Timeout){\r
+ Retries = 20;\r
+ while ((MmioRead32 (LAN9118_E2P_CMD) & E2P_EPC_BUSY) && --Retries){\r
gBS->Stall (LAN9118_STALL);\r
MemoryFence();\r
}\r
- if (!Timeout) {\r
+ if (!Retries) {\r
return EFI_TIMEOUT;\r
}\r
\r
UINT32 PhyControl;\r
UINT32 PhyStatus;\r
UINT32 Features;\r
- UINT32 TimeOut;\r
+ UINT32 Retries;\r
\r
// First check that auto-negotiation is supported\r
PhyStatus = IndirectPHYRead32 (PHY_INDEX_BASIC_STATUS);\r
// Check that link is up first\r
if ((PhyStatus & PHYSTS_LINK_STS) == 0) {\r
// Wait until it is up or until Time Out\r
- TimeOut = FixedPcdGet32 (PcdLan9118DefaultNegotiationTimeout) / LAN9118_STALL;\r
+ Retries = FixedPcdGet32 (PcdLan9118DefaultNegotiationTimeout) / LAN9118_STALL;\r
while ((IndirectPHYRead32 (PHY_INDEX_BASIC_STATUS) & PHYSTS_LINK_STS) == 0) {\r
MemoryFence();\r
gBS->Stall (LAN9118_STALL);\r
- TimeOut--;\r
- if (!TimeOut) {\r
+ Retries--;\r
+ if (!Retries) {\r
DEBUG ((EFI_D_ERROR, "Link timeout in auto-negotiation.\n"));\r
return EFI_TIMEOUT;\r
}\r