VirtualBox

Changeset 13766 in vbox for trunk/src/VBox/VMM/VMReq.cpp


Ignore:
Timestamp:
Nov 3, 2008 5:30:25 PM (16 years ago)
Author:
vboxsync
Message:

No need to call RTThreadNativeSelf twice.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMReq.cpp

    r13765 r13766  
    618618     * Also, store pVM (and fFlags) locally since pReq may be invalid after queuing it.
    619619     */
     620    RTNATIVETHREAD hCurrentThread = RTThreadNativeSelf();
    620621    int rc = VINF_SUCCESS;
    621622    PUVM pUVM = ((VMREQ volatile *)pReq)->pUVM;                 /* volatile paranoia */
    622623    if (    pReq->enmDest == VMREQDEST_ALL
    623         &&  pUVM->vm.s.NativeThreadEMT != RTThreadNativeSelf())
     624        &&  pUVM->vm.s.NativeThreadEMT != hCurrentThread)
    624625    {
    625626        unsigned fFlags = ((VMREQ volatile *)pReq)->fFlags;     /* volatile paranoia */
     
    652653    else
    653654    if (    pReq->enmDest != VMREQDEST_ALL
    654         &&  pUVM->aCpu[pReq->enmDest].vm.s.NativeThreadEMT != RTThreadNativeSelf())
     655        &&  pUVM->aCpu[pReq->enmDest].vm.s.NativeThreadEMT != hCurrentThread)
    655656    {
    656657        RTCPUID  idTarget = (RTCPUID)pReq->enmDest;
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