qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/2] block: add missed block_acct_setup with new block device init procedure
@ 2022-08-22 10:31 Denis V. Lunev
  2022-08-22 10:31 ` [PATCH 1/2] target/hppa: Fix proberi instruction emulation for linux-user Denis V. Lunev
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Denis V. Lunev @ 2022-08-22 10:31 UTC (permalink / raw)
  To: qemu-block, qemu-devel
  Cc: Denis V . Lunev, Peter Krempa, Markus Armbruster, John Snow,
	Kevin Wolf, Hanna Reitz, Vladimir Sementsov-Ogievskiy

Commit 5f76a7aac156ca75680dad5df4a385fd0b58f6b1 is looking harmless from
the first glance, but it has changed things a lot. 'libvirt' uses it to
detect that it should follow new initialization way and this changes
things considerably. With this procedure followed, blockdev_init() is
not called anymore and thus block_acct_setup() helper is not called.

This means in particular that defaults for block accounting statistics
are changed and account_invalid/account_failed are actually initialized
as false instead of true originally.

This commit changes things to match original world. There are the following
constraints:
* new default value in block_acct_init() is set to true
* block_acct_setup() inside blockdev_init() is called before
  blkconf_apply_backend_options()
* thus newly created option in block device properties has precedence if
  specified

Changes from v2:
* called bool_from_onoffauto(account_..., true) in the first patch to
  preserve original semantics before patch 2

Changes from v1:
* set account_invalid/account_failed to true by default
* pass OnOffAuto to block_acct_init() to handle double initialization (patch 1)
* changed properties on BLK device to OnOffAuto

Signed-off-by: Denis V. Lunev <den@openvz.org>
CC: Peter Krempa <pkrempa@redhat.com>
CC: Markus Armbruster <armbru@redhat.com>
CC: John Snow <jsnow@redhat.com>
CC: Kevin Wolf <kwolf@redhat.com>
CC: Hanna Reitz <hreitz@redhat.com>
CC: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>




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

end of thread, other threads:[~2022-08-22 12:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-08-22 10:31 [PATCH v3 0/2] block: add missed block_acct_setup with new block device init procedure Denis V. Lunev
2022-08-22 10:31 ` [PATCH 1/2] target/hppa: Fix proberi instruction emulation for linux-user Denis V. Lunev
2022-08-22 12:38   ` Helge Deller
2022-08-22 10:31 ` [PATCH 2/2] block: pass OnOffAuto instead of bool to block_acct_setup() Denis V. Lunev
2022-08-22 10:38 ` [PATCH v3 0/2] block: add missed block_acct_setup with new block device init procedure Denis V. Lunev

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