Lines Matching refs:p1
1315 void *p1; in get_pointer_to_instructions() local
1317 p1 = ALIGN_PTR_UP(&lots_o_noops_around_write, PAGE_SIZE); in get_pointer_to_instructions()
1320 assert(p1 == &lots_o_noops_around_write); in get_pointer_to_instructions()
1323 p1 += PAGE_SIZE; in get_pointer_to_instructions()
1329 madvise(p1, PAGE_SIZE, MADV_DONTNEED); in get_pointer_to_instructions()
1331 return p1; in get_pointer_to_instructions()
1336 void *p1; in test_executing_on_unreadable_memory() local
1341 p1 = get_pointer_to_instructions(); in test_executing_on_unreadable_memory()
1343 ptr_contents = read_ptr(p1); in test_executing_on_unreadable_memory()
1344 dprintf2("ptr (%p) contents@%d: %x\n", p1, __LINE__, ptr_contents); in test_executing_on_unreadable_memory()
1346 ret = mprotect_pkey(p1, PAGE_SIZE, PROT_EXEC, (u64)pkey); in test_executing_on_unreadable_memory()
1355 madvise(p1, PAGE_SIZE, MADV_DONTNEED); in test_executing_on_unreadable_memory()
1358 ptr_contents = read_ptr(p1); in test_executing_on_unreadable_memory()
1359 dprintf2("ptr (%p) contents@%d: %x\n", p1, __LINE__, ptr_contents); in test_executing_on_unreadable_memory()
1365 void *p1; in test_implicit_mprotect_exec_only_memory() local
1372 p1 = get_pointer_to_instructions(); in test_implicit_mprotect_exec_only_memory()
1374 ptr_contents = read_ptr(p1); in test_implicit_mprotect_exec_only_memory()
1375 dprintf2("ptr (%p) contents@%d: %x\n", p1, __LINE__, ptr_contents); in test_implicit_mprotect_exec_only_memory()
1378 ret = mprotect(p1, PAGE_SIZE, PROT_EXEC); in test_implicit_mprotect_exec_only_memory()
1384 madvise(p1, PAGE_SIZE, MADV_DONTNEED); in test_implicit_mprotect_exec_only_memory()
1387 ptr_contents = read_ptr(p1); in test_implicit_mprotect_exec_only_memory()
1388 dprintf2("ptr (%p) contents@%d: %x\n", p1, __LINE__, ptr_contents); in test_implicit_mprotect_exec_only_memory()
1397 ret = mprotect(p1, PAGE_SIZE, PROT_NONE); in test_implicit_mprotect_exec_only_memory()
1400 ret = mprotect(p1, PAGE_SIZE, PROT_READ|PROT_EXEC); in test_implicit_mprotect_exec_only_memory()
1402 ptr_contents = read_ptr(p1); in test_implicit_mprotect_exec_only_memory()