/bionic/tests/ |
D | sys_mman_test.cpp | 27 void* map = mmap(nullptr, 4096, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); in TEST() 33 void* map = mmap64(nullptr, 4096, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); in TEST() 41 void* map = mmap(nullptr, 100, PROT_READ, MAP_SHARED, tf.fd, 1); in TEST() 48 void* map = mmap64(nullptr, 100, PROT_READ, MAP_SHARED, tf.fd, 1); in TEST() 62 void* map = mmap(nullptr, sizeof(STRING_MSG), PROT_READ, MAP_SHARED, tf.fd, 0); in TEST() 113 void* map = mmap(nullptr, pagesize, PROT_READ, MAP_SHARED, tf.fd, pagesize); in TEST() 121 map = mmap(nullptr, pagesize, PROT_READ, MAP_SHARED, tf.fd, 2 * pagesize); in TEST() 184 void* map = mmap(nullptr, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, tempfile.fd, 0); in TEST() 202 void* map = mmap(nullptr, pagesize, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in TEST() 240 char* base = reinterpret_cast<char*>(mmap(nullptr, PAGE_SIZE * 2, PROT_EXEC | PROT_READ, in TEST()
|
D | buffer_tests.cpp | 376 ASSERT_TRUE(MprotectHeap(&memory[pagesize], pagesize, PROT_READ | PROT_WRITE) == 0); in RunSingleBufferOverreadTest() 402 ASSERT_TRUE(MprotectHeap(&memory[pagesize], pagesize, PROT_READ | PROT_WRITE) == 0); in RunSrcDstBufferOverreadTest() 456 ASSERT_TRUE(MprotectHeap(&memory1[pagesize], pagesize, PROT_READ | PROT_WRITE) == 0); in RunCmpBufferOverreadTest() 457 ASSERT_TRUE(MprotectHeap(&memory2[pagesize], pagesize, PROT_READ | PROT_WRITE) == 0); in RunCmpBufferOverreadTest()
|
D | sys_prctl_test.cpp | 38 void* p = mmap(NULL, page_size * 3, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in TEST()
|
D | android_unsafe_frame_pointer_chase_test.cpp | 136 mmap(nullptr, kStackSize * 2, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); in TEST()
|
D | utils.h | 131 record.perms |= PROT_READ; in parse_maps()
|
/bionic/libc/private/ |
D | WriteProtected.h | 55 set_protection(PROT_READ); in initialize() 68 set_protection(PROT_READ | PROT_WRITE); in mutate() 70 set_protection(PROT_READ); in mutate()
|
/bionic/linker/ |
D | linker_block_allocator_test.cpp | 131 allocator.protect_all(PROT_READ); in protect_all() 132 allocator.protect_all(PROT_READ | PROT_WRITE); in protect_all() 137 allocator.protect_all(PROT_READ); in protect_all()
|
D | linker_cfi.cpp | 56 reinterpret_cast<char*>(mmap(nullptr, aligned_end - aligned_start, PROT_READ | PROT_WRITE, in ShadowWrite() 59 mprotect(aligned_start, aligned_end - aligned_start, PROT_READ); in ShadowWrite() 74 mprotect(tmp_start, size, PROT_READ); in ~ShadowWrite() 208 mprotect(shadow_start, PAGE_SIZE, PROT_READ); in NotifyLibDl()
|
D | linker_mapped_file_fragment.cpp | 62 mmap64(nullptr, map_size, PROT_READ, MAP_PRIVATE, fd, page_min)); in Map()
|
D | linker_phdr.cpp | 137 MAYBE_MAP_FLAG((x), PF_R, PROT_READ) | \ 864 return _phdr_table_set_gnu_relro_prot(phdr_table, phdr_count, load_bias, PROT_READ); in phdr_table_protect_gnu_relro() 901 void* map = mmap(reinterpret_cast<void*>(seg_page_start), size, PROT_READ, in phdr_table_serialize_gnu_relro() 941 temp_mapping = mmap(nullptr, file_size, PROT_READ, MAP_PRIVATE, fd, 0); in phdr_table_map_gnu_relro() 988 PROT_READ, MAP_PRIVATE|MAP_FIXED, fd, *file_offset + match_offset); in phdr_table_map_gnu_relro()
|
D | linker_block_allocator.cpp | 124 mmap(nullptr, kAllocateSize, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0)); in create_new_page()
|
/bionic/libc/malloc_debug/ |
D | MapData.cpp | 64 flags |= PROT_READ; in parse_line() 71 if (!(flags & PROT_READ)) { in parse_line() 82 if (!(entry->flags & PROT_READ) || addr < entry->start || addr + sizeof(T) > entry->end) { in get_val() 199 if (prev_entry->flags == PROT_READ && prev_entry->offset < entry->offset && in find()
|
/bionic/libc/bionic/ |
D | pthread_create.cpp | 73 PROT_READ | PROT_WRITE, in __allocate_temp_bionic_tls() 89 …void* stack_base = mmap(nullptr, SIGNAL_STACK_SIZE, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOU… in __init_alternate_signal_stack() 130 mprotect(scs, SCS_SIZE, PROT_READ | PROT_WRITE); in __init_shadow_call_stack() 227 PROT_READ | PROT_WRITE) != 0) { in __allocate_thread_mapping()
|
D | atexit.cpp | 162 const int prot = PROT_READ | (writable ? PROT_WRITE : 0); in set_writable() 174 new_pages = mmap(nullptr, new_capacity_bytes, PROT_READ | PROT_WRITE, in expand_capacity()
|
D | android_set_abort_message.cpp | 81 void* map = mmap(nullptr, size, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); in android_set_abort_message()
|
D | bionic_allocator.cpp | 195 void* const map_ptr = mmap(nullptr, PAGE_SIZE, PROT_READ | PROT_WRITE, in alloc_page() 276 void* map_ptr = mmap(nullptr, allocated_size, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, in alloc_mmap()
|
D | libc_init_static.cpp | 127 mprotect(reinterpret_cast<void*>(seg_page_start), seg_page_end - seg_page_start, PROT_READ); in apply_gnu_relro()
|
D | grp_pwd_file.cpp | 243 void* map_result = mmap(nullptr, mmap_size, PROT_READ, MAP_SHARED, fd.get(), 0); in DoMmap()
|
D | fdsan.cpp | 87 mmap(nullptr, aligned_size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in at()
|
/bionic/libc/kernel/uapi/asm-generic/ |
D | mman-common.h | 21 #define PROT_READ 0x1 macro
|
/bionic/libc/upstream-openbsd/android/include/ |
D | arc4random.h | 69 if ((p = mmap(NULL, sizeof(*p), PROT_READ|PROT_WRITE, in _rs_allocate()
|
/bionic/tests/headers/posix/ |
D | sys_mman_h.c | 36 MACRO(PROT_READ); in sys_mman_h()
|
/bionic/libc/system_properties/ |
D | contexts_serialized.cpp | 48 void* const map_result = mmap(nullptr, context_nodes_mmap_size, PROT_READ | PROT_WRITE, in InitializeContextNodes()
|
D | prop_area.cpp | 95 void* const memory_area = mmap(nullptr, pa_size_, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); in map_prop_area_rw() 122 void* const map_result = mmap(nullptr, pa_size_, PROT_READ, MAP_SHARED, fd, 0); in map_fd_ro()
|
/bionic/libc/stdio/ |
D | printf_common.h | 541 PROT_WRITE | PROT_READ, in __find_arguments() 652 PROT_WRITE | PROT_READ, in __grow_type_table() 658 PROT_WRITE | PROT_READ, in __grow_type_table()
|