34 lines
928 B
Diff
34 lines
928 B
Diff
|
|
From a9459c849c5484a022f67a317b72de764c84c845 Mon Sep 17 00:00:00 2001
|
||
|
|
From: Jinhua Cao <caojinhua1@huawei.com>
|
||
|
|
Date: Thu, 10 Feb 2022 20:21:33 +0800
|
||
|
|
Subject: [PATCH] vhost-user: add unregister_savevm when vhost-user cleanup
|
||
|
|
|
||
|
|
Signed-off-by: Jinhua Cao <caojinhua1@huawei.com>
|
||
|
|
---
|
||
|
|
hw/virtio/vhost-user.c | 2 ++
|
||
|
|
1 file changed, 2 insertions(+)
|
||
|
|
|
||
|
|
diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c
|
||
|
|
index bf6e50223c..c265e9e92c 100644
|
||
|
|
--- a/hw/virtio/vhost-user.c
|
||
|
|
+++ b/hw/virtio/vhost-user.c
|
||
|
|
@@ -24,6 +24,7 @@
|
||
|
|
#include "sysemu/cryptodev.h"
|
||
|
|
#include "migration/migration.h"
|
||
|
|
#include "migration/postcopy-ram.h"
|
||
|
|
+#include "migration/register.h"
|
||
|
|
#include "trace.h"
|
||
|
|
|
||
|
|
#include <sys/ioctl.h>
|
||
|
|
@@ -2068,6 +2069,7 @@ static int vhost_user_backend_cleanup(struct vhost_dev *dev)
|
||
|
|
u->region_rb_len = 0;
|
||
|
|
g_free(u);
|
||
|
|
dev->opaque = 0;
|
||
|
|
+ unregister_savevm(NULL, "vhost-user", dev);
|
||
|
|
|
||
|
|
return 0;
|
||
|
|
}
|
||
|
|
--
|
||
|
|
2.27.0
|
||
|
|
|