Changeset 82373 in vbox for trunk/src/VBox/Devices/Audio
- Timestamp:
- Dec 4, 2019 10:38:41 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevIchAc97.cpp
r82371 r82373 124 124 /** @name Extended Audio ID Register (EAID). 125 125 * @{ */ 126 #define AC97_EAID_VRA RT_BIT(0) 127 #define AC97_EAID_VRM RT_BIT(3) 128 #define AC97_EAID_REV0 RT_BIT(10) 129 #define AC97_EAID_REV1 RT_BIT(11) 126 #define AC97_EAID_VRA RT_BIT(0) /**< Variable Rate Audio. */ 127 #define AC97_EAID_VRM RT_BIT(3) /**< Variable Rate Mic Audio. */ 128 #define AC97_EAID_REV0 RT_BIT(10) /**< AC'97 revision compliance. */ 129 #define AC97_EAID_REV1 RT_BIT(11) /**< AC'97 revision compliance. */ 130 130 /** @} */ 131 131 132 132 /** @name Extended Audio Control and Status Register (EACS). 133 133 * @{ */ 134 #define AC97_EACS_VRA RT_BIT(0) 135 #define AC97_EACS_VRM RT_BIT(3) 134 #define AC97_EACS_VRA RT_BIT(0) /**< Variable Rate Audio (4.2.1.1). */ 135 #define AC97_EACS_VRM RT_BIT(3) /**< Variable Rate Mic Audio (4.2.1.1). */ 136 136 /** @} */ 137 137 138 138 /** @name Baseline Audio Register Set (BARS). 139 139 * @{ */ 140 #define AC97_BARS_VOL_MASK 0x1f 141 #define AC97_BARS_GAIN_MASK 0x0f 142 #define AC97_BARS_VOL_MUTE_SHIFT 15 140 #define AC97_BARS_VOL_MASK 0x1f /**< Volume mask for the Baseline Audio Register Set (5.7.2). */ 141 #define AC97_BARS_GAIN_MASK 0x0f /**< Gain mask for the Baseline Audio Register Set. */ 142 #define AC97_BARS_VOL_MUTE_SHIFT 15 /**< Mute bit shift for the Baseline Audio Register Set (5.7.2). */ 143 143 /** @} */ 144 144 … … 161 161 /** @name Mixer registers / NAM BAR registers? 162 162 * @{ */ 163 enum 164 { 165 AC97_Reset = 0x00, 166 AC97_Master_Volume_Mute = 0x02, 167 AC97_Headphone_Volume_Mute = 0x04, /**< Also known as AUX, see table 16, section 5.7. */ 168 AC97_Master_Volume_Mono_Mute = 0x06, 169 AC97_Master_Tone_RL = 0x08, 170 AC97_PC_BEEP_Volume_Mute = 0x0a, 171 AC97_Phone_Volume_Mute = 0x0c, 172 AC97_Mic_Volume_Mute = 0x0e, 173 AC97_Line_In_Volume_Mute = 0x10, 174 AC97_CD_Volume_Mute = 0x12, 175 AC97_Video_Volume_Mute = 0x14, 176 AC97_Aux_Volume_Mute = 0x16, 177 AC97_PCM_Out_Volume_Mute = 0x18, 178 AC97_Record_Select = 0x1a, 179 AC97_Record_Gain_Mute = 0x1c, 180 AC97_Record_Gain_Mic_Mute = 0x1e, 181 AC97_General_Purpose = 0x20, 182 AC97_3D_Control = 0x22, 183 AC97_AC_97_RESERVED = 0x24, 184 AC97_Powerdown_Ctrl_Stat = 0x26, 185 AC97_Extended_Audio_ID = 0x28, 186 AC97_Extended_Audio_Ctrl_Stat = 0x2a, 187 AC97_PCM_Front_DAC_Rate = 0x2c, 188 AC97_PCM_Surround_DAC_Rate = 0x2e, 189 AC97_PCM_LFE_DAC_Rate = 0x30, 190 AC97_PCM_LR_ADC_Rate = 0x32, 191 AC97_MIC_ADC_Rate = 0x34, 192 AC97_6Ch_Vol_C_LFE_Mute = 0x36, 193 AC97_6Ch_Vol_L_R_Surround_Mute = 0x38, 194 AC97_Vendor_Reserved = 0x58, 195 AC97_AD_Misc = 0x76, 196 AC97_Vendor_ID1 = 0x7c, 197 AC97_Vendor_ID2 = 0x7e 198 }; 163 #define AC97_Reset 0x00 164 #define AC97_Master_Volume_Mute 0x02 165 #define AC97_Headphone_Volume_Mute 0x04 /**< Also known as AUX, see table 16, section 5.7. */ 166 #define AC97_Master_Volume_Mono_Mute 0x06 167 #define AC97_Master_Tone_RL 0x08 168 #define AC97_PC_BEEP_Volume_Mute 0x0a 169 #define AC97_Phone_Volume_Mute 0x0c 170 #define AC97_Mic_Volume_Mute 0x0e 171 #define AC97_Line_In_Volume_Mute 0x10 172 #define AC97_CD_Volume_Mute 0x12 173 #define AC97_Video_Volume_Mute 0x14 174 #define AC97_Aux_Volume_Mute 0x16 175 #define AC97_PCM_Out_Volume_Mute 0x18 176 #define AC97_Record_Select 0x1a 177 #define AC97_Record_Gain_Mute 0x1c 178 #define AC97_Record_Gain_Mic_Mute 0x1e 179 #define AC97_General_Purpose 0x20 180 #define AC97_3D_Control 0x22 181 #define AC97_AC_97_RESERVED 0x24 182 #define AC97_Powerdown_Ctrl_Stat 0x26 183 #define AC97_Extended_Audio_ID 0x28 184 #define AC97_Extended_Audio_Ctrl_Stat 0x2a 185 #define AC97_PCM_Front_DAC_Rate 0x2c 186 #define AC97_PCM_Surround_DAC_Rate 0x2e 187 #define AC97_PCM_LFE_DAC_Rate 0x30 188 #define AC97_PCM_LR_ADC_Rate 0x32 189 #define AC97_MIC_ADC_Rate 0x34 190 #define AC97_6Ch_Vol_C_LFE_Mute 0x36 191 #define AC97_6Ch_Vol_L_R_Surround_Mute 0x38 192 #define AC97_Vendor_Reserved 0x58 193 #define AC97_AD_Misc 0x76 194 #define AC97_Vendor_ID1 0x7c 195 #define AC97_Vendor_ID2 0x7e 199 196 /** @} */ 200 197 201 198 /** @name Analog Devices miscellaneous regiter bits used in AD1980. 202 199 * @{ */ 203 #define AC97_AD_MISC_LOSEL RT_BIT(5) /**< Surround (rear) goes to line out outputs. */204 #define AC97_AD_MISC_HPSEL RT_BIT(10) /**< PCM (front) goes to headphone outputs. */200 #define AC97_AD_MISC_LOSEL RT_BIT(5) /**< Surround (rear) goes to line out outputs. */ 201 #define AC97_AD_MISC_HPSEL RT_BIT(10) /**< PCM (front) goes to headphone outputs. */ 205 202 /** @} */ 206 203 … … 208 205 /** @name BUP flag values. 209 206 * @{ */ 210 #define BUP_SET RT_BIT_32(0)211 #define BUP_LAST RT_BIT_32(1)207 #define BUP_SET RT_BIT_32(0) 208 #define BUP_LAST RT_BIT_32(1) 212 209 /** @} */ 213 210 … … 217 214 * @{ 218 215 */ 219 #define AC97SOUNDSOURCE_PI_INDEX 0 /**< PCM in */220 #define AC97SOUNDSOURCE_PO_INDEX 1 /**< PCM out */221 #define AC97SOUNDSOURCE_MC_INDEX 2 /**< Mic in */222 #define AC97SOUNDSOURCE_MAX 3 /**< Max sound sources. */216 #define AC97SOUNDSOURCE_PI_INDEX 0 /**< PCM in */ 217 #define AC97SOUNDSOURCE_PO_INDEX 1 /**< PCM out */ 218 #define AC97SOUNDSOURCE_MC_INDEX 2 /**< Mic in */ 219 #define AC97SOUNDSOURCE_MAX 3 /**< Max sound sources. */ 223 220 /** @} */ 224 221 … … 260 257 * @{ */ 261 258 /** NABMBAR: Global Control Register. */ 262 #define AC97_GLOB_CNT 0x2c259 #define AC97_GLOB_CNT 0x2c 263 260 /** NABMBAR: Global Status. */ 264 #define AC97_GLOB_STA 0x30261 #define AC97_GLOB_STA 0x30 265 262 /** Codec Access Semaphore Register. */ 266 #define AC97_CAS 0x34263 #define AC97_CAS 0x34 267 264 /** @} */ 268 265 269 #define AC97_PORT2IDX(a_idx) ( ((a_idx) >> 4) & 3 )266 #define AC97_PORT2IDX(a_idx) ( ((a_idx) >> 4) & 3 ) 270 267 271 268
Note:
See TracChangeset
for help on using the changeset viewer.