VirtualBox

Changeset 76188 in vbox for trunk/src/VBox/Devices/Audio


Ignore:
Timestamp:
Dec 12, 2018 4:08:40 PM (6 years ago)
Author:
vboxsync
Message:

Audio/AC97: Saved state fix (also re-arm the per-stream timer when loading from a saved state).

File:
1 edited

Legend:

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

    r76186 r76188  
    37343734    for (unsigned i = 0; i < AC97_MAX_STREAMS; i++)
    37353735    {
    3736         rc2 = ichac97R3StreamEnable(pThis, &pThis->aStreams[i], RT_BOOL(uaStrmsActive[i]));
     3736        const bool        fEnable = RT_BOOL(uaStrmsActive[i]);
     3737        const PAC97STREAM pStream = &pThis->aStreams[i];
     3738
     3739        rc2 = ichac97R3StreamEnable(pThis, pStream, fEnable);
     3740        if (RT_SUCCESS(rc2))
     3741        {
     3742            /* Re-arm the timer for this stream. */
     3743            rc2 = ichac97R3TimerSet(pThis, pStream,
     3744                                    TMTimerGet((pThis)->DEVAC97_CTX_SUFF_SD(pTimer, pStream->u8SD)) + pStream->State.cTransferTicks,
     3745                                    false /* fForce */);
     3746        }
     3747
    37373748        AssertRC(rc2);
    37383749        /* Keep going. */
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