VirtualBox

Changeset 44780 in vbox for trunk/src/VBox/Devices/VMMDev


Ignore:
Timestamp:
Feb 21, 2013 1:48:30 PM (12 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
83892
Message:

VMMDev: Do our own locking entirely.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/VMMDev/VMMDev.cpp

    r44778 r44780  
    267267        return;
    268268
    269     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     269    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    270270    vmmdevNotifyGuestWorker(pThis, fAddEvents);
    271271    PDMCritSectLeave(&pThis->CritSect);
     
    288288void VMMDevCtlSetGuestFilterMask(PVMMDEV pThis, uint32_t fOrMask, uint32_t fNotMask)
    289289{
    290     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     290    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    291291
    292292    const bool fHadEvents = (pThis->u32HostEventFlags & pThis->u32GuestFilterMask) != 0;
     
    28002800{
    28012801    PVMMDEV pThis = RT_FROM_MEMBER(pInterface, VMMDEV, IPort);
    2802     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     2802    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    28032803
    28042804    if (   pThis->mouseXAbs != xAbs
     
    28342834{
    28352835    PVMMDEV pThis = RT_FROM_MEMBER(pInterface, VMMDEV, IPort);
    2836     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     2836    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    28372837
    28382838    uint32_t fOldCaps = pThis->mouseCapabilities;
     
    28632863        return VERR_INVALID_PARAMETER;
    28642864
    2865     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     2865    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    28662866
    28672867    DISPLAYCHANGEREQUEST *pRequest = &pThis->displayChangeData.aRequests[idxDisplay];
     
    29202920{
    29212921    PVMMDEV pThis = RT_FROM_MEMBER(pInterface, VMMDEV, IPort);
    2922     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     2922    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    29232923
    29242924    /* Verify that the new resolution is different and that guest does not yet know about it. */
     
    29462946{
    29472947    PVMMDEV pThis = RT_FROM_MEMBER(pInterface, VMMDEV, IPort);
    2948     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     2948    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    29492949
    29502950    /* Verify that the new resolution is different and that guest does not yet know about it. */
     
    29692969{
    29702970    PVMMDEV pThis = RT_FROM_MEMBER(pInterface, VMMDEV, IPort);
    2971     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     2971    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    29722972
    29732973    bool fSame = (pThis->fVRDPEnabled == fVRDPEnabled);
     
    29932993{
    29942994    PVMMDEV pThis = RT_FROM_MEMBER(pInterface, VMMDEV, IPort);
    2995     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     2995    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    29962996
    29972997    /* Verify that the new resolution is different and that guest does not yet know about it. */
     
    30223022    AssertReturn(fFlags & (VMMDEV_SETCREDENTIALS_GUESTLOGON | VMMDEV_SETCREDENTIALS_JUDGE), VERR_INVALID_PARAMETER);
    30233023
    3024     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     3024    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    30253025
    30263026    /*
     
    30773077    Log(("vmmdevIPort_CpuHotUnplug: idCpuCore=%u idCpuPackage=%u\n", idCpuCore, idCpuPackage));
    30783078
    3079     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     3079    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    30803080
    30813081    if (pThis->fCpuHotPlugEventsEnabled)
     
    31033103    Log(("vmmdevCpuPlug: idCpuCore=%u idCpuPackage=%u\n", idCpuCore, idCpuPackage));
    31043104
    3105     PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
     3105    PDMCritSectEnter(&pThis->CritSect, VERR_IGNORED);
    31063106
    31073107    if (pThis->fCpuHotPlugEventsEnabled)
     
    36933693
    36943694    /*
    3695      * Create the critical section for the device.
     3695     * We do our own locking entirely. So, install NOP critsect for the device
     3696     * and create our own critsect for use where it really matters (++).
    36963697     */
     3698    rc = PDMDevHlpSetDeviceCritSect(pDevIns, PDMDevHlpCritSectGetNop(pDevIns));
     3699    AssertRCReturn(rc, rc);
    36973700    rc = PDMDevHlpCritSectInit(pDevIns, &pThis->CritSect, RT_SRC_POS, "VMMDev#%u", iInstance);
    36983701    AssertRCReturn(rc, rc);
    3699     /* Later: pDevIns->pCritSectR3 = &pThis->CritSect; */
    37003702
    37013703    /*
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette