VirtualBox

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


Ignore:
Timestamp:
Apr 9, 2018 11:08:31 AM (7 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
121869
Message:

DevHDA: Follow-up to r121836 (hdaTimerSet).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Audio/DevHDACommon.cpp

    r71736 r71767  
    689689bool hdaR3TimerSet(PHDASTATE pThis, PHDASTREAM pStream, uint64_t tsExpire, bool fForce)
    690690{
    691     AssertPtr(pThis);
    692     AssertPtr(pStream);
     691    AssertPtrReturn(pThis, false);
     692    AssertPtrReturn(pStream, false);
    693693
    694694    uint64_t tsExpireMin = tsExpire;
     
    702702    AssertPtr(pThis->pTimer[pStream->u8SD]);
    703703
    704 # ifdef VBOX_STRICT
    705     /** @todo r=bird: This looks totally wrong inside \#ifdef VBOX_STRICT,
    706      * especially with the comment.  If you're trying to avoid assertions in TM
    707      * code, you better say so and explain why it's okay to try bypass it this
    708      * way.  If that isn't the case, then I don't know what on earth you're doing
    709      * here... */
    710704    const uint64_t tsNow = TMTimerGet(pThis->pTimer[pStream->u8SD]);
    711705
    712     if (tsExpireMin < tsNow) /* Make sure to not go backwards in time. */
     706    /*
     707     * Make sure to not go backwards in time, as this will assert in TMTimerSet().
     708     * This in theory could happen in hdaR3StreamTransferGetNext() from above.
     709     */
     710    if (tsExpireMin < tsNow)
    713711        tsExpireMin = tsNow;
    714 # endif
    715 
    716       int rc2 = TMTimerSet(pThis->pTimer[pStream->u8SD], tsExpireMin);
    717       AssertRC(rc2);
    718 
    719     return true;
     712
     713    int rc = TMTimerSet(pThis->pTimer[pStream->u8SD], tsExpireMin);
     714    AssertRC(rc);
     715
     716    return RT_SUCCESS(rc);
    720717}
    721718
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