flag (ULONG) - input

      Allocate attribute and desired access protection flags.

      A set of flags describing the allocation attributes and desired access protection for the private memory object. Possible values are shown in the lists below:

      Allocation Attributes

      PAG_COMMIT (0x00000010)

        All pages in the private memory object are initially committed.
      OBJ_TILE (0x00000040)
        The private memory object must be allocated in the first 512MB of virtual-address space, with 16-bit selectors mapping the memory object.
      The 16-bit selectors are allocated to map the 32-bit object at 64KB boundaries. The figure below shows how the 16-bit alias selectors map the 32-bit object.
          32-bit             32-bit               16-bit alias
          Offset             Object               Selectors
      
         BaseAddress+000KBÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿ ÄÄÄÄÄ Sel
                          ³              ³
         BaseAddress+064KBÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´ ÄÄÄÄÄ Sel+HugeInc
                          ³              ³
         BaseAddress+128KBÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´ ÄÄÄÄÄ Sel+HugeInc*2
                          ³              ³
         BaseAddress+192KBÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´ ÄÄÄÄÄ Sel+HugeInc*3
                          ³              ³
      
      HugeInc is the huge increment used for DosAllocHuge.
      
      

      Desired Access Protection

      PAG_EXECUTE (0x00000004)

        Execute access to the committed pages in the private memory object
      PAG_READ (0x00000001)
        Read access
      PAG_WRITE (0x00000002)
        Write access
      PAG_GUARD (0x00000008)
        Access to the committed pages in the private memory object causes a "guard page entered" condition to be raised in the subject process.
      At least one of the bits PAG_READ, PAG_WRITE, or PAG_EXECUTE must be set.


    [Back] [Next]