Changeset 53369 in vbox for trunk/src/VBox
- Timestamp:
- Nov 21, 2014 12:08:21 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostDrivers/Support/SUPDrv.c
r53288 r53369 6612 6612 idxNewGipMaster = supdrvGipCpuIndexFromCpuId(pGip, idNewGipMaster); 6613 6613 iTSCDelta = pGip->aCPUs[idxNewGipMaster].i64TSCDelta; 6614 Assert(iTSCDelta != UINT64_MAX);6614 Assert(iTSCDelta != INT64_MAX); 6615 6615 for (i = 0; i < pGip->cCpus; i++) 6616 6616 { … … 6750 6750 while (cTriesLeft-- > 0) 6751 6751 { 6752 unsigned 6753 uint64_t 6752 unsigned i; 6753 uint64_t uMinCmpReadTime = UINT64_MAX; 6754 6754 for (i = 0; i < GIP_TSC_DELTA_LOOPS; i++) 6755 6755 { 6756 RTCCUINTREG uFlags = ASMIntDisableFlags(); /* Disable interrupts per-iteration, see @bugref{6710} comment #38. */6757 6756 if (idCpu == idMaster) 6758 6757 { … … 6760 6759 * The master. 6761 6760 */ 6761 RTCCUINTREG uFlags; 6762 6762 Assert(pGipCpuMaster->u64TSCSample == GIP_TSC_DELTA_RSVD); 6763 6763 ASMAtomicWriteU32(&g_pTscDeltaSync->u, GIP_TSC_DELTA_SYNC_START); 6764 6765 /* Disable interrupts only in the master for as short a period 6766 as possible, thanks again to Windows. See @bugref{6710} comment #73. */ 6767 uFlags = ASMIntDisableFlags(); 6768 6764 6769 while (ASMAtomicReadU32(&g_pTscDeltaSync->u) == GIP_TSC_DELTA_SYNC_START) 6765 6770 ; … … 6770 6775 ASMAtomicWriteU64(&pGipCpuMaster->u64TSCSample, ASMReadTSC()); 6771 6776 } while (pGipCpuMaster->u64TSCSample == GIP_TSC_DELTA_RSVD); 6777 6778 ASMSetFlags(uFlags); 6772 6779 6773 6780 while (ASMAtomicReadU32(&g_pTscDeltaSync->u) != GIP_TSC_DELTA_SYNC_WORKER_DONE) … … 6839 6846 ASMNopPause(); 6840 6847 } 6841 6842 ASMSetFlags(uFlags);6843 6848 } 6844 6849
Note:
See TracChangeset
for help on using the changeset viewer.