VirtualBox

Changeset 56381 in vbox


Ignore:
Timestamp:
Jun 12, 2015 11:50:53 AM (10 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
100980
Message:

Stubbed VMMR0_DO_CALL_HYPERVISOR and VMMR0_DO_RAW_RUN when !VBOX_WITH_RAW_MODE.

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/err.h

    r56080 r56381  
    8989/** Invalid CPU index. */
    9090#define VERR_INVALID_CPU_INDEX              (-1022)
     91/** This VirtualBox build does not support raw-mode. */
     92#define VERR_RAW_MODE_NOT_SUPPORTED         (-1023)
    9193/** @} */
    9294
  • trunk/include/VBox/vmm/hm.h

    r55863 r56381  
    175175VMMR0_INT_DECL(int)             HMR0TermVM(PVM pVM);
    176176VMMR0_INT_DECL(int)             HMR0EnableAllCpus(PVM pVM);
     177# ifdef VBOX_WITH_RAW_MODE
    177178VMMR0_INT_DECL(int)             HMR0EnterSwitcher(PVM pVM, VMMSWITCHER enmSwitcher, bool *pfVTxDisabled);
    178179VMMR0_INT_DECL(void)            HMR0LeaveSwitcher(PVM pVM, bool fVTxDisabled);
     180# endif
    179181
    180182VMMR0_INT_DECL(void)            HMR0SavePendingIOPortWrite(PVMCPU pVCpu, RTGCPTR GCPtrRip, RTGCPTR GCPtrRipNext,
  • trunk/src/VBox/VMM/VMMR0/HMR0.cpp

    r56365 r56381  
    16261626}
    16271627
     1628#ifdef VBOX_WITH_RAW_MODE
    16281629
    16291630/**
     
    17261727}
    17271728
     1729#endif /* VBOX_WITH_RAW_MODE */
    17281730#ifdef VBOX_STRICT
    17291731
  • trunk/src/VBox/VMM/VMMR0/VMMR0.cpp

    r56287 r56381  
    875875        case VMMR0_DO_RAW_RUN:
    876876        {
    877 #ifndef VBOX_WITH_2X_4GB_ADDR_SPACE_IN_R0
     877#ifdef VBOX_WITH_RAW_MODE
     878# ifndef VBOX_WITH_2X_4GB_ADDR_SPACE_IN_R0
    878879            /* Some safety precautions first. */
    879880            if (RT_UNLIKELY(!PGMGetHyperCR3(pVCpu)))
     
    882883                break;
    883884            }
    884 #endif
     885# endif
    885886
    886887            /*
     
    902903                 * Commit the CPU identifiers and update the periodict preemption timer if it's active.
    903904                 */
    904 #ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
     905# ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
    905906                CPUMR0SetLApic(pVCpu, iHostCpuSet);
    906 #endif
     907# endif
    907908                pVCpu->iHostCpuSet = iHostCpuSet;
    908909                ASMAtomicWriteU32(&pVCpu->idHostCpu, idHostCpu);
     
    954955                    /* Fire dtrace probe and collect statistics. */
    955956                    VBOXVMM_R0_VMM_RETURN_TO_RING3_RC(pVCpu, CPUMQueryGuestCtxPtr(pVCpu), rc);
    956 #ifdef VBOX_WITH_STATISTICS
     957# ifdef VBOX_WITH_STATISTICS
    957958                    STAM_COUNTER_INC(&pVM->vmm.s.StatRunRC);
    958959                    vmmR0RecordRC(pVM, pVCpu, rc);
    959 #endif
     960# endif
    960961                }
    961962                else
     
    989990                    pVCpu->vmm.s.iLastGZRc = VERR_INVALID_CPU_INDEX;
    990991            }
     992
     993#else  /* !VBOX_WITH_RAW_MODE */
     994            pVCpu->vmm.s.iLastGZRc = VERR_RAW_MODE_NOT_SUPPORTED;
     995#endif
    991996            break;
    992997        }
     
    13421347        case VMMR0_DO_CALL_HYPERVISOR:
    13431348        {
     1349#ifdef VBOX_WITH_RAW_MODE
    13441350            /*
    13451351             * Validate input / context.
     
    13501356                return VERR_INVALID_PARAMETER;
    13511357            PVMCPU pVCpu = &pVM->aCpus[idCpu];
    1352 #ifndef VBOX_WITH_2X_4GB_ADDR_SPACE_IN_R0
     1358# ifndef VBOX_WITH_2X_4GB_ADDR_SPACE_IN_R0
    13531359            if (RT_UNLIKELY(!PGMGetHyperCR3(pVCpu)))
    13541360                return VERR_PGM_NO_CR3_SHADOW_ROOT;
    1355 #endif
     1361# endif
    13561362
    13571363            /*
     
    13841390             * Commit the CPU identifiers.
    13851391             */
    1386 #ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
     1392# ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
    13871393            CPUMR0SetLApic(pVCpu, iHostCpuSet);
    1388 #endif
     1394# endif
    13891395            pVCpu->iHostCpuSet = iHostCpuSet;
    13901396            ASMAtomicWriteU32(&pVCpu->idHostCpu, idHostCpu);
     
    14191425            ASMSetFlags(fFlags);
    14201426            return rc;
     1427
     1428#else  /* !VBOX_WITH_RAW_MODE */
     1429            return VERR_RAW_MODE_NOT_SUPPORTED;
     1430#endif
    14211431        }
    14221432
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