VirtualBox

Changeset 75538 in vbox for trunk/src/VBox/Devices


Ignore:
Timestamp:
Nov 17, 2018 2:32:21 AM (6 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
126696
Message:

VMMDev/HGCM: Use an allocation cache for HGCM command structures with 6 or fewer parameters (also connect and disconnect). Moved the connection location out of the union just like the parameters, as it's 132 bytes big. bugref:9172 [destroy fix]

File:
1 edited

Legend:

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

    r75537 r75538  
    21632163    LogFlowFunc(("\n"));
    21642164
    2165     RTCritSectDelete(&pThis->critsectHGCMCmdList);
    2166 
    2167     PVBOXHGCMCMD pCmd, pNext;
    2168     RTListForEachSafe(&pThis->listHGCMCmd, pCmd, pNext, VBOXHGCMCMD, node)
    2169     {
    2170         vmmdevHGCMRemoveCommand(pThis, pCmd);
    2171         vmmdevHGCMCmdFree(pThis, pCmd);
     2165    if (RTCritSectIsInitialized(&pThis->critsectHGCMCmdList))
     2166    {
     2167        PVBOXHGCMCMD pCmd, pNext;
     2168        RTListForEachSafe(&pThis->listHGCMCmd, pCmd, pNext, VBOXHGCMCMD, node)
     2169        {
     2170            vmmdevHGCMRemoveCommand(pThis, pCmd);
     2171            vmmdevHGCMCmdFree(pThis, pCmd);
     2172        }
     2173
     2174        RTCritSectDelete(&pThis->critsectHGCMCmdList);
    21722175    }
    21732176
     
    21912194int vmmdevHGCMInit(PVMMDEV pThis)
    21922195{
     2196    LogFlowFunc(("\n"));
     2197
    21932198    RTListInit(&pThis->listHGCMCmd);
    21942199
Note: See TracChangeset for help on using the changeset viewer.

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