Searched refs:PAGE_SIZE (Results 1 - 25 of 196) sorted by relevance

12345678

/vbox/include/iprt/
H A Dparam.h37 /* Undefine PAGE_SIZE and PAGE_SHIFT to avoid unnecessary noice when clashing
40 #undef PAGE_SIZE macro
50 # define PAGE_SIZE 8192 macro
52 # define PAGE_SIZE 4096 macro
H A Dzero.h42 extern RTDATADECL(uint8_t const) g_abRTZeroPage[PAGE_SIZE];
/vbox/src/VBox/Devices/EFI/Firmware/StdLib/Include/Ipf/machine/
H A Dvmparam.h92 #define PAGE_SIZE (1 << PAGE_SHIFT) macro
93 #define PAGE_MASK (PAGE_SIZE - 1)
98 #define VM_GATEWAY_SIZE PAGE_SIZE
111 #define VM_PHYS_SIZE (USRIOSIZE*PAGE_SIZE)
/vbox/src/VBox/Runtime/r3/
H A Dmemsafer-r3.cpp258 RTRandBytes(pvPages, PAGE_SIZE + pThis->offUser);
260 uint8_t *pbUser = (uint8_t *)pvPages + PAGE_SIZE + pThis->offUser;
264 RTRandBytes(pbUser + pThis->cbUser, (size_t)pThis->cPages * PAGE_SIZE - PAGE_SIZE - pThis->offUser - pThis->cbUser);
300 rc = SUPR3PageProtect(pvPages, NIL_RTR0PTR, 0, PAGE_SIZE, RTMEM_PROT_NONE);
303 rc = SUPR3PageProtect(pvPages, NIL_RTR0PTR, (pThis->cPages - 1) * PAGE_SIZE, PAGE_SIZE, RTMEM_PROT_NONE);
306 SUPR3PageProtect(pvPages, NIL_RTR0PTR, 0, PAGE_SIZE, RTMEM_PROT_READ | RTMEM_PROT_WRITE);
335 void *pvPages = RTMemPageAlloc((size_t)pThis->cPages * PAGE_SIZE);
343 rc = RTMemProtect(pvPages, PAGE_SIZE, RTMEM_PROT_NON
[all...]
/vbox/src/VBox/Runtime/testcase/
H A DtstRTR0MemUserKernel.cpp72 uint8_t *pbKrnlBuf = (uint8_t *)RTMemAlloc(PAGE_SIZE * 2);
93 int rc = RTR0MemUserCopyFrom(pbKrnlBuf, R3Ptr, PAGE_SIZE);
96 rc = RTR0MemUserCopyTo(R3Ptr, pbKrnlBuf, PAGE_SIZE);
157 for (unsigned cb = 0; cb < PAGE_SIZE - 16; cb++)
165 for (unsigned cb = 0; cb < PAGE_SIZE - 16; cb++)
176 for (unsigned cb = 0; cb < PAGE_SIZE - 16; cb++)
/vbox/src/VBox/Additions/common/VBoxService/
H A DVBoxServiceBalloon.cpp65 void *pv = (void*)mmap(NULL, PAGE_SIZE, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
68 g_fSysMadviseWorks = madvise(pv, PAGE_SIZE, MADV_DONTFORK) == 0;
69 munmap(pv, PAGE_SIZE);
86 cb += 2 * PAGE_SIZE;
109 RTMemProtect(pu8, PAGE_SIZE, RTMEM_PROT_NONE);
110 RTMemProtect(pu8 + cb - PAGE_SIZE, PAGE_SIZE, RTMEM_PROT_NONE);
111 pu8 += PAGE_SIZE;
139 cb += 2 * PAGE_SIZE;
140 pu8 -= PAGE_SIZE;
[all...]
/vbox/src/VBox/HostDrivers/Support/testcase/
H A DtstLow.cpp78 memset((char *)pvPages0 + iPage * PAGE_SIZE, iPage, PAGE_SIZE);
80 for (uint8_t *pu8 = (uint8_t *)pvPages0 + iPage * PAGE_SIZE, *pu8End = pu8 + PAGE_SIZE; pu8 < pu8End; pu8++)
126 memset((char *)pvPages1 + iPage * PAGE_SIZE, iPage, PAGE_SIZE);
128 for (uint8_t *pu8 = (uint8_t *)pvPages1 + iPage * PAGE_SIZE, *pu8End = pu8 + PAGE_SIZE; pu8 < pu8End; pu8++)
H A DtstContiguous.cpp58 memset(pv, 0xff, PAGE_SIZE * 8);
63 memset(pv, 0x7f, PAGE_SIZE * 5);
H A DtstPage.cpp52 memset(pv, 0xff, PAGE_SIZE);
H A DtstPin.cpp86 aPinnings[i].pvAligned = RT_ALIGN_P(aPinnings[i].pv, PAGE_SIZE);
139 pv = SUPR3ContAlloc(RT_ALIGN_Z(15003, PAGE_SIZE) >> PAGE_SHIFT, NIL_RTR0PTR, &HCPhys);
146 pv = SUPR3ContAlloc(RT_ALIGN_Z(12999, PAGE_SIZE) >> PAGE_SHIFT, NIL_RTR0PTR, &HCPhys);
152 rc = SUPR3ContFree(pv, RT_ALIGN_Z(12999, PAGE_SIZE) >> PAGE_SHIFT);
169 #define BIG_SIZEPP (BIG_SIZE + PAGE_SIZE)
175 void *pvAligned = RT_ALIGN_P(pv, PAGE_SIZE);
/vbox/include/VBox/
H A Dparam.h41 #define VBOX_MAX_ALLOC_PAGE_COUNT (256U * _1M / PAGE_SIZE)
67 #define MM_HYPER_DYNAMIC_SIZE (16U * PAGE_SIZE)
/vbox/src/VBox/Runtime/r3/win/
H A Dalloc-win.cpp60 cbProt = RT_ALIGN_Z(cbProt, PAGE_SIZE);
83 void *pv = VirtualAlloc(NULL, RT_ALIGN_Z(cb, PAGE_SIZE), MEM_COMMIT, PAGE_READWRITE);
85 void *pv = _aligned_malloc(RT_ALIGN_Z(cb, PAGE_SIZE), PAGE_SIZE);
95 void *pv = VirtualAlloc(NULL, RT_ALIGN_Z(cb, PAGE_SIZE), MEM_COMMIT, PAGE_READWRITE);
97 void *pv = _aligned_malloc(RT_ALIGN_Z(cb, PAGE_SIZE), PAGE_SIZE);
101 memset(pv, 0, RT_ALIGN_Z(cb, PAGE_SIZE));
H A Dallocex-win.cpp81 cbAlloc = RT_ALIGN_Z(cbAlloc, PAGE_SIZE);
82 AssertReturn(cbAlloc <= _64K - PAGE_SIZE, VERR_NO_MEMORY);
85 return rtMemAllocExInRange(cbAlloc, fFlags, ppv, PAGE_SIZE, _64K - cbAlloc);
91 cbAlloc = RT_ALIGN_Z(cbAlloc, PAGE_SIZE);
/vbox/src/VBox/VMM/testcase/
H A DtstCompressionBenchmark.cpp44 static size_t g_cPages = 20*_1M / PAGE_SIZE;
165 size_t const cPages = cbSrc / PAGE_SIZE;
169 RTCrc32(&pabSrc[iPage * PAGE_SIZE], PAGE_SIZE);
177 RTCrc64(&pabSrc[iPage * PAGE_SIZE], PAGE_SIZE);
184 RTCrcAdler32(&pabSrc[iPage * PAGE_SIZE], PAGE_SIZE);
192 RTMd5(&pabSrc[iPage * PAGE_SIZE], PAGE_SIZE, abMd5Has
[all...]
H A DtstSSM.cpp59 const uint8_t gabPage[PAGE_SIZE] = {0};
92 memset(&gabBigMem[sizeof(gabBigMem) / 4], 0, PAGE_SIZE * 4);
93 memset(&gabBigMem[sizeof(gabBigMem) / 4 * 3], 0, PAGE_SIZE * 4);
435 rc = SSMR3PutMem(pSSM, pu8Org, PAGE_SIZE);
438 RTPrintf("Item03: PutMem(,%p,%#x) -> %Rrc\n", pu8Org, PAGE_SIZE, rc);
443 cb -= PAGE_SIZE;
444 pu8Org += PAGE_SIZE;
494 char achPage[PAGE_SIZE];
495 rc = SSMR3GetMem(pSSM, &achPage[0], PAGE_SIZE);
498 RTPrintf("Item03: SSMR3GetMem(,,%#x) -> %Rrc offset %#x\n", PAGE_SIZE, r
[all...]
H A DtstMMHyperHeap.cpp56 SUPPAGE aPages[RT_ALIGN_Z(sizeof(*pVM) + NUM_CPUS * sizeof(VMCPU), PAGE_SIZE) >> PAGE_SHIFT];
126 { PAGE_SIZE, PAGE_SIZE, NULL, 13 },
128 { PAGE_SIZE, 32, NULL, 11 },
129 { PAGE_SIZE, PAGE_SIZE, NULL, 14 },
167 || aOps[i].uAlignment == PAGE_SIZE)
211 if (aOps[j].uAlignment == PAGE_SIZE)
/vbox/include/VBox/vmm/
H A Duvm.h164 AssertMsgReturn( RT_VALID_ALIGNED_PTR(a_pUVM, PAGE_SIZE) \
167 RT_VALID_ALIGNED_PTR(a_pUVM, PAGE_SIZE) ? (a_pUVM)->u32Magic : 0), \
173 AssertMsgReturnVoid( RT_VALID_ALIGNED_PTR(a_pUVM, PAGE_SIZE) \
176 RT_VALID_ALIGNED_PTR(a_pUVM, PAGE_SIZE) ? (a_pUVM)->u32Magic : 0))
/vbox/src/VBox/VMM/VMMR0/
H A DVMMR0TripleFaultHack.cpp77 int rc = RTR0MemObjEnterPhys(&g_hMemPage0, 0, PAGE_SIZE, RTMEM_CACHE_POLICY_DONT_CARE);
87 //rc = RTR0MemObjAllocPhys(&g_hMemLowCore, PAGE_SIZE, _1M - 1);
89 rc = RTR0MemObjEnterPhys(&g_hMemLowCore, 0x7000, PAGE_SIZE, RTMEM_CACHE_POLICY_DONT_CARE);
100 g_pvSavedLowCore = RTMemAlloc(PAGE_SIZE);
102 memcpy(g_pvSavedLowCore, g_pbLowCore, PAGE_SIZE);
111 AssertLogRelReturn(cbCode <= PAGE_SIZE, VERR_OUT_OF_RANGE);
159 memcpy(g_pbLowCore, g_pvSavedLowCore, PAGE_SIZE);
/vbox/src/VBox/HostDrivers/Support/linux/
H A DSUPLib-linux.cpp89 void *pv = mmap(NULL, PAGE_SIZE, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
92 pThis->fSysMadviseWorks = (0 == madvise(pv, PAGE_SIZE, MADV_DONTFORK));
93 munmap(pv, PAGE_SIZE);
242 mprotect(pvPages, PAGE_SIZE, PROT_NONE);
243 mprotect(pvPages + cbMmap - PAGE_SIZE, PAGE_SIZE, PROT_NONE);
244 *ppvPages = pvPages + PAGE_SIZE;
/vbox/src/VBox/Runtime/r0drv/darwin/
H A Dalloc-r0drv-darwin.cpp138 cb = RT_ALIGN_Z(cb, PAGE_SIZE);
140 void *pv = IOMallocContiguous(cb, PAGE_SIZE, &PhysAddr);
168 cb = RT_ALIGN_Z(cb, PAGE_SIZE);
H A Dmemobj-r0drv-darwin.cpp88 if (cb <= PAGE_SIZE)
90 cb -= PAGE_SIZE;
91 pu32 += PAGE_SIZE / sizeof(uint32_t);
114 if (cb <= PAGE_SIZE)
116 cb -= PAGE_SIZE;
117 pu32 += PAGE_SIZE / sizeof(uint32_t);
224 IOAddressRange aRanges[1] = { { (mach_vm_address_t)HCPhys, RT_ALIGN_Z(cb, PAGE_SIZE) } };
460 cbFudged += PAGE_SIZE;
470 uint64_t uAlignment = PAGE_SIZE;
498 for (IOByteCount off = 0; off < cb; off += PAGE_SIZE)
[all...]
/vbox/src/VBox/Runtime/r0drv/
H A Dmemobj-r0drv.cpp66 AssertMsg(RT_ALIGN_Z(cb, PAGE_SIZE) == cb, ("%#zx\n", cb));
231 * employed by any API is PAGE_SIZE, so the result can safely be shifted by
249 AssertMsg(RT_ALIGN_Z(pMem->cb, PAGE_SIZE) == pMem->cb, ("%#zx\n", pMem->cb));
297 return pMem->u.Cont.Phys + iPage * PAGE_SIZE;
299 return pMem->u.Phys.PhysBase + iPage * PAGE_SIZE;
423 const size_t cbAligned = RT_ALIGN_Z(cb, PAGE_SIZE);
439 const size_t cbAligned = RT_ALIGN_Z(cb, PAGE_SIZE);
455 const size_t cbAligned = RT_ALIGN_Z(cb, PAGE_SIZE);
472 const size_t cbAligned = RT_ALIGN_Z(cb + (R3Ptr & PAGE_OFFSET_MASK), PAGE_SIZE);
493 const size_t cbAligned = RT_ALIGN_Z(cb + ((uintptr_t)pv & PAGE_OFFSET_MASK), PAGE_SIZE);
[all...]
/vbox/src/VBox/Runtime/r0drv/linux/
H A Dalloc-r0drv-linux.c162 size_t const cbAlloc = RT_ALIGN_Z(sizeof(RTMEMLNXHDREX) + cb, PAGE_SIZE);
277 cb <= PAGE_SIZE*16 - sizeof(*pHdr)
279 cb <= PAGE_SIZE
289 && cb > PAGE_SIZE
379 * rounded up to PAGE_SIZE.
396 cb = RT_ALIGN_Z(cb, PAGE_SIZE);
422 AssertMsg( (uintptr_t)phys_to_virt(page_to_phys(&paPages[iPage])) + PAGE_SIZE
424 && page_to_phys(&paPages[iPage]) + PAGE_SIZE
465 cb = RT_ALIGN_Z(cb, PAGE_SIZE);
/vbox/src/VBox/Runtime/r3/posix/
H A Drtmempage-exec-mmap-posix.cpp64 cb = RT_ALIGN_Z(cb, PAGE_SIZE);
101 cb = RT_ALIGN_Z(cb, PAGE_SIZE);
/vbox/src/VBox/VMM/VMMR3/
H A DMMHyper.cpp130 cbHyperHeap = RT_ALIGN_32(cbHyperHeap, PAGE_SIZE);
145 MMR3HyperReserve(pVM, PAGE_SIZE, "fence", NULL);
152 rc = MMR3HyperMapPages(pVM, pVM, pVM->pVMR0, RT_ALIGN_Z(pVM->cbSelf, PAGE_SIZE) >> PAGE_SHIFT, pVM->paVMPagesR3, "VM",
161 MMR3HyperReserve(pVM, PAGE_SIZE, "fence", NULL);
247 rc = PGMMap(pVM, GCPtr + (i << PAGE_SHIFT), paHCPhysPages[i], PAGE_SIZE, 0);
261 for (uint32_t off = 0; off < cb; off += PAGE_SIZE)
267 rc = PGMMap(pVM, GCPtr + off, HCPhys, PAGE_SIZE, 0);
277 for (RTGCPHYS offCur = pLookup->u.MMIO2.off; offCur < offEnd; offCur += PAGE_SIZE)
283 rc = PGMMap(pVM, GCPtr + (offCur - pLookup->u.MMIO2.off), HCPhys, PAGE_SIZE, 0);
426 AssertReturn(RT_ALIGN_P(pvR3, PAGE_SIZE)
[all...]

Completed in 147 milliseconds

12345678