VirtualBox

Changeset 88055 in vbox for trunk/include


Ignore:
Timestamp:
Mar 9, 2021 2:39:16 PM (4 years ago)
Author:
vboxsync
Message:

Audio: Moved the host audio device enumeration code to PDM (VBox/vmm/pdmaudiohostenuminline.h). bugref:9890

Location:
trunk/include/VBox/vmm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/vmm/pdmaudiohostenuminline.h

    r88054 r88055  
    7373        pDev->uMagic = PDMAUDIOHOSTDEV_MAGIC;
    7474        pDev->cbSelf = (uint32_t)cb;
    75         RTListInit(&pDev->Node);
     75        RTListInit(&pDev->ListEntry);
    7676
    7777        //pDev->cMaxInputChannels  = 0;
     
    119119    {
    120120        memcpy(pDevDup, pDev, cbToDup);
    121         RTListInit(&pDevDup->Node);
     121        RTListInit(&pDevDup->ListEntry);
    122122        pDev->cbSelf = cbToDup;
    123123    }
     
    156156
    157157        PPDMAUDIOHOSTDEV pDev, pDevNext;
    158         RTListForEachSafe(&pDevEnm->LstDevices, pDev, pDevNext, PDMAUDIOHOSTDEV, Node)
    159         {
    160             RTListNodeRemove(&pDev->Node);
     158        RTListForEachSafe(&pDevEnm->LstDevices, pDev, pDevNext, PDMAUDIOHOSTDEV, ListEntry)
     159        {
     160            RTListNodeRemove(&pDev->ListEntry);
    161161
    162162            PDMAudioHostDevFree(pDev);
     
    185185    Assert(pDevEnm->uMagic == PDMAUDIOHOSTENUM_MAGIC);
    186186
    187     RTListAppend(&pDevEnm->LstDevices, &pDev->Node);
     187    RTListAppend(&pDevEnm->LstDevices, &pDev->ListEntry);
    188188    pDevEnm->cDevices++;
    189189}
     
    211211
    212212    PPDMAUDIOHOSTDEV pSrcDev;
    213     RTListForEach(&pSrcDevEnm->LstDevices, pSrcDev, PDMAUDIOHOSTDEV, Node)
     213    RTListForEach(&pSrcDevEnm->LstDevices, pSrcDev, PDMAUDIOHOSTDEV, ListEntry)
    214214    {
    215215        if (   enmUsage == pSrcDev->enmUsage
     
    244244
    245245    PPDMAUDIOHOSTDEV pDev;
    246     RTListForEach(&pDevEnm->LstDevices, pDev, PDMAUDIOHOSTDEV, Node)
     246    RTListForEach(&pDevEnm->LstDevices, pDev, PDMAUDIOHOSTDEV, ListEntry)
    247247    {
    248248        if (pDev->fFlags & PDMAUDIOHOSTDEV_F_DEFAULT)
     
    275275    uint32_t        cDevs = 0;
    276276    PPDMAUDIOHOSTDEV pDev;
    277     RTListForEach(&pDevEnm->LstDevices, pDev, PDMAUDIOHOSTDEV, Node)
     277    RTListForEach(&pDevEnm->LstDevices, pDev, PDMAUDIOHOSTDEV, ListEntry)
    278278    {
    279279        if (enmUsage == pDev->enmUsage)
     
    335335DECLINLINE(void) PDMAudioHostEnumLog(PCPDMAUDIOHOSTENUM pDevEnm, const char *pszDesc)
    336336{
     337#ifdef LOG_ENABLED
    337338    AssertPtrReturnVoid(pDevEnm);
    338339    AssertPtrReturnVoid(pszDesc);
     
    344345
    345346        PPDMAUDIOHOSTDEV pDev;
    346         RTListForEach(&pDevEnm->LstDevices, pDev, PDMAUDIOHOSTDEV, Node)
     347        RTListForEach(&pDevEnm->LstDevices, pDev, PDMAUDIOHOSTDEV, ListEntry)
    347348        {
    348349            char szFlags[PDMAUDIOHOSTDEV_MAX_FLAGS_STRING_LEN];
     
    355356        }
    356357    }
     358#else
     359    RT_NOREF(pDevEnm, pszDesc);
     360#endif
    357361}
    358362
  • trunk/include/VBox/vmm/pdmaudioifs.h

    r88045 r88055  
    360360{
    361361    /** List entry (like PDMAUDIOHOSTENUM::LstDevices). */
    362     RTLISTNODE          Node;
     362    RTLISTNODE          ListEntry;
    363363    /** Magic value (PDMAUDIOHOSTDEV_MAGIC). */
    364364    uint32_t            uMagic;
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette