Home
last modified time | relevance | path

Searched refs:PAGE_SIZE (Results 1 – 25 of 29) sorted by relevance

12

/tools/testing/scatterlist/
Dmain.c15 ((1 + array[i]) * PAGE_SIZE); in set_pages()
31 { -EINVAL, 1, pfn(0), PAGE_SIZE, PAGE_SIZE + 1, 1 }, in main()
32 { -EINVAL, 1, pfn(0), PAGE_SIZE, 0, 1 }, in main()
33 { -EINVAL, 1, pfn(0), PAGE_SIZE, sgmax + 1, 1 }, in main()
34 { 0, 1, pfn(0), PAGE_SIZE, sgmax, 1 }, in main()
36 { 0, 2, pfn(0, 1), 2 * PAGE_SIZE, sgmax, 1 }, in main()
37 { 0, 2, pfn(1, 0), 2 * PAGE_SIZE, sgmax, 2 }, in main()
38 { 0, 3, pfn(0, 1, 2), 3 * PAGE_SIZE, sgmax, 1 }, in main()
39 { 0, 3, pfn(0, 2, 1), 3 * PAGE_SIZE, sgmax, 3 }, in main()
40 { 0, 3, pfn(0, 1, 3), 3 * PAGE_SIZE, sgmax, 2 }, in main()
[all …]
/tools/testing/selftests/vm/
Dva_128TBswitch.c15 #define PAGE_SIZE (64 << 10) macro
21 #define PAGE_SIZE (4 << 10) macro
48 .addr = ((void *)(ADDR_SWITCH_HINT - PAGE_SIZE)),
49 .size = PAGE_SIZE,
60 .addr = ((void *)(ADDR_SWITCH_HINT - PAGE_SIZE)),
61 .size = 2 * PAGE_SIZE,
72 .size = PAGE_SIZE,
79 .size = 2 * PAGE_SIZE,
85 .size = 2 * PAGE_SIZE,
92 .size = 2 * PAGE_SIZE,
[all …]
Dgup_benchmark.c15 #define PAGE_SIZE sysconf(_SC_PAGESIZE) macro
104 for (; (unsigned long)p < gup.addr + size; p += PAGE_SIZE) in main()
Dtranshuge-stress.c22 #define PAGE_SIZE (1 << PAGE_SHIFT) macro
133 if (madvise(p, HPAGE_SIZE - PAGE_SIZE, MADV_DONTNEED)) in main()
/tools/testing/scatterlist/linux/
Dmm.h29 #define PAGE_SIZE (4096) macro
31 #define PAGE_MASK (~(PAGE_SIZE-1))
37 #define PAGE_ALIGN(addr) ALIGN(addr, PAGE_SIZE)
51 #define page_to_pfn(page) ((unsigned long)(page) / PAGE_SIZE)
52 #define pfn_to_page(pfn) (void *)((pfn) * PAGE_SIZE)
104 return (unsigned long)malloc(PAGE_SIZE); in __get_free_page()
/tools/testing/selftests/proc/
Dproc-self-map-files-002.c49 const int PAGE_SIZE = sysconf(_SC_PAGESIZE); in main() local
64 for (va = 0; va < va_max; va += PAGE_SIZE) { in main()
65 p = mmap((void *)va, PAGE_SIZE, PROT_NONE, MAP_PRIVATE|MAP_FILE|MAP_FIXED, fd, 0); in main()
75 b = (unsigned long)p + PAGE_SIZE; in main()
Dthread-self.c49 const int PAGE_SIZE = sysconf(_SC_PAGESIZE); in main() local
56 stack = mmap(NULL, 2 * PAGE_SIZE, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0); in main()
59 pid = clone(f, stack + PAGE_SIZE, CLONE_THREAD|CLONE_SIGHAND|CLONE_VM, (void *)1); in main()
Dproc-self-map-files-001.c49 const unsigned int PAGE_SIZE = sysconf(_SC_PAGESIZE); in main() local
58 p = mmap(NULL, PAGE_SIZE, PROT_NONE, MAP_PRIVATE|MAP_FILE, fd, 0); in main()
63 b = (unsigned long)p + PAGE_SIZE; in main()
Dproc-pid-vm.c107 #define PAGE_SIZE 4096 macro
306 VADDR, VADDR + PAGE_SIZE, in main()
386 VADDR, VADDR + PAGE_SIZE); in main()
/tools/virtio/linux/
Dkernel.h23 #define PAGE_SIZE getpagesize() macro
24 #define PAGE_MASK (~(PAGE_SIZE-1))
25 #define PAGE_ALIGN(x) ((x + PAGE_SIZE - 1) & PAGE_MASK)
47 #define offset_in_page(p) (((unsigned long)p) % PAGE_SIZE)
100 posix_memalign(&p, PAGE_SIZE, PAGE_SIZE); in __get_free_page()
/tools/testing/selftests/x86/
Dtest_mremap_vdso.c23 #define PAGE_SIZE 4096 macro
68 unsigned long vdso_size = PAGE_SIZE; in main()
82 vdso_size += PAGE_SIZE; in main()
Dsysret_rip.c137 if (ip <= (1UL << 47) - PAGE_SIZE) { in test_syscall_fallthrough_to()
178 test_syscall_fallthrough_to((1UL << 47) - 2*PAGE_SIZE); in main()
182 test_syscall_fallthrough_to((1UL<<i) - PAGE_SIZE); in main()
Dprotection_keys.c178 __attribute__((__aligned__(PAGE_SIZE)))
761 ret = mprotect_pkey((void *)ptr, PAGE_SIZE, prot, pkey); in malloc_pkey_with_mprotect()
1076 iov.iov_len = PAGE_SIZE; in test_kernel_gup_of_access_disabled_region()
1120 err = sys_mprotect_pkey(ptr, PAGE_SIZE, PROT_READ, i); in test_pkey_syscalls_on_non_allocated_pkey()
1132 err = sys_mprotect_pkey(ptr, PAGE_SIZE, PROT_READ, bad_pkey); in test_pkey_syscalls_bad_args()
1249 int *plain_ptr = ALIGN_PTR_UP(plain_ptr_unaligned, PAGE_SIZE); in test_ptrace_of_child()
1317 p1 = ALIGN_PTR_UP(&lots_o_noops_around_write, PAGE_SIZE); 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()
1346 ret = mprotect_pkey(p1, PAGE_SIZE, PROT_EXEC, (u64)pkey); in test_executing_on_unreadable_memory()
[all …]
Dpkey-helpers.h142 #define PAGE_SIZE 4096 macro
/tools/testing/selftests/ptrace/
Dpeeksiginfo.c35 #ifndef PAGE_SIZE
36 #define PAGE_SIZE sysconf(_SC_PAGESIZE) macro
54 addr_rw = mmap(NULL, 2 * PAGE_SIZE, PROT_READ | PROT_WRITE, in check_error_paths()
61 addr_ro = mmap(addr_rw + PAGE_SIZE, PAGE_SIZE, PROT_READ, in check_error_paths()
101 munmap(addr_rw, 2 * PAGE_SIZE); in check_error_paths()
/tools/testing/nvdimm/
Ddax-dev.c15 addr = pgoff * PAGE_SIZE + res->start; in dax_pgoff_to_phys()
21 if (dev_dax->region->align > PAGE_SIZE) in dax_pgoff_to_phys()
/tools/testing/selftests/cgroup/
Dcgroup_util.c128 char buf[PAGE_SIZE]; in cg_read_strstr()
148 char buf[PAGE_SIZE]; in cg_read_key_long()
176 char buf[10 * PAGE_SIZE]; in cg_find_unified_root()
210 char buf[10 * PAGE_SIZE] = {0}; in cg_wait_for_proc_count()
235 char buf[PAGE_SIZE]; in cg_killall()
342 char buf[PAGE_SIZE]; in alloc_pagecache()
369 for (ptr = buf; ptr < buf + size; ptr += PAGE_SIZE) in alloc_anon()
378 char buf[PAGE_SIZE]; in is_swap_enabled()
Dcgroup_util.h4 #define PAGE_SIZE 4096 macro
Dtest_memcontrol.c31 char buf[PAGE_SIZE]; in test_memcg_subtree_control()
97 for (ptr = buf; ptr < buf + size; ptr += PAGE_SIZE) in alloc_anon_50M_check()
691 for (ptr = buf; ptr < buf + size; ptr += PAGE_SIZE) in alloc_anon_50M_check_swap()
/tools/testing/selftests/powerpc/benchmarks/
Dmmap_bench.c17 #define PAGE_SIZE (1UL << 16) macro
18 #define CHUNK_COUNT (MEMSIZE/PAGE_SIZE)
/tools/power/acpi/os_specific/service_layers/
Dosunixmap.c43 #ifdef PAGE_SIZE in acpi_os_get_page_size()
44 return PAGE_SIZE; in acpi_os_get_page_size()
/tools/virtio/virtio-trace/
Dtrace-agent.c17 #define PAGE_SIZE (sysconf(_SC_PAGE_SIZE)) macro
19 #define PIPE_MIN_SIZE (PAGE_SIZE*PIPE_DEF_BUFS)
96 round = value & (PAGE_SIZE - 1); in parse_size()
/tools/testing/selftests/kvm/x86_64/
Dsmm_test.c23 #define PAGE_SIZE 4096 macro
27 #define SMRAM_PAGES (SMRAM_SIZE / PAGE_SIZE)
Dvmx_tsc_adjust_test.c35 #define PAGE_SIZE 4096 macro
/tools/testing/selftests/sysctl/
Dsysctl.sh87 if [ -z $PAGE_SIZE ]; then
88 PAGE_SIZE=$(getconf PAGESIZE)
91 MAX_DIGITS=$(($PAGE_SIZE/8))

12