VirtualBox

Changeset 82402 in vbox for trunk/src


Ignore:
Timestamp:
Dec 4, 2019 11:50:36 PM (5 years ago)
Author:
vboxsync
Message:

DevHDA: Removed unnecessary input masking in hdaRegWriteSDCTL and instead make hdaMmioWrite do the requested masking according to the register size (I suspect the masking was added to avoid assertion in the 24-bit register writer). Guest does not write junk in the top 8-bits, they write the SDSTS register, only hdaMmioWrite confused us here. bugref:9218

File:
1 edited

Legend:

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

    r82401 r82402  
    12211221
    12221222    /*
    1223      * Some guests write too much (that is, 32-bit with the top 8 bit being junk)
    1224      * instead of 24-bit required for SDCTL. So just mask this here to be safe.
    1225      */
    1226     u32Value &= 0x00ffffff;
    1227 
    1228     /*
    12291223     * Extract the stream tag the guest wants to use for this specific
    12301224     * stream descriptor (SDn). This only can happen if the stream is in a non-running
     
    33333327                uint32_t uLogOldVal = pThis->au32Regs[idxRegMem];
    33343328# endif
    3335                 rc = hdaWriteReg(pDevIns, pThis, idxRegDsc, u64Value, "*");
     3329                rc = hdaWriteReg(pDevIns, pThis, idxRegDsc, u64Value & g_afMasks[cbReg], "*");
    33363330                Log4Func(("\t%#x -> %#x\n", uLogOldVal, pThis->au32Regs[idxRegMem]));
    33373331            }
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