]> git.proxmox.com Git - mirror_qemu.git/commit - qapi/block-core.json
blockjobs: add block-job-finalize
authorJohn Snow <jsnow@redhat.com>
Sat, 10 Mar 2018 08:27:43 +0000 (03:27 -0500)
committerKevin Wolf <kwolf@redhat.com>
Mon, 19 Mar 2018 11:01:24 +0000 (12:01 +0100)
commit11b61fbc0d1a447849f36d76e0e1d05be2dfaad2
tree93bb4e5cc3452c6bc62021b982506b2f0187d133
parent5f241594c40875af526a53c7a8c6466e487f4e5e
blockjobs: add block-job-finalize

Instead of automatically transitioning from PENDING to CONCLUDED, gate
the .prepare() and .commit() phases behind an explicit acknowledgement
provided by the QMP monitor if auto_finalize = false has been requested.

This allows us to perform graph changes in prepare and/or commit so that
graph changes do not occur autonomously without knowledge of the
controlling management layer.

Transactions that have reached the "PENDING" state together can all be
moved to invoke their finalization methods by issuing block_job_finalize
to any one job in the transaction.

Jobs in a transaction with mixed job->auto_finalize settings will all
remain stuck in the "PENDING" state, as if the entire transaction was
specified with auto_finalize = false. Jobs that specified
auto_finalize = true, however, will still not emit the PENDING event.

Signed-off-by: John Snow <jsnow@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block/trace-events
blockdev.c
blockjob.c
include/block/blockjob.h
qapi/block-core.json