1 #include "libcflat.h" 2 #include "processor.h" 3 #include "x86/vm.h" 4 #include "access.h" 5 main(int argc,const char * argv[])6int main(int argc, const char *argv[]) 7 { 8 bool force_emulation = argc >= 2 && !strcmp(argv[1], "force_emulation"); 9 10 printf("starting test\n\n"); 11 ac_test_run(PT_LEVEL_PML4, force_emulation); 12 13 #ifndef CONFIG_EFI 14 /* 15 * Not supported yet for UEFI, because setting up 5 16 * level page table requires entering real mode. 17 */ 18 if (this_cpu_has(X86_FEATURE_LA57)) { 19 printf("starting 5-level paging test.\n\n"); 20 setup_5level_page_table(); 21 ac_test_run(PT_LEVEL_PML5, force_emulation); 22 } 23 #endif 24 25 return report_summary(); 26 } 27