mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 15:23:53 -06:00
qapi event: convert other BLOCK_JOB events
Since BLOCK_JOB_COMPLETED, BLOCK_JOB_CANCELLED, BLOCK_JOB_READY are related, convert them in one patch. The block_job_event_* functions are used to keep encapsulation of BlockJob structure. Signed-off-by: Wenchao Xia <wenchaoqemu@gmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
This commit is contained in:
parent
c120f0fa14
commit
bcada37b19
6 changed files with 111 additions and 100 deletions
|
@ -217,12 +217,21 @@ void block_job_pause(BlockJob *job);
|
|||
void block_job_resume(BlockJob *job);
|
||||
|
||||
/**
|
||||
* qobject_from_block_job:
|
||||
* block_job_event_cancle:
|
||||
* @job: The job whose information is requested.
|
||||
*
|
||||
* Return a QDict corresponding to @job's query-block-jobs entry.
|
||||
* Send a BLOCK_JOB_CANCELLED event for the specified job.
|
||||
*/
|
||||
QObject *qobject_from_block_job(BlockJob *job);
|
||||
void block_job_event_cancelled(BlockJob *job);
|
||||
|
||||
/**
|
||||
* block_job_ready:
|
||||
* @job: The job which is now ready to complete.
|
||||
* @msg: Error message. Only present on failure.
|
||||
*
|
||||
* Send a BLOCK_JOB_COMPLETED event for the specified job.
|
||||
*/
|
||||
void block_job_event_completed(BlockJob *job, const char *msg);
|
||||
|
||||
/**
|
||||
* block_job_ready:
|
||||
|
@ -230,7 +239,7 @@ QObject *qobject_from_block_job(BlockJob *job);
|
|||
*
|
||||
* Send a BLOCK_JOB_READY event for the specified job.
|
||||
*/
|
||||
void block_job_ready(BlockJob *job);
|
||||
void block_job_event_ready(BlockJob *job);
|
||||
|
||||
/**
|
||||
* block_job_is_paused:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue