[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-commits] [qemu/qemu] b807ca: xen-block: Fix removal of backend ins
From: |
Peter Maydell |
Subject: |
[Qemu-commits] [qemu/qemu] b807ca: xen-block: Fix removal of backend instance via xen... |
Date: |
Tue, 23 Mar 2021 09:55:11 -0700 |
Branch: refs/heads/staging
Home: https://github.com/qemu/qemu
Commit: b807ca3fa0ca29ec015adcf4045e716337cd3635
https://github.com/qemu/qemu/commit/b807ca3fa0ca29ec015adcf4045e716337cd3635
Author: Anthony PERARD <anthony.perard@citrix.com>
Date: 2021-03-23 (Tue, 23 Mar 2021)
Changed paths:
M hw/block/xen-block.c
Log Message:
-----------
xen-block: Fix removal of backend instance via xenstore
Whenever a Xen block device is detach via xenstore, the image
associated with it remained open by the backend QEMU and an error is
logged:
qemu-system-i386: failed to destroy drive: Node xvdz-qcow2 is in use
This happened since object_unparent() doesn't immediately frees the
object and thus keep a reference to the node we are trying to free.
The reference is hold by the "drive" property and the call
xen_block_drive_destroy() fails.
In order to fix that, we call drain_call_rcu() to run the callback
setup by bus_remove_child() via object_unparent().
Fixes: 2d24a6466154 ("device-core: use RCU for list of children of a bus")
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Paul Durrant <paul@xen.org>
Message-Id: <20210308143232.83388-1-anthony.perard@citrix.com>
Commit: ae3845efb306819f4c2693f64ed761c4ce5cd8e9
https://github.com/qemu/qemu/commit/ae3845efb306819f4c2693f64ed761c4ce5cd8e9
Author: Peter Maydell <peter.maydell@linaro.org>
Date: 2021-03-23 (Tue, 23 Mar 2021)
Changed paths:
M hw/block/xen-block.c
Log Message:
-----------
Merge remote-tracking branch 'remotes/aperard/tags/pull-xen-20210323' into
staging
Xen patch
- Fix Xen backend block detach via xenstore.
# gpg: Signature made Tue 23 Mar 2021 11:53:08 GMT
# gpg: using RSA key F80C006308E22CFD8A92E7980CF5572FD7FB55AF
# gpg: Good signature from "Anthony PERARD <anthony.perard@gmail.com>"
[marginal]
# gpg: aka "Anthony PERARD <anthony.perard@citrix.com>"
[marginal]
# gpg: WARNING: This key is not certified with sufficiently trusted signatures!
# gpg: It is not certain that the signature belongs to the owner.
# Primary key fingerprint: 5379 2F71 024C 600F 778A 7161 D8D5 7199 DF83 42C8
# Subkey fingerprint: F80C 0063 08E2 2CFD 8A92 E798 0CF5 572F D7FB 55AF
* remotes/aperard/tags/pull-xen-20210323:
xen-block: Fix removal of backend instance via xenstore
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Compare: https://github.com/qemu/qemu/compare/9950da284fa5...ae3845efb306
- [Qemu-commits] [qemu/qemu] b807ca: xen-block: Fix removal of backend instance via xen...,
Peter Maydell <=