Home
last modified time | relevance | path

Searched refs:uffdio_api (Results 1 – 14 of 14) sorted by relevance

/linux-6.12.1/tools/testing/selftests/mm/
Dhugepage-mremap.c65 struct uffdio_api uffdio_api; in register_region_with_uffd() local
73 uffdio_api.api = UFFD_API; in register_region_with_uffd()
74 uffdio_api.features = 0; in register_region_with_uffd()
75 if (ioctl(uffd, UFFDIO_API, &uffdio_api) == -1) in register_region_with_uffd()
Duffd-common.c239 struct uffdio_api uffdio_api; in userfaultfd_open() local
246 uffdio_api.api = UFFD_API; in userfaultfd_open()
247 uffdio_api.features = *features; in userfaultfd_open()
248 if (ioctl(uffd, UFFDIO_API, &uffdio_api)) in userfaultfd_open()
251 if (uffdio_api.api != UFFD_API) in userfaultfd_open()
252 err("UFFDIO_API error: %" PRIu64, (uint64_t)uffdio_api.api); in userfaultfd_open()
254 *features = uffdio_api.features; in userfaultfd_open()
691 struct uffdio_api uffdio_api = { .api = UFFD_API, .features = 0 }; in uffd_get_features() local
705 if (ioctl(fd, UFFDIO_API, &uffdio_api)) { in uffd_get_features()
710 *features = uffdio_api.features; in uffd_get_features()
Dmkdirty.c272 struct uffdio_api uffdio_api; in test_uffdio_copy() local
292 uffdio_api.api = UFFD_API; in test_uffdio_copy()
293 uffdio_api.features = 0; in test_uffdio_copy()
294 if (ioctl(uffd, UFFDIO_API, &uffdio_api) < 0) { in test_uffdio_copy()
Dksm_functional_tests.c376 struct uffdio_api uffdio_api; in test_unmerge_uffd_wp() local
394 uffdio_api.api = UFFD_API; in test_unmerge_uffd_wp()
395 uffdio_api.features = UFFD_FEATURE_PAGEFAULT_FLAG_WP; in test_unmerge_uffd_wp()
396 if (ioctl(uffd, UFFDIO_API, &uffdio_api) < 0) { in test_unmerge_uffd_wp()
400 if (!(uffdio_api.features & UFFD_FEATURE_PAGEFAULT_FLAG_WP)) { in test_unmerge_uffd_wp()
Duffd-unit-tests.c128 struct uffdio_api uffdio_api; in test_uffd_api() local
144 uffdio_api.api = 0xab; in test_uffd_api()
145 uffdio_api.features = 0; in test_uffd_api()
146 if (ioctl(uffd, UFFDIO_API, &uffdio_api) == 0) { in test_uffd_api()
152 uffdio_api.api = UFFD_API; in test_uffd_api()
153 uffdio_api.features = BIT_ULL(63); in test_uffd_api()
154 if (ioctl(uffd, UFFDIO_API, &uffdio_api) == 0) { in test_uffd_api()
160 uffdio_api.api = UFFD_API; in test_uffd_api()
161 uffdio_api.features = 0; in test_uffd_api()
162 if (ioctl(uffd, UFFDIO_API, &uffdio_api)) { in test_uffd_api()
[all …]
Dpagemap_ioctl.c94 struct uffdio_api uffdio_api; in init_uffd() local
100 uffdio_api.api = UFFD_API; in init_uffd()
101 uffdio_api.features = UFFD_FEATURE_WP_UNPOPULATED | UFFD_FEATURE_WP_ASYNC | in init_uffd()
103 if (ioctl(uffd, UFFDIO_API, &uffdio_api)) in init_uffd()
106 if (!(uffdio_api.api & UFFDIO_REGISTER_MODE_WP) || in init_uffd()
107 !(uffdio_api.features & UFFD_FEATURE_WP_UNPOPULATED) || in init_uffd()
108 !(uffdio_api.features & UFFD_FEATURE_WP_ASYNC) || in init_uffd()
109 !(uffdio_api.features & UFFD_FEATURE_WP_HUGETLBFS_SHMEM)) in init_uffd()
/linux-6.12.1/tools/testing/selftests/kvm/lib/
Duserfaultfd_util.c110 struct uffdio_api uffdio_api; in uffd_setup_demand_paging() local
140 uffdio_api.api = UFFD_API; in uffd_setup_demand_paging()
141 uffdio_api.features = 0; in uffd_setup_demand_paging()
142 TEST_ASSERT(ioctl(uffd, UFFDIO_API, &uffdio_api) != -1, in uffd_setup_demand_paging()
144 (uint64_t)uffdio_api.api); in uffd_setup_demand_paging()
/linux-6.12.1/tools/testing/selftests/powerpc/tm/
Dtm-signal-pagefault.c141 struct uffdio_api uffdio_api; in setup_uf_mem() local
153 uffdio_api.api = UFFD_API; in setup_uf_mem()
154 uffdio_api.features = 0; in setup_uf_mem()
155 if (ioctl(uffd, UFFDIO_API, &uffdio_api) == -1) { in setup_uf_mem()
/linux-6.12.1/fs/
Duserfaultfd.c1932 struct uffdio_api uffdio_api; in userfaultfd_api() local
1939 if (copy_from_user(&uffdio_api, buf, sizeof(uffdio_api))) in userfaultfd_api()
1941 features = uffdio_api.features; in userfaultfd_api()
1943 if (uffdio_api.api != UFFD_API) in userfaultfd_api()
1954 uffdio_api.features = UFFD_API_FEATURES; in userfaultfd_api()
1956 uffdio_api.features &= in userfaultfd_api()
1960 uffdio_api.features &= ~UFFD_FEATURE_PAGEFAULT_FLAG_WP; in userfaultfd_api()
1963 uffdio_api.features &= ~UFFD_FEATURE_WP_HUGETLBFS_SHMEM; in userfaultfd_api()
1964 uffdio_api.features &= ~UFFD_FEATURE_WP_UNPOPULATED; in userfaultfd_api()
1965 uffdio_api.features &= ~UFFD_FEATURE_WP_ASYNC; in userfaultfd_api()
[all …]
/linux-6.12.1/tools/testing/selftests/x86/
Dtest_shadow_stack.c485 struct uffdio_api uffdio_api; in test_userfaultfd() local
504 uffdio_api.api = UFFD_API; in test_userfaultfd()
505 uffdio_api.features = 0; in test_userfaultfd()
506 if (ioctl(uffd, UFFDIO_API, &uffdio_api)) in test_userfaultfd()
/linux-6.12.1/tools/include/uapi/linux/
Duserfaultfd.h87 struct uffdio_api)
162 struct uffdio_api { struct
/linux-6.12.1/include/uapi/linux/
Duserfaultfd.h87 struct uffdio_api)
162 struct uffdio_api { struct
/linux-6.12.1/Documentation/admin-guide/mm/
Duserfaultfd.rst87 ``UFFDIO_API`` ioctl specifying a ``uffdio_api.api`` value set to ``UFFD_API`` (or
89 userland intends to speak on the ``UFFD`` and the ``uffdio_api.features``
91 requested ``uffdio_api.api`` is spoken also by the running kernel and the
93 ``uffdio_api.features`` and ``uffdio_api.ioctls`` two 64bit bitmasks of
97 The ``uffdio_api.features`` bitmask returned by the ``UFFDIO_API`` ioctl
124 ioctl should be invoked (if present in the returned ``uffdio_api.ioctls``
371 bits in ``uffdio_api.features`` passed to ``UFFDIO_API`` ioctl:
/linux-6.12.1/tools/testing/selftests/bpf/prog_tests/
Dbpf_mod_race.c66 struct uffdio_api uffd_api = {}; in test_setup_uffd()