From 70f0da6df2adb1c74f5daa9b72ef0d45d4bdb214 Mon Sep 17 00:00:00 2001 From: Patrick Roy Date: Thu, 31 Oct 2024 11:57:28 +0000 Subject: [PATCH] fix: drop cfg(target_arch) from create_guest_memfd The KVM docs do not list this ioctls as restricted to any specific architecture. It is instead discoverable via capabilities, and can theoretically work on any architecture (provided the architecture has a VM type that support guest private memory). Signed-off-by: Patrick Roy --- src/ioctls/vm.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/ioctls/vm.rs b/src/ioctls/vm.rs index 654727cc..edc63e41 100644 --- a/src/ioctls/vm.rs +++ b/src/ioctls/vm.rs @@ -1474,7 +1474,6 @@ impl VmFd { /// /// let guest_memfd = vm.create_guest_memfd(gmem).unwrap(); /// ``` - #[cfg(any(target_arch = "x86_64", target_arch = "aarch64"))] pub fn create_guest_memfd(&self, gmem: kvm_create_guest_memfd) -> Result { // SAFETY: Safe because we know that our file is a VM fd, we know the kernel will only // read the correct amount of memory from our pointer, and we verify the return result.