VirtualBox

Changeset 71738 in vbox for trunk/src/VBox/Devices/Audio


Ignore:
Timestamp:
Apr 7, 2018 9:44:18 PM (7 years ago)
Author:
vboxsync
Message:

DevAC97: AC97SOUNDSOURCE_LAST_INDEX -> AC97SOUNDSOURCE_END_INDEX, as we use 'last' to be inclusive in an enumeration and 'end' to be +1.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Audio/DevIchAc97.cpp

    r71737 r71738  
    188188typedef enum
    189189{
    190     AC97_CODEC_STAC9700 = 0,     /* SigmaTel STAC9700 */
    191     AC97_CODEC_AD1980,           /* Analog Devices AD1980 */
    192     AC97_CODEC_AD1981B           /* Analog Devices AD1981B */
     190    AC97_CODEC_STAC9700 = 0,     /**< SigmaTel STAC9700 */
     191    AC97_CODEC_AD1980,           /**< Analog Devices AD1980 */
     192    AC97_CODEC_AD1981B           /**< Analog Devices AD1981B */
    193193} AC97CODEC;
    194194
    195195/* Analog Devices miscellaneous regiter bits used in AD1980. */
    196 #define AC97_AD_MISC_LOSEL       RT_BIT(5)   /* Surround (rear) goes to line out outputs. */
    197 #define AC97_AD_MISC_HPSEL       RT_BIT(10)  /* PCM (front) goes to headphone outputs. */
     196#define AC97_AD_MISC_LOSEL       RT_BIT(5)   /**< Surround (rear) goes to line out outputs. */
     197#define AC97_AD_MISC_HPSEL       RT_BIT(10)  /**< PCM (front) goes to headphone outputs. */
    198198
    199199#define ICHAC97STATE_2_DEVINS(a_pAC97)   ((a_pAC97)->pDevInsR3)
     
    220220typedef enum
    221221{
    222     AC97SOUNDSOURCE_PI_INDEX = 0, /** PCM in */
    223     AC97SOUNDSOURCE_PO_INDEX,     /** PCM out */
    224     AC97SOUNDSOURCE_MC_INDEX,     /** Mic in */
    225     AC97SOUNDSOURCE_LAST_INDEX
     222    AC97SOUNDSOURCE_PI_INDEX = 0, /**< PCM in */
     223    AC97SOUNDSOURCE_PO_INDEX,     /**< PCM out */
     224    AC97SOUNDSOURCE_MC_INDEX,     /**< Mic in */
     225    AC97SOUNDSOURCE_END_INDEX
    226226} AC97SOUNDSOURCE;
    227227
     
    32203220    SSMR3PutMem(pSSM, pThis->mixer_data, sizeof(pThis->mixer_data));
    32213221
    3222     uint8_t active[AC97SOUNDSOURCE_LAST_INDEX];
     3222    uint8_t active[AC97SOUNDSOURCE_END_INDEX];
    32233223
    32243224    active[AC97SOUNDSOURCE_PI_INDEX] = ichac97StreamIsEnabled(pThis, &pThis->StreamLineIn) ? 1 : 0;
     
    32873287
    32883288    /** @todo r=andy Stream IDs are hardcoded to certain streams. */
    3289     uint8_t uaStrmsActive[AC97SOUNDSOURCE_LAST_INDEX];
     3289    uint8_t uaStrmsActive[AC97SOUNDSOURCE_END_INDEX];
    32903290    SSMR3GetMem(pSSM, uaStrmsActive, sizeof(uaStrmsActive));
    32913291
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