[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 01/19] vhost-user: save features if the char dev is closed
From: |
Michael S. Tsirkin |
Subject: |
[PULL 01/19] vhost-user: save features if the char dev is closed |
Date: |
Sat, 5 Oct 2019 17:58:37 -0400 |
From: Adrian Moreno <address@hidden>
That way the state can be correctly restored when the device is opened
again. This might happen if the backend is restarted.
Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=1738768
Reported-by: Pei Zhang <address@hidden>
Fixes: 6ab79a20af3a ("do not call vhost_net_cleanup() on running net from char
user event")
Cc: address@hidden
Cc: Michael S. Tsirkin <address@hidden>
Cc: address@hidden
Signed-off-by: Adrian Moreno <address@hidden>
Message-Id: <address@hidden>
Acked-by: Jason Wang <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
---
net/vhost-user.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/net/vhost-user.c b/net/vhost-user.c
index 51921de443..014199d600 100644
--- a/net/vhost-user.c
+++ b/net/vhost-user.c
@@ -235,6 +235,10 @@ static void chr_closed_bh(void *opaque)
s = DO_UPCAST(NetVhostUserState, nc, ncs[0]);
+ if (s->vhost_net) {
+ s->acked_features = vhost_net_get_acked_features(s->vhost_net);
+ }
+
qmp_set_link(name, false, &err);
qemu_chr_fe_set_handlers(&s->chr, NULL, NULL, net_vhost_user_event,
--
MST
- [PULL 00/19] virtio, vhost, acpi: features, fixes, tests, Michael S. Tsirkin, 2019/10/05
- [PULL 01/19] vhost-user: save features if the char dev is closed,
Michael S. Tsirkin <=
- [PULL 02/19] hw/acpi: Make ACPI IO address space configurable, Michael S. Tsirkin, 2019/10/05
- [PULL 03/19] hw/acpi: Do not create memory hotplug method when handler is not defined, Michael S. Tsirkin, 2019/10/05
- [PULL 04/19] hw/acpi: Add ACPI Generic Event Device Support, Michael S. Tsirkin, 2019/10/05
- [PULL 05/19] hw/arm/virt: Add memory hotplug framework, Michael S. Tsirkin, 2019/10/05
- [PULL 06/19] hw/arm/virt: Enable device memory cold/hot plug with ACPI boot, Michael S. Tsirkin, 2019/10/05
- [PULL 07/19] hw/arm/virt-acpi-build: Add PC-DIMM in SRAT, Michael S. Tsirkin, 2019/10/05
- [PULL 08/19] hw/arm: Factor out powerdown notifier from GPIO, Michael S. Tsirkin, 2019/10/05
- [PULL 09/19] hw/arm: Use GED for system_powerdown event, Michael S. Tsirkin, 2019/10/05
- [PULL 10/19] docs/specs: Add ACPI GED documentation, Michael S. Tsirkin, 2019/10/05
- [PULL 11/19] tests: Update ACPI tables list for upcoming arm/virt tests, Michael S. Tsirkin, 2019/10/05