VirtualBox

Ignore:
Timestamp:
Oct 29, 2019 11:26:34 AM (5 years ago)
Author:
vboxsync
Message:

VMMDev: cleanups. bugref:9218

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/VMMDev/VMMDevState.h

    r81031 r81569  
    127127    PDMCRITSECT         CritSect;
    128128
    129     /** hypervisor address space size */
    130     uint32_t hypervisorSize;
    131 
    132129    /** mouse capabilities of host and guest */
    133     uint32_t mouseCapabilities;
    134     /** absolute mouse position in pixels */
    135     int32_t mouseXAbs;
    136     int32_t mouseYAbs;
     130    uint32_t            fMouseCapabilities;
     131    /** @name Absolute mouse position in pixels
     132     * @{ */
     133    int32_t             xMouseAbs;
     134    int32_t             yMouseAbs;
     135    /** @} */
    137136    /** Does the guest currently want the host pointer to be shown? */
    138     uint32_t fHostCursorRequested;
    139 
    140 #ifdef VBOX_WITH_RAW_MODE_KEEP
    141     /** Pointer to device instance - RC pointer. */
    142     PPDMDEVINSRC pDevInsRC;
    143 #else
    144     uint32_t u32Alignment0;
    145 #endif
     137    uint32_t            fHostCursorRequested;
     138
    146139    /** Pointer to device instance - R3 poitner. */
    147     PPDMDEVINSR3 pDevInsR3;
     140    PPDMDEVINSR3        pDevInsR3;
    148141    /** Pointer to device instance - R0 pointer. */
    149     PPDMDEVINSR0 pDevInsR0;
     142    PPDMDEVINSR0        pDevInsR0;
    150143
    151144    /** LUN\#0 + Status: VMMDev port base interface. */
    152     PDMIBASE IBase;
     145    PDMIBASE            IBase;
    153146    /** LUN\#0: VMMDev port interface. */
    154     PDMIVMMDEVPORT IPort;
     147    PDMIVMMDEVPORT      IPort;
    155148#ifdef VBOX_WITH_HGCM
    156149    /** LUN\#0: HGCM port interface. */
    157     PDMIHGCMPORT IHGCMPort;
     150    PDMIHGCMPORT        IHGCMPort;
    158151//# if HC_ARCH_BITS == 32
    159152//    RTR3PTR      R3PtrAlignment1;
     
    169162#endif
    170163    /** message buffer for backdoor logging. */
    171     char szMsg[512];
     164    char                szMsg[512];
    172165    /** message buffer index. */
    173     uint32_t iMsg;
     166    uint32_t            offMsg;
    174167    /** Alignment padding. */
    175     uint32_t u32Alignment2;
     168    uint32_t            u32Alignment2;
    176169
    177170    /** Statistics counter for slow IRQ ACK. */
    178     STAMCOUNTER StatSlowIrqAck;
     171    STAMCOUNTER         StatSlowIrqAck;
    179172    /** Statistics counter for fast IRQ ACK - R3. */
    180     STAMCOUNTER StatFastIrqAckR3;
     173    STAMCOUNTER         StatFastIrqAckR3;
    181174    /** Statistics counter for fast IRQ ACK - R0 / RC. */
    182     STAMCOUNTER StatFastIrqAckRZ;
    183     /** IRQ number assigned to the device */
    184     uint32_t irq;
    185     /** Current host side event flags */
    186     uint32_t u32HostEventFlags;
    187     /** Mask of events guest is interested in.
     175    STAMCOUNTER         StatFastIrqAckRZ;
     176    /** Current host side event flags - VMMDEV_EVENT_XXX. */
     177    uint32_t            fHostEventFlags;
     178    /** Mask of events guest is interested in - VMMDEV_EVENT_XXX.
    188179     * @note The HGCM events are enabled automatically by the VMMDev device when
    189180     *       guest issues HGCM commands. */
    190     uint32_t u32GuestFilterMask;
    191     /** Delayed mask of guest events */
    192     uint32_t u32NewGuestFilterMask;
    193     /** Flag whether u32NewGuestFilterMask is valid */
    194     bool fNewGuestFilterMask;
     181    uint32_t            fGuestFilterMask;
     182    /** Delayed mask of guest events - VMMDEV_EVENT_XXX. */
     183    uint32_t            fNewGuestFilterMask;
     184    /** Flag whether fNewGuestFilterMask is valid */
     185    bool                fNewGuestFilterMaskValid;
    195186    /** Alignment padding. */
    196     bool afAlignment3[3];
     187    bool                afAlignment3[7];
    197188
    198189    /** GC physical address of VMMDev RAM area */
     
    211202    R3PTRTYPE(VMMDevMemory *) pVMMDevHeapR3;
    212203    /** GC physical address of VMMDev Heap RAM area */
    213     RTGCPHYS32 GCPhysVMMDevHeap;
     204    RTGCPHYS32          GCPhysVMMDevHeap;
    214205
    215206    /** Information reported by guest via VMMDevReportGuestInfo generic request.
    216207     * Until this information is reported the VMMDev refuses any other requests.
    217208     */
    218     VBoxGuestInfo guestInfo;
     209    VBoxGuestInfo       guestInfo;
    219210    /** Information report \#2, chewed a little. */
    220211    struct
    221212    {
    222         uint32_t uFullVersion; /**< non-zero if info is present. */
    223         uint32_t uRevision;
    224         uint32_t fFeatures;
    225         char     szName[128];
    226     } guestInfo2;
     213        uint32_t            uFullVersion; /**< non-zero if info is present. */
     214        uint32_t            uRevision;
     215        uint32_t            fFeatures;
     216        char                szName[128];
     217    }                   guestInfo2;
    227218
    228219    /** Array of guest facility statuses. */
    229     VMMDEVFACILITYSTATUSENTRY   aFacilityStatuses[32];
     220    VMMDEVFACILITYSTATUSENTRY aFacilityStatuses[32];
    230221    /** The number of valid entries in the facility status array. */
    231     uint32_t                    cFacilityStatuses;
    232 
    233     /** Information reported by guest via VMMDevReportGuestCapabilities. */
    234     uint32_t      guestCaps;
     222    uint32_t            cFacilityStatuses;
     223
     224    /** Information reported by guest via VMMDevReportGuestCapabilities - VMMDEV_GUEST_SUPPORTS_XXX. */
     225    uint32_t            fGuestCaps;
    235226
    236227    /** "Additions are Ok" indicator, set to true after processing VMMDevReportGuestInfo,
     
    238229     * of the version in guestInfo.
    239230     */
    240     uint32_t fu32AdditionsOk;
     231    uint32_t            fu32AdditionsOk;
    241232
    242233    /** Video acceleration status set by guest. */
    243     uint32_t u32VideoAccelEnabled;
    244 
    245     DISPLAYCHANGEDATA displayChangeData;
     234    uint32_t            u32VideoAccelEnabled;
     235
     236    DISPLAYCHANGEDATA   displayChangeData;
    246237
    247238    /** Pointer to the credentials. */
     
    249240
    250241#if HC_ARCH_BITS == 32
    251     uint32_t uAlignment4;
    252 #endif
    253 
    254     /* memory balloon change request */
    255     uint32_t    cMbMemoryBalloon;
     242    uint32_t            uAlignment4;
     243#endif
     244
     245    /** memory balloon change request */
     246    uint32_t            cMbMemoryBalloon;
    256247    /** The last balloon size queried by the guest additions. */
    257     uint32_t    cMbMemoryBalloonLast;
    258 
    259     /* guest ram size */
    260     uint64_t    cbGuestRAM;
    261 
    262     /* unique session id; the id will be different after each start, reset or restore of the VM. */
    263     uint64_t    idSession;
    264 
    265     /* statistics interval change request */
    266     uint32_t    u32StatIntervalSize, u32LastStatIntervalSize;
    267 
    268     /* seamless mode change request */
    269     bool fLastSeamlessEnabled, fSeamlessEnabled;
    270     bool afAlignment5[1];
    271 
    272     bool fVRDPEnabled;
    273     uint32_t uVRDPExperienceLevel;
     248    uint32_t            cMbMemoryBalloonLast;
     249
     250    /** guest ram size */
     251    uint64_t            cbGuestRAM;
     252
     253    /** unique session id; the id will be different after each start, reset or restore of the VM. */
     254    uint64_t            idSession;
     255
     256    /** Statistics interval in seconds.  */
     257    uint32_t            cSecsStatInterval;
     258    /** The statistics interval last returned to the guest. */
     259    uint32_t            cSecsLastStatInterval;
     260
     261    /** Whether seamless is enabled or not. */
     262    bool                fSeamlessEnabled;
     263    /** The last fSeamlessEnabled state returned to the guest. */
     264    bool                fLastSeamlessEnabled;
     265    bool                afAlignment5[1];
     266
     267    bool                fVRDPEnabled;
     268    uint32_t            uVRDPExperienceLevel;
    274269
    275270#ifdef VMMDEV_WITH_ALT_TIMESYNC
    276     uint64_t hostTime;
    277     bool fTimesyncBackdoorLo;
    278     bool afAlignment6[2];
     271    uint64_t            msLatchedHostTime;
     272    bool                fTimesyncBackdoorLo;
     273    bool                afAlignment6[2];
    279274#else
    280     bool afAlignment6[1+2];
    281 #endif
     275    bool                afAlignment6[1+2];
     276#endif
     277
    282278    /** Set if GetHostTime should fail.
    283279     * Loaded from the GetHostTimeDisabled configuration value. */
    284     bool fGetHostTimeDisabled;
    285 
     280    bool                fGetHostTimeDisabled;
    286281    /** Set if backdoor logging should be disabled (output will be ignored then) */
    287     bool fBackdoorLogDisabled;
    288 
     282    bool                fBackdoorLogDisabled;
    289283    /** Don't clear credentials */
    290     bool fKeepCredentials;
    291 
     284    bool                fKeepCredentials;
    292285    /** Heap enabled. */
    293     bool fHeapEnabled;
     286    bool                fHeapEnabled;
    294287
    295288    /** Guest Core Dumping enabled. */
    296     bool fGuestCoreDumpEnabled;
    297 
     289    bool                fGuestCoreDumpEnabled;
    298290    /** Guest Core Dump location. */
    299     char szGuestCoreDumpDir[RTPATH_MAX];
    300 
     291    char                szGuestCoreDumpDir[RTPATH_MAX];
    301292    /** Number of additional cores to keep around. */
    302     uint32_t cGuestCoreDumps;
     293    uint32_t            cGuestCoreDumps;
    303294
    304295#ifdef VBOX_WITH_HGCM
    305296    /** List of pending HGCM requests (VBOXHGCMCMD). */
    306     RTLISTANCHORR3 listHGCMCmd;
     297    RTLISTANCHORR3      listHGCMCmd;
    307298    /** Critical section to protect the list. */
    308     RTCRITSECT critsectHGCMCmdList;
     299    RTCRITSECT          critsectHGCMCmdList;
    309300    /** Whether the HGCM events are already automatically enabled. */
    310     uint32_t u32HGCMEnabled;
     301    uint32_t            u32HGCMEnabled;
    311302    /** Saved state version of restored commands. */
    312     uint32_t u32SSMVersion;
    313     RTMEMCACHE  hHgcmCmdCache;
    314     STAMPROFILE StatHgcmCmdArrival;
    315     STAMPROFILE StatHgcmCmdCompletion;
    316     STAMPROFILE StatHgcmCmdTotal;
    317     STAMCOUNTER StatHgcmLargeCmdAllocs;
    318     STAMCOUNTER StatHgcmFailedPageListLocking;
     303    uint32_t            u32SSMVersion;
     304    RTMEMCACHE          hHgcmCmdCache;
     305    STAMPROFILE         StatHgcmCmdArrival;
     306    STAMPROFILE         StatHgcmCmdCompletion;
     307    STAMPROFILE         StatHgcmCmdTotal;
     308    STAMCOUNTER         StatHgcmLargeCmdAllocs;
     309    STAMCOUNTER         StatHgcmFailedPageListLocking;
    319310#endif /* VBOX_WITH_HGCM */
    320     STAMCOUNTER StatReqBufAllocs;
     311    STAMCOUNTER         StatReqBufAllocs;
    321312
    322313    /** Per CPU request 4K sized buffers, allocated as needed. */
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