]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
vfio: Make vfio_viommu_preset() static
authorCédric Le Goater <clg@redhat.com>
Wed, 26 Mar 2025 07:50:50 +0000 (08:50 +0100)
committerCédric Le Goater <clg@redhat.com>
Fri, 25 Apr 2025 07:01:37 +0000 (09:01 +0200)
This routine is only used in file "migration.c". Move it there.

Reviewed-by: John Levon <john.levon@nutanix.com>
Reviewed-by: Joao Martins <joao.m.martins@oracle.com>
Link: https://lore.kernel.org/qemu-devel/20250318095415.670319-6-clg@redhat.com
Link: https://lore.kernel.org/qemu-devel/20250326075122.1299361-6-clg@redhat.com
Signed-off-by: Cédric Le Goater <clg@redhat.com>
hw/vfio/common.c
hw/vfio/migration.c
include/hw/vfio/vfio-common.h

index d65e77b93a15dff8ef244e296ff073c906e4af35..679076343ac0a736a4f6fe597c2f851a87381a41 100644 (file)
@@ -65,11 +65,6 @@ int vfio_kvm_device_fd = -1;
  */
 
 
-bool vfio_viommu_preset(VFIODevice *vbasedev)
-{
-    return vbasedev->bcontainer->space->as != &address_space_memory;
-}
-
 bool vfio_device_state_is_running(VFIODevice *vbasedev)
 {
     VFIOMigration *migration = vbasedev->migration;
index ace3d8548edfa438a6479df6a617ceb8f495c622..b5bb0cd09252deb8fdd87879e2a6802efa6d94a8 100644 (file)
@@ -1138,6 +1138,11 @@ bool vfio_migration_active(void)
     return true;
 }
 
+static bool vfio_viommu_preset(VFIODevice *vbasedev)
+{
+    return vbasedev->bcontainer->space->as != &address_space_memory;
+}
+
 /*
  * Return true when either migration initialized or blocker registered.
  * Currently only return false when adding blocker fails which will
index 5f1c0bee9de3b4ed38a63872bca7db5bde3815c4..8c5692150698b9a4a8eb534bafc5623d9cf2d5a5 100644 (file)
@@ -290,7 +290,6 @@ extern VFIODeviceList vfio_device_list;
 extern const MemoryListener vfio_memory_listener;
 extern int vfio_kvm_device_fd;
 
-bool vfio_viommu_preset(VFIODevice *vbasedev);
 void vfio_migration_add_bytes_transferred(unsigned long val);
 bool vfio_device_state_is_running(VFIODevice *vbasedev);
 bool vfio_device_state_is_precopy(VFIODevice *vbasedev);