Changeset 104804 in vbox for trunk/src/VBox/Devices/USB
- Timestamp:
- May 28, 2024 1:04:36 PM (9 months ago)
- svn:sync-xref-src-repo-rev:
- 163376
- Location:
- trunk/src/VBox/Devices/USB
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/USB/DrvVUSBRootHub.cpp
r104303 r104804 711 711 712 712 /* Don't do anything if we are not supposed to process anything (EHCI and XHCI). */ 713 if (!pThis->uFrameRateDefault) 713 if ( !pThis->uFrameRateDefault 714 || ASMAtomicReadBool(&pThis->fSavingState)) 714 715 return 0; 715 716 … … 1374 1375 RT_NOREF(pSSM); 1375 1376 1377 ASMAtomicXchgBool(&pThis->fSavingState, true); 1378 1376 1379 /* 1377 1380 * If there is old load state hanging around, we'll have to execute it first … … 1391 1394 * Detach all proxied devices. 1392 1395 */ 1393 RTCritSectEnter(&pThis->CritSectDevices);1394 1396 1395 1397 /** @todo we a) can't tell which are proxied, and b) this won't work well when continuing after saving! */ 1396 1398 for (unsigned i = 0; i < RT_ELEMENTS(pThis->apDevByPort); i++) 1397 1399 { 1398 PVUSBDEV pDev = pThis->apDevByPort[i];1400 PVUSBDEV pDev = vusbR3RhGetVUsbDevByPortRetain(pThis, i, "SavePrep"); 1399 1401 if (pDev) 1400 1402 { … … 1409 1411 * called unconditionally if the Prep handler was called. 1410 1412 */ 1413 Assert(!pThis->apDevByPort[i]); 1411 1414 pThis->apDevByPort[i] = pDev; 1415 vusbDevRelease(pDev, "SavePrep"); 1412 1416 } 1413 1417 } 1414 1418 } 1415 1416 RTCritSectLeave(&pThis->CritSectDevices);1417 1419 1418 1420 return VINF_SUCCESS; … … 1452 1454 } 1453 1455 1456 ASMAtomicXchgBool(&pThis->fSavingState, false); 1454 1457 return VINF_SUCCESS; 1455 1458 } -
trunk/src/VBox/Devices/USB/VUSBInternal.h
r100517 r104804 422 422 /** Flag whether a frame is currently being processed. */ 423 423 volatile bool fFrameProcessing; 424 /** Flag whether we are in the middle of saving the VM state. */ 425 volatile bool fSavingState; 424 426 425 427 #if HC_ARCH_BITS == 32
Note:
See TracChangeset
for help on using the changeset viewer.