From: Paolo Bonzini <pbonzini@redhat.com>
To: qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>,
Markus Armbruster <armbru@redhat.com>,
qemu-block@nongnu.org, Max Reitz <mreitz@redhat.com>
Subject: [Qemu-devel] [RFC PATCH 0/2] Early release of -drive QemuOpts
Date: Fri, 8 Jan 2016 18:37:43 +0100 [thread overview]
Message-ID: <1452274665-23061-1-git-send-email-pbonzini@redhat.com> (raw)
In short, this patch gets rid of blockdev_mark_auto_del and
blockdev_auto_del.
With these patches, it is possible to create a new -drive with the same
id as soon as the DEVICE_DELETED event is delivered (which equals to
unrealize).
I'm sorry I'm not able to explain the history (and probably do not
understand the full ramifications) of this. That's why this is just
an RFC.
The idea here is that reference counting the BlockBackend is enough to
defer the deletion of the block device as much as necessary; anticipating
the demise of the DriveInfo is not a problem, and has the desired effect
of freeing the QemuOpts.
Paolo
Paolo Bonzini (2):
block: detach devices from DriveInfo at unrealize time
block: remove legacy_dinfo at blk_detach_dev time
block/block-backend.c | 14 ++++++++----
blockdev.c | 26 ++++++++------------------
hw/block/virtio-blk.c | 4 +++-
hw/block/xen_disk.c | 1 +
hw/core/qdev-properties-system.c | 2 +-
hw/ide/piix.c | 3 +++
hw/scsi/scsi-bus.c | 4 +++-
hw/usb/dev-storage.c | 3 ++-
include/sysemu/blockdev.h | 5 ++---
9 files changed, 33 insertions(+), 29 deletions(-)
--
2.5.0
next reply other threads:[~2016-01-08 17:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-08 17:37 Paolo Bonzini [this message]
2016-01-08 17:37 ` [Qemu-devel] [PATCH 1/2] block: detach devices from DriveInfo at unrealize time Paolo Bonzini
2016-01-08 17:37 ` [Qemu-devel] [PATCH 2/2] block: remove legacy_dinfo at blk_detach_dev time Paolo Bonzini
2016-01-22 14:01 ` [Qemu-devel] [RFC PATCH 0/2] Early release of -drive QemuOpts Paolo Bonzini
2016-01-22 22:38 ` Max Reitz
2016-02-04 23:01 ` Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1452274665-23061-1-git-send-email-pbonzini@redhat.com \
--to=pbonzini@redhat.com \
--cc=armbru@redhat.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).