Changeset 87837 in vbox
- Timestamp:
- Feb 23, 2021 5:45:25 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Bus/DevIommuAmd.cpp
r87834 r87837 6182 6182 pHlp->pfnSSMPutU64(pSSM, pThis->DevSpecificCtrl.u64); /* read-only, done in liveExec */ 6183 6183 pHlp->pfnSSMPutU64(pSSM, pThis->DevSpecificStatus.u64); /* read-only, done in liveExec */ 6184 #endif 6185 6186 #if 0 6184 6187 6185 pHlp->pfnSSMPutU64(pSSM, pThis->MiscInfo.u64); /* read-only, done in liveExec */ 6188 6186 #endif … … 6297 6295 ("Control register invalid %#RX64\n", pThis->Ctrl.u64), rcDataError); 6298 6296 6297 /* Exclusion range base address register. */ 6298 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->ExclRangeBaseAddr.u64); 6299 AssertRCReturn(rc, rc); 6300 pThis->ExclRangeBaseAddr.u64 &= IOMMU_EXCL_RANGE_BAR_VALID_MASK; 6301 6302 /* Exclusion range limit register. */ 6303 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->ExclRangeLimit.u64); 6304 AssertRCReturn(rc, rc); 6305 pThis->ExclRangeLimit.u64 &= IOMMU_EXCL_RANGE_LIMIT_VALID_MASK; 6306 pThis->ExclRangeLimit.u64 |= UINT64_C(0xfff); 6307 6308 #if 0 6309 pHlp->pfnSSMGetU64(pSSM, &pThis->ExtFeat.u64); /* read-only, done already (above). */ 6310 #endif 6311 6312 /* PPR log base address register. */ 6313 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->PprLogBaseAddr.u64); 6314 AssertRCReturn(rc, rc); 6315 Assert(!pThis->ExtFeat.n.u1PprSup); 6316 6317 /* Hardware event (Hi) register. */ 6318 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->HwEvtHi.u64); 6319 AssertRCReturn(rc, rc); 6320 6321 /* Hardware event (Lo) register. */ 6322 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->HwEvtLo); 6323 AssertRCReturn(rc, rc); 6324 6325 /* Hardware event status register. */ 6326 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->HwEvtStatus.u64); 6327 AssertRCReturn(rc, rc); 6328 pThis->HwEvtStatus.u64 &= IOMMU_HW_EVT_STATUS_VALID_MASK; 6329 6330 /* Guest Virtual-APIC log base address register. */ 6331 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->GALogBaseAddr.u64); 6332 AssertRCReturn(rc, rc); 6333 Assert(!pThis->ExtFeat.n.u1GstVirtApicSup); 6334 6335 /* Guest Virtual-APIC log tail address register. */ 6336 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->GALogTailAddr.u64); 6337 AssertRCReturn(rc, rc); 6338 Assert(!pThis->ExtFeat.n.u1GstVirtApicSup); 6339 6340 /* PPR log-B base address register. */ 6341 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->PprLogBBaseAddr.u64); 6342 AssertRCReturn(rc, rc); 6343 Assert(!pThis->ExtFeat.n.u1PprSup); 6344 6345 /* Event log-B base address register. */ 6346 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->EvtLogBBaseAddr.u64); 6347 AssertRCReturn(rc, rc); 6348 Assert(!pThis->ExtFeat.n.u2DualPprLogSup); 6349 6350 #if 0 6351 pHlp->pfnSSMGetU64(pSSM, &pThis->DevSpecificFeat.u64); /* read-only, done already (above). */ 6352 pHlp->pfnSSMGetU64(pSSM, &pThis->DevSpecificCtrl.u64); /* read-only, done already (above). */ 6353 pHlp->pfnSSMGetU64(pSSM, &pThis->DevSpecificStatus.u64); /* read-only, done already (above). */ 6354 6355 pHlp->pfnSSMGetU64(pSSM, &pThis->MiscInfo.u64); /* read-only, done already (above). */ 6356 #endif 6357 6358 /* Performance optimization control register. */ 6359 rc = pHlp->pfnSSMGetU32(pSSM, &pThis->PerfOptCtrl.u32); 6360 AssertRCReturn(rc, rc); 6361 Assert(!pThis->ExtFeat.n.u1PerfOptSup); 6362 6363 /* x2APIC registers. */ 6364 { 6365 Assert(!pThis->ExtFeat.n.u1X2ApicSup); 6366 6367 /* x2APIC general interrupt control register. */ 6368 pHlp->pfnSSMGetU64(pSSM, &pThis->XtGenIntrCtrl.u64); 6369 AssertRCReturn(rc, rc); 6370 6371 /* x2APIC PPR interrupt control register. */ 6372 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->XtPprIntrCtrl.u64); 6373 AssertRCReturn(rc, rc); 6374 6375 /* x2APIC GA log interrupt control register. */ 6376 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->XtGALogIntrCtrl.u64); 6377 AssertRCReturn(rc, rc); 6378 } 6379 6380 /* MARC (Memory access and routing) registers. */ 6381 { 6382 uint8_t cMarcApers; 6383 rc = pHlp->pfnSSMGetU8(pSSM, &cMarcApers); 6384 AssertRCReturn(rc, rc); 6385 AssertLogRelMsgReturn(cMarcApers <= RT_ELEMENTS(pThis->aMarcApers), 6386 ("MARC register count invalid %#x\n", cMarcApers), rcDataError); 6387 for (uint8_t i = 0; i < cMarcApers; i++) 6388 { 6389 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->aMarcApers[i].Base.u64); 6390 AssertRCReturn(rc, rc); 6391 6392 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->aMarcApers[i].Reloc.u64); 6393 AssertRCReturn(rc, rc); 6394 6395 rc = pHlp->pfnSSMGetU64(pSSM, &pThis->aMarcApers[i].Length.u64); 6396 AssertRCReturn(rc, rc); 6397 } 6398 Assert(!pThis->ExtFeat.n.u2MarcSup); 6399 } 6400 6401 #if 0 6402 pHlp->pfnSSMGetU64(pSSM, &pThis->RsvdReg); /* read-only, done already (above). */ 6403 #endif 6404 6299 6405 /** @todo The rest. */ 6300 6406 return VERR_NOT_IMPLEMENTED; 6301 6407 #if 0 6302 pThis->ExclRangeBaseAddr.u646303 pThis->ExclRangeLimit.u646304 #if 06305 pThis->ExtFeat.u64; /* read-only, done in liveExec */6306 #endif6307 6308 pThis->PprLogBaseAddr.u64);6309 pThis->HwEvtHi.u64);6310 pThis->HwEvtLo);6311 pThis->HwEvtStatus.u64);6312 6313 pThis->GALogBaseAddr.u64);6314 pThis->GALogTailAddr.u64);6315 6316 pThis->PprLogBBaseAddr.u64);6317 pThis->EvtLogBBaseAddr.u64);6318 6319 #if 06320 pThis->DevSpecificFeat.u64); /* read-only, done in liveExec */6321 pThis->DevSpecificCtrl.u64); /* read-only, done in liveExec */6322 pThis->DevSpecificStatus.u64); /* read-only, done in liveExec */6323 #endif6324 6325 #if 06326 pThis->MiscInfo.u64); /* read-only, done in liveExec */6327 #endif6328 pThis->PerfOptCtrl.u32);6329 6330 pThis->XtGenIntrCtrl.u64);6331 pThis->XtPprIntrCtrl.u64);6332 pThis->XtGALogIntrCtrl.u64);6333 6334 size_t const cMarcApers = RT_ELEMENTS(pThis->aMarcApers);6335 pHlp->pfnSSMPutU8(pSSM, cMarcApers);6336 for (size_t i = 0; i < cMarcApers; i++)6337 {6338 pHlp->pfnSSMPutU64(pSSM, pThis->aMarcApers[i].Base.u64);6339 pHlp->pfnSSMPutU64(pSSM, pThis->aMarcApers[i].Reloc.u64);6340 pHlp->pfnSSMPutU64(pSSM, pThis->aMarcApers[i].Length.u64);6341 }6342 6343 #if 06344 pHlp->pfnSSMPutU64(pSSM, pThis->RsvdReg); /* read-only, done in liveExec */6345 #endif6346 6408 6347 6409 pThis->CmdBufHeadPtr.u64);
Note:
See TracChangeset
for help on using the changeset viewer.