Changeset 64925 in vbox for trunk/src/VBox/Devices
- Timestamp:
- Dec 16, 2016 7:28:31 PM (8 years ago)
- svn:sync-xref-src-repo-rev:
- 112338
- Location:
- trunk/src/VBox/Devices/Network
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Network/DevE1000.cpp
r64836 r64925 70 70 * in init (see @bugref{8624}). 71 71 */ 72 //#define E1K_INIT_LINKUP_DELAY (500 * 1000)72 #define E1K_INIT_LINKUP_DELAY_US (2000 * 1000) 73 73 /** @def E1K_IMS_INT_DELAY_NS 74 74 * E1K_IMS_INT_DELAY_NS prevents interrupt storms in Windows guests on enabling … … 2678 2678 && !(STATUS & STATUS_LU)) 2679 2679 { 2680 #ifdef E1K_INIT_LINKUP_DELAY 2681 /* 2682 * The driver indicates that we should bring up the link. Our default 5-second delay is too long, 2683 * as Linux guests detect Tx hang after 2 seconds. Let's use 500 ms delay instead. */ 2684 e1kArmTimer(pThis, pThis->CTX_SUFF(pLUTimer), E1K_INIT_LINKUP_DELAY); 2685 #else /* !E1K_INIT_LINKUP_DELAY */ 2686 /* Bring up the link immediately, no need for an interrupt though. */ 2687 STATUS |= STATUS_LU; 2688 Phy::setLinkStatus(&pThis->phy, true); 2689 #endif /* !E1K_INIT_LINKUP_DELAY */ 2680 /* It should take about 2 seconds for the link to come up */ 2681 e1kArmTimer(pThis, pThis->CTX_SUFF(pLUTimer), E1K_INIT_LINKUP_DELAY_US); 2690 2682 } 2691 2683 if (value & CTRL_VME) -
trunk/src/VBox/Devices/Network/DevE1000Phy.cpp
r63369 r64925 320 320 REG(PCTRL) = PCTRL_SPDSELM | PCTRL_DUPMOD | PCTRL_ANEG; 321 321 /* 322 * 100 and 10 FD/HD, MF Preamble Suppression, Auto-Negotiation Complete,322 * 100 and 10 FD/HD, Extended Status, MF Preamble Suppression, 323 323 * AUTO NEG AB, EXT CAP 324 324 */ 325 REG(PSTATUS) = (REG(PSTATUS) & ~PSTATUS_LNKSTAT) | 0x7969;325 REG(PSTATUS) = 0x7949; 326 326 REG(ANA) = 0x01E1; 327 327 /* No flow control by our link partner, all speeds */ … … 351 351 static void Phy::softReset(PPHY pPhy) 352 352 { 353 RT_NOREF1(pPhy); 354 PhyLog(("PHY#%d Soft reset is not yet implemented!\n", pPhy->iInstance)); 353 PhyLog(("PHY#%d Soft reset\n", pPhy->iInstance)); 354 /* 355 * 100 and 10 FD/HD, Extended Status, MF Preamble Suppression, 356 * AUTO NEG AB, EXT CAP 357 */ 358 REG(PSTATUS) = 0x7949; 359 REG(PSSTAT) = 0x0000; 360 PhyLog(("PHY#%d PSTATUS=%04x PSSTAT=%04x\n", pPhy->iInstance, REG(PSTATUS), REG(PSSTAT))); 361 PhyLog(("PHY#%d Soft reset is not yet fully implemented!\n", pPhy->iInstance)); 355 362 } 356 363 … … 376 383 { 377 384 if (fLinkIsUp) 385 { 378 386 REG(PSSTAT) |= PSSTAT_LINK; 387 REG(PSTATUS) |= PSTATUS_NEGCOMP; 388 } 379 389 else 380 390 { … … 382 392 REG(PSTATUS) &= ~PSTATUS_LNKSTAT; 383 393 } 394 PhyLog(("PHY#%d setLinkStatus: PSTATUS=%04x PSSTAT=%04x\n", pPhy->iInstance, REG(PSTATUS), REG(PSSTAT))); 384 395 } 385 396 -
trunk/src/VBox/Devices/Network/DevE1000Phy.h
r62511 r64925 28 28 29 29 #define PSTATUS_LNKSTAT 0x0004 30 #define PSTATUS_NEGCOMP 0x0020 30 31 31 32 /*
Note:
See TracChangeset
for help on using the changeset viewer.