Changeset 31028 in vbox for trunk/src/VBox/Devices/Audio
- Timestamp:
- Jul 23, 2010 3:33:34 AM (14 years ago)
- Location:
- trunk/src/VBox/Devices/Audio
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevCodec.cpp
r30992 r31028 90 90 CODEC_CAD(cmd), CODEC_DIRECT(cmd) ? 'N' : 'Y', CODEC_NID(cmd), CODEC_VERBDATA(cmd))); 91 91 if (CODEC_CAD(cmd) != 0) 92 *pResp = ((uint64_t)CODEC_CAD(cmd) << 4)| 0x FFFFFFFF;92 *pResp = ((uint64_t)CODEC_CAD(cmd) << 4)| 0x0; 93 93 else 94 94 *pResp = 0; … … 225 225 case 1: 226 226 pNode->afg.node.name = "AFG"; 227 //** @todo r=michaln: Are the comments right? Looks like copy & paste. 228 pNode->node.au32F00_param[4] = RT_MAKE_U32_FROM_U8(0x1a, 0x00, 0x02, 0x00); /* node info (start node: 1, start id = 1) */ 229 pNode->node.au32F00_param[5] = RT_MAKE_U32_FROM_U8(0x1, 0x01, 0x00, 0x0); /* node info (start node: 1, start id = 1) */ 227 pNode->node.au32F00_param[4] = RT_MAKE_U32_FROM_U8(0x1a, 0x00, 0x02, 0x00); 228 pNode->node.au32F00_param[5] = RT_MAKE_U32_FROM_U8(0x1, 0x01, 0x00, 0x0); 230 229 pNode->node.au32F00_param[8] = RT_MAKE_U32_FROM_U8(0x0d, 0x0d, 0x01, 0x0); /* Capabilities */ 231 230 //pNode->node.au32F00_param[0xa] = RT_BIT(19)|RT_BIT(18)|RT_BIT(17)|RT_BIT(10)|RT_BIT(9)|RT_BIT(8)|RT_BIT(7)|RT_BIT(6)|RT_BIT(5); … … 391 390 pNode->node.name = "VolumeKnob"; 392 391 pNode->node.au32F00_param[0x9] = (0x6 << 20); 393 //** @todo r=michaln: The next assignment is out of array bounds (0x13 items in array);394 // the array needs to be bigger.395 392 pNode->node.au32F00_param[0x13] = RT_BIT(7)| 0x7F; 396 393 pNode->node.au32F00_param[0xe] = 0x4; … … 582 579 pState->cVerbs = STAC9220_VERB_SIZE; 583 580 pState->pfnLookup = codecLookup; 584 //** @todo r=michaln: Where is this memory freed?585 581 pState->pNodes = (PCODECNODE)RTMemAllocZ(sizeof(CODECNODE) * STAC9220_NODE_COUNT); 586 582 uint8_t i; … … 610 606 return VINF_SUCCESS; 611 607 } 612 int stac9220Destruct(CODECState *pCodecState); 608 int stac9220Destruct(CODECState *pCodecState) 609 { 610 RTMemFree(pCodecState->pNodes); 611 return VINF_SUCCESS; 612 } -
trunk/src/VBox/Devices/Audio/DevCodec.h
r30985 r31028 32 32 } CODECVERB; 33 33 34 #define CODECNODE_F0_PARAM_LENGTH 0x1 334 #define CODECNODE_F0_PARAM_LENGTH 0x14 35 35 typedef struct CODECCOMMONNODE 36 36 { -
trunk/src/VBox/Devices/Audio/DevIchIntelHDA.cpp
r31015 r31028 80 80 #define ICH6_HDA_REG_STATES 7 /* range 0x0E */ 81 81 #define STATES(pState) (HDA_REG((pState), STATES)) 82 #define ICH6_HDA_STATES_SCSF 0x 582 #define ICH6_HDA_STATES_SCSF 0x1 83 83 84 84 #define ICH6_HDA_REG_GSTS 8 /* range 0x10-0x11*/ … … 585 585 if (INTCTL_GIE(pState)) 586 586 { 587 //** @todo r=michaln: This *must* be PCISetIrq instead588 589 587 Log(("hda: irq %s\n", fIrq ? "asserted" : "deasserted")); 590 588 PDMDevHlpPCISetIrq(ICH6_HDASTATE_2_DEVINS(pState), 0 , fIrq); … … 1345 1343 pThis->hda.cbCorbBuf = CORBSIZE(&pThis->hda) * sizeof(uint32_t); 1346 1344 1347 //** @todo r=michaln: Where are the Corb/RirbBuf allocations freed?1348 1345 if (pThis->hda.pu32CorbBuf) 1349 1346 memset(pThis->hda.pu32CorbBuf, 0, pThis->hda.cbCorbBuf); … … 1495 1492 pThis->hda.Codec.pfnTransfer = hdaTransfer; 1496 1493 1494 return VINF_SUCCESS; 1495 } 1496 1497 /** 1498 * @interface_method_impl{PDMDEVREG,pfnDestruct} 1499 */ 1500 static DECLCALLBACK(int) hdaDestruct (PPDMDEVINS pDevIns) 1501 { 1502 PCIINTELHDLinkState *pThis = PDMINS_2_DATA(pDevIns, PCIINTELHDLinkState *); 1503 1504 int rc = stac9220Destruct(&pThis->hda.Codec); 1505 AssertRC(rc); 1506 if (pThis->hda.pu32CorbBuf) 1507 RTMemFree(pThis->hda.pu32CorbBuf); 1508 if (pThis->hda.pu32CorbBuf) 1509 RTMemFree(pThis->hda.pu32CorbBuf); 1497 1510 return VINF_SUCCESS; 1498 1511 } … … 1524 1537 hdaConstruct, 1525 1538 /* pfnDestruct */ 1526 NULL,1539 hdaDestruct, 1527 1540 /* pfnRelocate */ 1528 1541 NULL,
Note:
See TracChangeset
for help on using the changeset viewer.