| /tools/testing/selftests/mm/ |
| A D | hugetlb_madv_vs_map.c | 32 size_t mmap_size; variable 47 madvise(huge_ptr, mmap_size, MADV_DONTNEED); in madv() 62 ptr = mmap(NULL, mmap_size, PROT_READ | PROT_WRITE, in map_extra() 96 mmap_size = default_huge_page_size(); in main() 99 huge_ptr = mmap(NULL, mmap_size, PROT_READ | PROT_WRITE, in main() 122 munmap(huge_ptr, mmap_size); in main()
|
| A D | mkdirty.c | 64 const size_t mmap_size = 2 * thpsize; in mmap_thp_range() local 67 mmap_mem = mmap(NULL, mmap_size, prot, MAP_PRIVATE|MAP_ANON, in mmap_thp_range() 77 munmap(mmap_mem, mmap_size); in mmap_thp_range() 82 *_mmap_size = mmap_size; in mmap_thp_range() 125 size_t mmap_size; in test_ptrace_write_thp() local 131 mem = mmap_thp_range(PROT_READ, &mmap_mem, &mmap_size); in test_ptrace_write_thp() 155 munmap(mmap_mem, mmap_size); in test_ptrace_write_thp() 193 size_t mmap_size; in test_page_migration_thp() local 226 munmap(mmap_mem, mmap_size); in test_page_migration_thp() 232 size_t mmap_size; in test_pte_mapped_thp() local [all …]
|
| A D | uffd-wp-mremap.c | 54 size_t mmap_size = size * 2; in mmap_aligned() local 57 mmap_mem = mmap(NULL, mmap_size, prot, flags, -1, 0); in mmap_aligned() 63 munmap(mem + size, mmap_mem + mmap_size - mem - size); in mmap_aligned()
|
| A D | cow.c | 837 size_t size, mmap_size, mremap_size; in do_run_with_thp() local 841 mmap_size = 2 * thpsize; in do_run_with_thp() 842 mmap_mem = mmap(NULL, mmap_size, PROT_READ | PROT_WRITE, in do_run_with_thp() 984 munmap(mmap_mem, mmap_size); in do_run_with_thp() 1570 size_t mmap_size; in run_with_huge_zeropage() local 1582 mmap_size = 2 * pmdsize; in run_with_huge_zeropage() 1583 mmap_mem = mmap(NULL, mmap_size, PROT_READ | PROT_WRITE, in run_with_huge_zeropage() 1590 mmap_smem = mmap(NULL, mmap_size, PROT_READ, in run_with_huge_zeropage() 1630 munmap(mmap_mem, mmap_size); in run_with_huge_zeropage() 1632 munmap(mmap_smem, mmap_size); in run_with_huge_zeropage()
|
| /tools/testing/selftests/powerpc/pmu/sampling_tests/ |
| A D | misc.c | 180 size_t mmap_size; in event_sample_buf_mmap() local 189 mmap_size = page_size * (1 + mmap_pages); in event_sample_buf_mmap() 190 buff = mmap(NULL, mmap_size, in event_sample_buf_mmap()
|
| /tools/perf/util/ |
| A D | session.c | 1962 prefetch_event(char *buf, u64 head, size_t mmap_size, in prefetch_event() argument 1972 if (head + sizeof(event->header) > mmap_size) in prefetch_event() 1980 if (head + event_size <= mmap_size) in prefetch_event() 1988 if (event_size <= mmap_size - head % page_size) { in prefetch_event() 2009 return prefetch_event(buf, head, mmap_size, needs_swap, NULL); in fetch_decomp_event() 2074 size_t mmap_size; member 2095 rd->mmap_size = MMAP_SIZE; in reader__init() 2096 if (rd->mmap_size > data_size) { in reader__init() 2097 rd->mmap_size = data_size; in reader__init() 2136 munmap(mmaps[rd->mmap_idx], rd->mmap_size); in reader__mmap() [all …]
|
| A D | auxtrace.h | 260 size_t mmap_size; member
|
| A D | auxtrace.c | 1228 buffer->mmap_size = size; in auxtrace_buffer__get_data_rw() 1239 munmap(buffer->mmap_addr, buffer->mmap_size); in auxtrace_buffer__put_data() 1241 buffer->mmap_size = 0; in auxtrace_buffer__put_data()
|
| /tools/testing/selftests/bpf/benchs/ |
| A D | bench_ringbufs.c | 467 size_t mmap_size; member 481 size_t mmap_mask = pb->mmap_size - 1; in perfbuf_custom_consumer()
|
| /tools/testing/selftests/kvm/lib/ |
| A D | kvm_util.c | 821 ret = munmap(region->mmap_start, region->mmap_size); in __vm_mem_region_delete() 825 ret = munmap(region->mmap_alias, region->mmap_size); in __vm_mem_region_delete() 1054 region->mmap_size = mem_size; in vm_mem_add() 1076 region->mmap_size += alignment; in vm_mem_add() 1080 region->fd = kvm_memfd_alloc(region->mmap_size, in vm_mem_add() 1083 region->mmap_start = mmap(NULL, region->mmap_size, in vm_mem_add() 1159 region->mmap_alias = mmap(NULL, region->mmap_size, in vm_mem_add()
|
| /tools/bpf/bpftool/ |
| A D | gen.c | 734 size_t mmap_size = 0; in gen_trace() local 744 mmap_data = bpf_map__initial_value(map, &mmap_size); in gen_trace() 745 print_hex(mmap_data, mmap_size); in gen_trace()
|
| /tools/testing/selftests/kvm/include/ |
| A D | kvm_util.h | 46 size_t mmap_size; member
|
| /tools/lib/bpf/ |
| A D | libbpf.c | 13222 perf_event_read_simple(void *mmap_mem, size_t mmap_size, size_t page_size, 13235 ehdr = base + (data_tail & (mmap_size - 1)); 13238 if (((void *)ehdr) + ehdr_size > base + mmap_size) { 13240 size_t len_first = base + mmap_size - copy_start; 13301 size_t mmap_size; member 13315 munmap(cpu_buf->base, pb->mmap_size + pb->page_size)) in perf_buffer__free_cpu_buf() 13373 cpu_buf->base = mmap(NULL, pb->mmap_size + pb->page_size, in perf_buffer__open_cpu_buf() 13507 pb->mmap_size = pb->page_size * page_cnt; in __perf_buffer__new() 13655 ret = perf_event_read_simple(cpu_buf->base, pb->mmap_size, in perf_buffer__process_records() 13728 *buf_size = pb->mmap_size; in perf_buffer__buffer()
|
| /tools/power/x86/turbostat/ |
| A D | turbostat.c | 9673 size_t mmap_size; in pmt_mmio_open() local 9725 mmap_size = ROUND_UP_TO_PAGE_SIZE(size); in pmt_mmio_open() 9726 mmio = mmap(0, mmap_size, PROT_READ, MAP_SHARED, fd_pmt, 0); in pmt_mmio_open()
|