Lines Matching refs:ufd
224 int ufd; in receive_ufd_features() local
227 ufd = uffd_open(O_CLOEXEC); in receive_ufd_features()
228 if (ufd == -1) { in receive_ufd_features()
236 if (ioctl(ufd, UFFDIO_API, &api_struct)) { in receive_ufd_features()
246 close(ufd); in receive_ufd_features()
259 static bool request_ufd_features(int ufd, uint64_t features) in request_ufd_features() argument
266 if (ioctl(ufd, UFFDIO_API, &api_struct)) { in request_ufd_features()
283 static bool ufd_check_and_apply(int ufd, MigrationIncomingState *mis, in ufd_check_and_apply() argument
318 if (!request_ufd_features(ufd, asked_features)) { in ufd_check_and_apply()
376 int ufd = -1; in postcopy_ram_supported_by_host() local
389 ufd = uffd_open(O_CLOEXEC); in postcopy_ram_supported_by_host()
390 if (ufd == -1) { in postcopy_ram_supported_by_host()
401 if (!ufd_check_and_apply(ufd, mis, errp)) { in postcopy_ram_supported_by_host()
450 if (ioctl(ufd, UFFDIO_REGISTER, ®_struct)) { in postcopy_ram_supported_by_host()
457 if (ioctl(ufd, UFFDIO_UNREGISTER, &range_struct)) { in postcopy_ram_supported_by_host()
477 if (ufd != -1) { in postcopy_ram_supported_by_host()
478 close(ufd); in postcopy_ram_supported_by_host()