qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] Fix not white-listed copy-before-write
@ 2021-09-20 11:55 Vladimir Sementsov-Ogievskiy
  2021-09-20 11:55 ` [PATCH 1/5] block: implement bdrv_new_open_driver_opts() Vladimir Sementsov-Ogievskiy
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Vladimir Sementsov-Ogievskiy @ 2021-09-20 11:55 UTC (permalink / raw)
  To: qemu-block; +Cc: qemu-devel, hreitz, kwolf, vsementsov

Hi all!

As reported in https://bugzilla.redhat.com/show_bug.cgi?id=2004812
backup don't work when copy-before-write is not white-listed.

Yes, we do need copy-before-write filter for backup to work (like we
always use copy-on-read filter in block-stream).
The problem is that in bdrv_insert_node() (called to insert filters
internally) we use bdrv_open(), which does a lot of things we don't need
for internal node creation and among them check the white-list.

Backup job should of course work when copy-before-write is not
white-listed. As well, block-stream should work with not-white-listed
copy-on-read. White-list is for user, not for internal implementation.

Following Kevin's suggestion fix the problem by implementing a version
of bdrv_new_open_driver() that supports QDict of options, and use it
instead of bdrv_open().

Vladimir Sementsov-Ogievskiy (5):
  block: implement bdrv_new_open_driver_opts()
  block: bdrv_insert_node(): fix and improve error handling
  block: bdrv_insert_node(): doc and style
  block: bdrv_insert_node(): don't use bdrv_open()
  iotests/image-fleecing: declare requirement of copy-before-write

 include/block/block.h                   |  4 ++
 block.c                                 | 77 ++++++++++++++++++++-----
 tests/qemu-iotests/tests/image-fleecing |  1 +
 3 files changed, 68 insertions(+), 14 deletions(-)

-- 
2.29.2



^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-09-21 14:35 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-09-20 11:55 [PATCH 0/5] Fix not white-listed copy-before-write Vladimir Sementsov-Ogievskiy
2021-09-20 11:55 ` [PATCH 1/5] block: implement bdrv_new_open_driver_opts() Vladimir Sementsov-Ogievskiy
2021-09-20 11:55 ` [PATCH 2/5] block: bdrv_insert_node(): fix and improve error handling Vladimir Sementsov-Ogievskiy
2021-09-20 11:55 ` [PATCH 3/5] block: bdrv_insert_node(): doc and style Vladimir Sementsov-Ogievskiy
2021-09-20 11:55 ` [PATCH 4/5] block: bdrv_insert_node(): don't use bdrv_open() Vladimir Sementsov-Ogievskiy
2021-09-21 14:33   ` Kevin Wolf
2021-09-20 11:55 ` [PATCH 5/5] iotests/image-fleecing: declare requirement of copy-before-write Vladimir Sementsov-Ogievskiy

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).