Index: /trunk/src/VBox/Devices/Audio/DevHDA.cpp
===================================================================
--- /trunk/src/VBox/Devices/Audio/DevHDA.cpp	(revision 82401)
+++ /trunk/src/VBox/Devices/Audio/DevHDA.cpp	(revision 82402)
@@ -1221,10 +1221,4 @@
 
     /*
-     * Some guests write too much (that is, 32-bit with the top 8 bit being junk)
-     * instead of 24-bit required for SDCTL. So just mask this here to be safe.
-     */
-    u32Value &= 0x00ffffff;
-
-    /*
      * Extract the stream tag the guest wants to use for this specific
      * stream descriptor (SDn). This only can happen if the stream is in a non-running
@@ -3333,5 +3327,5 @@
                 uint32_t uLogOldVal = pThis->au32Regs[idxRegMem];
 # endif
-                rc = hdaWriteReg(pDevIns, pThis, idxRegDsc, u64Value, "*");
+                rc = hdaWriteReg(pDevIns, pThis, idxRegDsc, u64Value & g_afMasks[cbReg], "*");
                 Log4Func(("\t%#x -> %#x\n", uLogOldVal, pThis->au32Regs[idxRegMem]));
             }
