|
|
0a7476 |
From a2f60e6e90112f4bf4a8c2e68d76f472c88b7074 Mon Sep 17 00:00:00 2001
|
|
|
0a7476 |
Message-Id: <a2f60e6e90112f4bf4a8c2e68d76f472c88b7074@dist-git>
|
|
|
0a7476 |
From: Michal Privoznik <mprivozn@redhat.com>
|
|
|
0a7476 |
Date: Thu, 11 Apr 2019 15:14:22 -0400
|
|
|
0a7476 |
Subject: [PATCH] qemu_hotplug: Assume chardev alias always exists in
|
|
|
0a7476 |
qemuDomainDetachChrDevice
|
|
|
0a7476 |
|
|
|
0a7476 |
The @tmpChr is looked up in domain definition based on user
|
|
|
0a7476 |
provided chardev XML. Therefore, the alias must have been
|
|
|
0a7476 |
allocated already when domain was started up.
|
|
|
0a7476 |
|
|
|
0a7476 |
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
|
|
|
0a7476 |
Reviewed-by: John Ferlan <jferlan@redhat.com>
|
|
|
0a7476 |
(cherry picked from commit 5657e22212c54651a9e098ceb79c5522d55e0114)
|
|
|
0a7476 |
|
|
|
0a7476 |
Partially-Resolves: https://bugzilla.redhat.com/1658198
|
|
|
0a7476 |
Signed-off-by: Laine Stump <laine@redhat.com>
|
|
|
0a7476 |
Signed-off-by: Laine Stump <laine@laine.org>
|
|
|
0a7476 |
Message-Id: <20190411191453.24055-11-laine@redhat.com>
|
|
|
0a7476 |
Acked-by: Michal Privoznik <mprivozn@redhat.com>
|
|
|
0a7476 |
---
|
|
|
0a7476 |
src/qemu/qemu_hotplug.c | 5 -----
|
|
|
0a7476 |
1 file changed, 5 deletions(-)
|
|
|
0a7476 |
|
|
|
0a7476 |
diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c
|
|
|
0a7476 |
index d4444bbb5d..36840f977e 100644
|
|
|
0a7476 |
--- a/src/qemu/qemu_hotplug.c
|
|
|
0a7476 |
+++ b/src/qemu/qemu_hotplug.c
|
|
|
0a7476 |
@@ -5607,11 +5607,6 @@ int qemuDomainDetachChrDevice(virQEMUDriverPtr driver,
|
|
|
0a7476 |
guestfwd = tmpChr->deviceType == VIR_DOMAIN_CHR_DEVICE_TYPE_CHANNEL &&
|
|
|
0a7476 |
tmpChr->targetType == VIR_DOMAIN_CHR_CHANNEL_TARGET_TYPE_GUESTFWD;
|
|
|
0a7476 |
|
|
|
0a7476 |
- if (!tmpChr->info.alias && qemuAssignDeviceChrAlias(vmdef, tmpChr, -1) < 0)
|
|
|
0a7476 |
- goto cleanup;
|
|
|
0a7476 |
-
|
|
|
0a7476 |
- sa_assert(tmpChr->info.alias);
|
|
|
0a7476 |
-
|
|
|
0a7476 |
if (!async && !guestfwd)
|
|
|
0a7476 |
qemuDomainMarkDeviceForRemoval(vm, &tmpChr->info);
|
|
|
0a7476 |
|
|
|
0a7476 |
--
|
|
|
0a7476 |
2.21.0
|
|
|
0a7476 |
|