VirtualBox

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


Ignore:
Timestamp:
May 25, 2011 11:37:52 AM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
71907
Message:

Some ASMAtomic*Size elimiation.

File:
1 edited

Legend:

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

    r37175 r37211  
    21892189{
    21902190    VMMDevState *pThis = IVMMDEVPORT_2_VMMDEVSTATE(pInterface);
    2191     AssertCompile(sizeof(pThis->mouseXAbs) == sizeof(*pAbsX));
    2192     AssertCompile(sizeof(pThis->mouseYAbs) == sizeof(*pAbsY));
    21932191    if (pAbsX)
    2194         ASMAtomicReadSize(&pThis->mouseXAbs, pAbsX);
     2192        *pAbsX = ASMAtomicReadS32(&pThis->mouseXAbs); /* why the atomic read? */
    21952193    if (pAbsY)
    2196         ASMAtomicReadSize(&pThis->mouseYAbs, pAbsY);
     2194        *pAbsY = ASMAtomicReadS32(&pThis->mouseYAbs);
    21972195    return VINF_SUCCESS;
    21982196}
     
    22102208    PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
    22112209
    2212     if ((pThis->mouseXAbs == absX) && (pThis->mouseYAbs == absY))
     2210    if (pThis->mouseXAbs == absX && pThis->mouseYAbs == absY)
    22132211    {
    22142212        PDMCritSectLeave(&pThis->CritSect);
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