Changeset 73579 in vbox
- Timestamp:
- Aug 9, 2018 8:51:16 AM (6 years ago)
- File:
-
- 1 edited
-
trunk/src/VBox/VMM/testcase/tstMMHyperHeap.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/testcase/tstMMHyperHeap.cpp
r73502 r73579 54 54 * Create empty VM structure and call MMR3Init(). 55 55 */ 56 PVM pVM = NULL;56 void *pvVM = NULL; 57 57 RTR0PTR pvR0 = NIL_RTR0PTR; 58 SUPPAGE aPages[RT_ALIGN_Z(sizeof( *pVM) + NUM_CPUS * sizeof(VMCPU), PAGE_SIZE) >> PAGE_SHIFT];58 SUPPAGE aPages[RT_ALIGN_Z(sizeof(VM) + NUM_CPUS * sizeof(VMCPU), PAGE_SIZE) >> PAGE_SHIFT]; 59 59 int rc = SUPR3Init(NULL); 60 60 if (RT_SUCCESS(rc)) 61 61 //rc = SUPR3LowAlloc(RT_ELEMENTS(aPages), (void **)&pVM, &pvR0, &aPages[0]); 62 rc = SUPR3PageAllocEx(RT_ELEMENTS(aPages), 0, (void **)&pVM, &pvR0, &aPages[0]);62 rc = SUPR3PageAllocEx(RT_ELEMENTS(aPages), 0, &pvVM, &pvR0, &aPages[0]); 63 63 if (RT_FAILURE(rc)) 64 64 { … … 66 66 return RTEXITCODE_FAILURE; 67 67 } 68 RT_BZERO(pvVM, RT_ELEMENTS(aPages) * PAGE_SIZE); /* SUPR3PageAllocEx doesn't necessarily zero the memory. */ 69 PVM pVM = (PVM)pvVM; 68 70 pVM->paVMPagesR3 = aPages; 69 71 pVM->pVMR0 = pvR0;
Note:
See TracChangeset
for help on using the changeset viewer.

