Changeset 31062 in vbox
- Timestamp:
- Jul 23, 2010 1:34:08 PM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 63993
- Location:
- trunk/src/VBox/Devices/Audio
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevCodec.cpp
r31050 r31062 89 89 CODEC_NID(cmd) == 0x12 \ 90 90 || CODEC_NID(cmd) == 0x13) 91 92 93 static int stac9220ResetNode(struct CODECState *pState, uint8_t nodenum, PCODECNODE pNode); 94 95 91 96 static int codecUnimplemented(struct CODECState *pState, uint32_t cmd, uint64_t *pResp) 92 97 { … … 182 187 *pResp = pState->pNodes[CODEC_NID(cmd)].afg.u32F20_param; 183 188 } 189 return VINF_SUCCESS; 190 } 191 192 static int codecReset(struct CODECState *pState, uint32_t cmd, uint64_t *pResp) 193 { 194 Assert((CODEC_CAD(cmd) == 0)); 195 Assert(STAC9220_IS_AFG_CMD(cmd)); 196 if(STAC9220_IS_AFG_CMD(cmd)) 197 { 198 uint8_t i; 199 Log(("HDAcodec: enters reset\n")); 200 for (i = 0; i < STAC9220_NODE_COUNT; ++i) 201 { 202 stac9220ResetNode(pState, i, &pState->pNodes[i]); 203 } 204 pState->pfnReset(pState); 205 Log(("HDAcodec: exits reset\n")); 206 } 207 *pResp = 0; 184 208 return VINF_SUCCESS; 185 209 } … … 263 287 pNode->node.au32F00_param[0x12] = RT_BIT(31)|(0x2 << 16)|(0x7f << 8)|0x7f; 264 288 pNode->afg.u32F05_param = (0x2) << 4 | 0x2; /* PS-Act: 0x2, D2 */ 265 pNode->afg.u32F20_param = 0x 106b0800; /* Old Intel Mac*/289 pNode->afg.u32F20_param = 0x83847626; /*STAC9271X */ 266 290 pNode->afg.u32F08_param = 0; 267 291 break; … … 459 483 {0x000F0200, CODEC_VERB_8BIT_CMD , codecGetF02 }, 460 484 {0x000F2000, CODEC_VERB_8BIT_CMD , codecGetSubId }, 485 {0x0007FF00, CODEC_VERB_8BIT_CMD , codecReset }, 461 486 #if 0 462 487 {0x000F0500, CODEC_VERB_8BIT_CMD , codecGetPowerState}, -
trunk/src/VBox/Devices/Audio/DevCodec.h
r31028 r31062 197 197 typedef struct CODECState 198 198 { 199 uint16_t id; 199 200 CODECVERB *pVerbs; 200 201 int cVerbs; -
trunk/src/VBox/Devices/Audio/DevIchIntelHDA.cpp
r31042 r31062 1159 1159 } 1160 1160 1161 DECLCALLBACK(int) hdaCodecReset(CODECState *pCodecState) 1162 { 1163 INTELHDLinkState *pState = (INTELHDLinkState *)pCodecState->pHDAState; 1164 STATESTS(pState) |= 1 << (pCodecState->id); 1165 INTSTS(pState) |= HDA_REG_FIELD_FLAG_MASK(INTSTS, CIS); 1166 return VINF_SUCCESS; 1167 } 1161 1168 DECLCALLBACK(void) hdaTransfer(CODECState *pCodecState, ENMSOUNDSOURCE src, int avail) 1162 1169 { … … 1531 1538 AssertRCReturn(rc, rc); 1532 1539 hdaReset (pDevIns); 1540 pThis->hda.Codec.id = 0; 1533 1541 pThis->hda.Codec.pfnTransfer = hdaTransfer; 1542 pThis->hda.Codec.pfnReset = hdaCodecReset; 1534 1543 /* 1535 1544 * 18.2.6,7 defines that values of this registers might be cleared on power on/reset
Note:
See TracChangeset
for help on using the changeset viewer.