VirtualBox

Ignore:
Timestamp:
Apr 16, 2008 1:50:43 PM (17 years ago)
Author:
vboxsync
Message:

corrected #if/#else/#endif comments.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/PGMAllBth.h

    r8034 r8042  
    4141/* Filter out some illegal combinations of guest and shadow paging, so we can remove redundant checks inside functions. */
    4242#if      PGM_GST_TYPE == PGM_TYPE_PAE && PGM_SHW_TYPE != PGM_TYPE_PAE
    43 #error "Invalid combination; PAE guest implies PAE shadow"
     43# error "Invalid combination; PAE guest implies PAE shadow"
    4444#endif
    4545
    4646#if     (PGM_GST_TYPE == PGM_TYPE_REAL || PGM_GST_TYPE == PGM_TYPE_PROT) \
    4747    && !(PGM_SHW_TYPE == PGM_TYPE_32BIT || PGM_SHW_TYPE == PGM_TYPE_PAE)
    48 #error "Invalid combination; real or protected mode without paging implies 32 bits or PAE shadow paging."
     48# error "Invalid combination; real or protected mode without paging implies 32 bits or PAE shadow paging."
    4949#endif
    5050
    5151#if     (PGM_GST_TYPE == PGM_TYPE_32BIT || PGM_GST_TYPE == PGM_TYPE_PAE) \
    5252    && !(PGM_SHW_TYPE == PGM_TYPE_32BIT || PGM_SHW_TYPE == PGM_TYPE_PAE)
    53 #error "Invalid combination; 32 bits guest paging or PAE implies 32 bits or PAE shadow paging."
     53# error "Invalid combination; 32 bits guest paging or PAE implies 32 bits or PAE shadow paging."
    5454#endif
    5555
    5656#if    (PGM_GST_TYPE == PGM_TYPE_AMD64 && PGM_SHW_TYPE != PGM_TYPE_AMD64)
    5757    || (PGM_SHW_TYPE == PGM_TYPE_AMD64 && PGM_GST_TYPE != PGM_TYPE_AMD64)
    58 #error "Invalid combination; AMD64 guest implies AMD64 shadow and vice versa"
     58# error "Invalid combination; AMD64 guest implies AMD64 shadow and vice versa"
    5959#endif
    6060
    6161#ifdef IN_RING0 /* no mappings in VT-x and AMD-V mode */
    62 #define PGM_WITHOUT_MAPPINGS
     62# define PGM_WITHOUT_MAPPINGS
    6363#endif
    6464
     
    842842    PX86PDPAE       pPDSrc      = pgmGstGetPaePDPtr(&pVM->pgm.s, GCPtrPage, &iPDSrc);
    843843    GSTPDE          PdeSrc;
    844    
     844
    845845    if (pPDSrc)
    846846        PdeSrc = pPDSrc->a[iPDSrc];
     
    16711671        ||  (fNoExecuteBitValid && (uErr & X86_TRAP_PF_ID) && pPdpeSrc->n.u1NoExecute)
    16721672        ||  (fWriteFault && !pPdpeSrc->n.u1Write && (fUserLevelFault || fWriteProtect))
    1673         ||  (fUserLevelFault && !pPdpeSrc->n.u1User) 
     1673        ||  (fUserLevelFault && !pPdpeSrc->n.u1User)
    16741674# endif
    16751675       )
     
    19951995# else  /* PGM_WITHOUT_MAPPINGS */
    19961996    Assert(!pgmMapAreMappingsEnabled(&pVM->pgm.s));
    1997 # endif /* !PGM_WITHOUT_MAPPINGS */
     1997# endif /* PGM_WITHOUT_MAPPINGS */
    19981998    Assert(!PdeDst.n.u1Present); /* We're only supposed to call SyncPT on PDE!P and conflicts.*/
    19991999
     
    27362736                &&  (PdeSrc.n.u1User || fRawR0Enabled))
    27372737            {
    2738 #  if    (PGM_GST_TYPE == PGM_TYPE_32BIT \
    2739       ||  PGM_GST_TYPE == PGM_TYPE_PAE) \
     2738#  if    (   PGM_GST_TYPE == PGM_TYPE_32BIT \
     2739          || PGM_GST_TYPE == PGM_TYPE_PAE) \
    27402740      && !defined(PGM_WITHOUT_MAPPINGS)
    27412741
     
    27802780#   endif
    27812781                }
    2782 #  else  /* PGM_GST_TYPE != PGM_TYPE_32BIT && PGM_GST_TYPE != PGM_TYPE_PAE && PGM_WITHOUT_MAPPINGS */
     2782#  else  /* (PGM_GST_TYPE != PGM_TYPE_32BIT && PGM_GST_TYPE != PGM_TYPE_PAE) || PGM_WITHOUT_MAPPINGS */
    27832783                Assert(!pgmMapAreMappingsEnabled(&pVM->pgm.s));
    2784 #  endif /* (PGM_GST_TYPE == PGM_TYPE_32BIT || PGM_GST_TYPE == PGM_TYPE_PAE) && !PGM_WITHOUT_MAPPINGS */
     2784#  endif /* (PGM_GST_TYPE != PGM_TYPE_32BIT && PGM_GST_TYPE != PGM_TYPE_PAE) || PGM_WITHOUT_MAPPINGS */
    27852785                /*
    27862786                 * Sync page directory entry.
     
    28982898            else
    28992899            {
    2900 #  if    (PGM_GST_TYPE == PGM_TYPE_32BIT \
    2901       || PGM_GST_TYPE == PGM_TYPE_PAE)  \
     2900#  if    (   PGM_GST_TYPE == PGM_TYPE_32BIT \
     2901          || PGM_GST_TYPE == PGM_TYPE_PAE)  \
    29022902      && !defined(PGM_WITHOUT_MAPPINGS)
    29032903
     
    29612961                AssertCompile(PGM_GST_TYPE == PGM_TYPE_32BIT && PGM_SHW_TYPE == PGM_TYPE_PAE);
    29622962#   endif
    2963 #  else  /* PGM_GST_TYPE != PGM_TYPE_32BIT && PGM_GST_TYPE != PGM_TYPE_PAE && PGM_WITHOUT_MAPPINGS */
     2963#  else  /* (PGM_GST_TYPE != PGM_TYPE_32BIT && PGM_GST_TYPE != PGM_TYPE_PAE) || PGM_WITHOUT_MAPPINGS */
    29642964                Assert(!pgmMapAreMappingsEnabled(&pVM->pgm.s));
    2965 #  endif /* (PGM_GST_TYPE == PGM_TYPE_32BIT || PGM_GST_TYPE == PGM_TYPE_PAE) && !PGM_WITHOUT_MAPPINGS */
     2965#  endif /* (PGM_GST_TYPE != PGM_TYPE_32BIT && PGM_GST_TYPE != PGM_TYPE_PAE) || PGM_WITHOUT_MAPPINGS */
    29662966            }
    29672967
     
    30893089            AssertMsg(   pVM->pgm.s.apGstPaePDsHC[i]    == (R3R0PTRTYPE(PX86PDPAE))HCPtr
    30903090                      && pVM->pgm.s.aGCPhysGstPaePDs[i] == GCPhys,
    3091                       ("idx %d apGstPaePDsHC %VHv vs %VHv aGCPhysGstPaePDs %VGp vs %VGp\n", 
     3091                      ("idx %d apGstPaePDsHC %VHv vs %VHv aGCPhysGstPaePDs %VGp vs %VGp\n",
    30923092                       i, pVM->pgm.s.apGstPaePDsHC[i], HCPtr, pVM->pgm.s.aGCPhysGstPaePDs[i], GCPhys));
    30933093        }
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