OSDN Git Service

migration/rdma: It makes no sense to recive that flag without RDMA
authorJuan Quintela <quintela@redhat.com>
Thu, 4 May 2023 11:44:42 +0000 (13:44 +0200)
committerJuan Quintela <quintela@redhat.com>
Thu, 4 May 2023 23:04:32 +0000 (01:04 +0200)
This could only happen if the source sent
RAM_SAVE_FLAG_HOOK (i.e. rdma) and destination don't have CONFIG_RDMA.

Signed-off-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230504114443.23891-5-quintela@redhat.com>

migration/qemu-file.c

index b7afc8d..578b630 100644 (file)
@@ -345,14 +345,6 @@ void ram_control_load_hook(QEMUFile *f, uint64_t flags, void *data)
         if (ret < 0) {
             qemu_file_set_error(f, ret);
         }
-    } else {
-        /*
-         * Hook is a hook specifically requested by the source sending a flag
-         * that expects there to be a hook on the destination.
-         */
-        if (flags == RAM_CONTROL_HOOK) {
-            qemu_file_set_error(f, -EINVAL);
-        }
     }
 }