Changeset 82307 in vbox for trunk/src/VBox/Devices/Audio
- Timestamp:
- Dec 1, 2019 12:39:11 AM (5 years ago)
- Location:
- trunk/src/VBox/Devices/Audio
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevHDA.cpp
r82306 r82307 3471 3471 } 3472 3472 3473 3474 /* PCI callback. */3475 3476 3473 #ifdef IN_RING3 3477 3474 3478 /* Saved state workers and callbacks. */ 3475 3476 /********************************************************************************************************************************* 3477 * Saved state * 3478 *********************************************************************************************************************************/ 3479 3479 3480 3480 /** … … 3711 3711 switch (uVersion) 3712 3712 { 3713 case HDA_S SM_VERSION_1:3713 case HDA_SAVED_STATE_VERSION_1: 3714 3714 /* Starting with r71199, we would save 112 instead of 113 3715 3715 registers due to some code cleanups. This only affected trunk … … 3726 3726 break; 3727 3727 3728 case HDA_S SM_VERSION_2:3729 case HDA_S SM_VERSION_3:3728 case HDA_SAVED_STATE_VERSION_2: 3729 case HDA_SAVED_STATE_VERSION_3: 3730 3730 cRegs = 112; 3731 3731 AssertCompile(RT_ELEMENTS(pThis->au32Regs) >= 112); … … 3733 3733 3734 3734 /* Since version 4 we store the register count to stay flexible. */ 3735 case HDA_S SM_VERSION_4:3736 case HDA_S SM_VERSION_5:3737 case HDA_S SM_VERSION_6:3735 case HDA_SAVED_STATE_VERSION_4: 3736 case HDA_SAVED_STATE_VERSION_5: 3737 case HDA_SAVED_STATE_VERSION_6: 3738 3738 rc = pHlp->pfnSSMGetU32(pSSM, &cRegs); 3739 3739 AssertRCReturn(rc, rc); … … 3777 3777 switch (uVersion) 3778 3778 { 3779 case HDA_S SM_VERSION_1:3780 case HDA_S SM_VERSION_2:3781 case HDA_S SM_VERSION_3:3782 case HDA_S SM_VERSION_4:3779 case HDA_SAVED_STATE_VERSION_1: 3780 case HDA_SAVED_STATE_VERSION_2: 3781 case HDA_SAVED_STATE_VERSION_3: 3782 case HDA_SAVED_STATE_VERSION_4: 3783 3783 { 3784 3784 /* Only load the internal states. … … 3856 3856 * Load BDLEs (Buffer Descriptor List Entries) and DMA counters. 3857 3857 */ 3858 if (uVersion == HDA_S SM_VERSION_5)3858 if (uVersion == HDA_SAVED_STATE_VERSION_5) 3859 3859 { 3860 3860 struct V5HDASTREAMSTATE /* HDASTREAMSTATE + HDABDLE */ … … 3945 3945 } 3946 3946 3947 if (uVersion <= HDA_S SM_VERSION_6) /* Handle older saved states? */3947 if (uVersion <= HDA_SAVED_STATE_VERSION_6) /* Handle older saved states? */ 3948 3948 { 3949 3949 rc = hdaR3LoadExecLegacy(pDevIns, pThis, pSSM, uVersion); … … 4121 4121 } 4122 4122 4123 /* IPRT format type handlers. */ 4123 4124 /********************************************************************************************************************************* 4125 * IPRT format type handlers * 4126 *********************************************************************************************************************************/ 4124 4127 4125 4128 /** … … 4207 4210 } 4208 4211 4209 /* Debug info dumpers */ 4212 4213 /********************************************************************************************************************************* 4214 * Debug Info Item Handlers * 4215 *********************************************************************************************************************************/ 4210 4216 4211 4217 static int hdaR3DbgLookupRegByName(const char *pszArgs) … … 4391 4397 4392 4398 4393 /* PDMIBASE */ 4399 /********************************************************************************************************************************* 4400 * PDMIBASE * 4401 *********************************************************************************************************************************/ 4394 4402 4395 4403 /** … … 4406 4414 4407 4415 4408 /* PDMDEVREG */ 4416 /********************************************************************************************************************************* 4417 * PDMDEVREGR3 * 4418 *********************************************************************************************************************************/ 4409 4419 4410 4420 /** … … 4908 4918 #endif 4909 4919 4910 rc = PDMDevHlpSSMRegister(pDevIns, HDA_S SM_VERSION, sizeof(*pThis), hdaR3SaveExec, hdaR3LoadExec);4920 rc = PDMDevHlpSSMRegister(pDevIns, HDA_SAVED_STATE_VERSION, sizeof(*pThis), hdaR3SaveExec, hdaR3LoadExec); 4911 4921 AssertRCReturn(rc, rc); 4912 4922 -
trunk/src/VBox/Devices/Audio/HDACodec.cpp
r82252 r82307 3131 3131 switch (uVersion) 3132 3132 { 3133 case HDA_S SM_VERSION_1:3133 case HDA_SAVED_STATE_VERSION_1: 3134 3134 AssertReturn(pThis->cTotalNodes == 0x1c, VERR_INTERNAL_ERROR); 3135 3135 pFields = g_aCodecNodeFieldsV1; … … 3137 3137 break; 3138 3138 3139 case HDA_S SM_VERSION_2:3140 case HDA_S SM_VERSION_3:3139 case HDA_SAVED_STATE_VERSION_2: 3140 case HDA_SAVED_STATE_VERSION_3: 3141 3141 AssertReturn(pThis->cTotalNodes == 0x1c, VERR_INTERNAL_ERROR); 3142 3142 pFields = g_aCodecNodeFields; … … 3145 3145 3146 3146 /* Since version 4 a flexible node count is supported. */ 3147 case HDA_S SM_VERSION_4:3148 case HDA_S SM_VERSION_5:3149 case HDA_S SM_VERSION:3147 case HDA_SAVED_STATE_VERSION_4: 3148 case HDA_SAVED_STATE_VERSION_5: 3149 case HDA_SAVED_STATE_VERSION: 3150 3150 { 3151 3151 uint32_t cNodes; -
trunk/src/VBox/Devices/Audio/HDACodec.h
r82306 r82307 132 132 int hdaCodecRemoveStream(PHDACODEC pThis, PDMAUDIOMIXERCTL enmMixerCtl); 133 133 134 /** @name Dev HDA saved state verions 135 * @todo r=bird: s/HDA_SSM_/HDA_SAVED_STATE_/g - SSM = saved state manager, duh! 134 /** @name DevHDA saved state versions 136 135 * @{ */ 137 136 /** Added (Controller): Current wall clock value (this independent from WALCLK register value). … … 142 141 * Added (Current BDLE per stream): Struct g_aSSMBDLEDescFields7. 143 142 * Added (Current BDLE per stream): Struct g_aSSMBDLEStateFields7. */ 144 #define HDA_SSM_VERSION 7 145 /** Saves the current BDLE state. */ 146 #define HDA_SSM_VERSION_6 6 143 #define HDA_SAVED_STATE_VERSION 7 144 /** Saves the current BDLE state. 145 * @since 5.0.14 (r104839) */ 146 #define HDA_SAVED_STATE_VERSION_6 6 147 147 /** Introduced dynamic number of streams + stream identifiers for serialization. 148 148 * Bug: Did not save the BDLE states correctly. 149 * Those will be skipped on load then. */ 150 #define HDA_SSM_VERSION_5 5 149 * Those will be skipped on load then. 150 * @since 5.0.12 (r104520) */ 151 #define HDA_SAVED_STATE_VERSION_5 5 151 152 /** Since this version the number of MMIO registers can be flexible. */ 152 #define HDA_S SM_VERSION_4 4153 #define HDA_S SM_VERSION_3 3154 #define HDA_S SM_VERSION_2 2155 #define HDA_S SM_VERSION_1 1153 #define HDA_SAVED_STATE_VERSION_4 4 154 #define HDA_SAVED_STATE_VERSION_3 3 155 #define HDA_SAVED_STATE_VERSION_2 2 156 #define HDA_SAVED_STATE_VERSION_1 1 156 157 /** @} */ 157 158
Note:
See TracChangeset
for help on using the changeset viewer.