VirtualBox

Changeset 52675 in vbox for trunk/src/VBox/VMM/VMMR3


Ignore:
Timestamp:
Sep 10, 2014 1:24:03 PM (10 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
95998
Message:

VMM/GIM: Fix circular dependency between PDM and GIM init. routines.

Location:
trunk/src/VBox/VMM/VMMR3
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR3/GIM.cpp

    r52247 r52675  
    148148}
    149149
    150 #if 0
    151 VMM_INT_DECL(int) GIMR3InitFinalize(PVM pVM)
     150
     151VMMR3_INT_DECL(int) GIMR3InitFinalize(PVM pVM)
    152152{
    153153    LogFlow(("GIMR3InitFinalize\n"));
     
    156156        return VINF_SUCCESS;
    157157
     158    int rc = VINF_SUCCESS;
    158159    switch (pVM->gim.s.enmProviderId)
    159160    {
    160161        case GIMPROVIDERID_MINIMAL:
    161162        {
    162             GIMR3MinimalInitFinalize(pVM);
    163             break;
    164         }
    165 
    166         case GIMPROVIDERID_HYPERV:
    167         {
    168             GIMR3HvInitFinalize(pVM);
    169             break;
    170         }
    171 
    172         case GIMPROVIDERID_KVM:            /** @todo KVM. */
     163            rc = GIMR3MinimalInitFinalize(pVM);
     164            break;
     165        }
     166
    173167        default:
    174         {
    175             AssertMsgFailed(("Invalid provider Id %#x\n", pVM->gim.s.enmProviderId));
    176             break;
    177         }
    178     }
    179 }
    180 #endif
     168            break;
     169    }
     170    return rc;
     171}
    181172
    182173
  • trunk/src/VBox/VMM/VMMR3/GIMMinimal.cpp

    r52674 r52675  
    4646    CPUMSetGuestCpuIdFeature(pVM, CPUMCPUIDFEATURE_HVP);
    4747
     48    return VINF_SUCCESS;
     49}
     50
     51
     52VMMR3_INT_DECL(int) GIMR3MinimalInitFinalize(PVM pVM)
     53{
    4854    /*
    4955     * Expose a generic hypervisor-agnostic leaf (originally defined VMware).
    5056     * The leaves range from  0x40000010 to 0x400000FF.
     57     *
     58     * This is done in the finalize routine as we need PDM to be
     59     * initialized (otherwise PDMApicGetTimerFreq() would fail).
    5160     */
    5261    CPUMCPUIDLEAF HyperLeaf;
     
    8392}
    8493
    85 
    8694VMMR3_INT_DECL(void) GIMR3MinimalRelocate(PVM pVM, RTGCINTPTR offDelta)
    8795{
  • trunk/src/VBox/VMM/VMMR3/VM.cpp

    r52419 r52675  
    10121012#endif
    10131013                                                                            if (RT_SUCCESS(rc))
     1014                                                                                rc = GIMR3InitFinalize(pVM);
     1015                                                                            if (RT_SUCCESS(rc))
    10141016                                                                            {
    10151017                                                                                PGMR3MemSetup(pVM, false /*fAtReset*/);
Note: See TracChangeset for help on using the changeset viewer.

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