mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
job: Move .complete callback to Job
This moves the .complete callback that tells a READY job to complete from BlockJobDriver to JobDriver. The wrapper function job_complete() doesn't require anything block job specific any more and can be moved to Job. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com>
This commit is contained in:
parent
b69f777dd9
commit
3453d97243
9 changed files with 43 additions and 48 deletions
|
@ -153,16 +153,6 @@ void block_job_set_speed(BlockJob *job, int64_t speed, Error **errp);
|
|||
*/
|
||||
void block_job_cancel(BlockJob *job, bool force);
|
||||
|
||||
/**
|
||||
* block_job_complete:
|
||||
* @job: The job to be completed.
|
||||
* @errp: Error object.
|
||||
*
|
||||
* Asynchronously complete the specified job.
|
||||
*/
|
||||
void block_job_complete(BlockJob *job, Error **errp);
|
||||
|
||||
|
||||
/**
|
||||
* block_job_finalize:
|
||||
* @job: The job to fully commit and finish.
|
||||
|
|
|
@ -38,12 +38,6 @@ struct BlockJobDriver {
|
|||
/** Generic JobDriver callbacks and settings */
|
||||
JobDriver job_driver;
|
||||
|
||||
/**
|
||||
* Optional callback for job types whose completion must be triggered
|
||||
* manually.
|
||||
*/
|
||||
void (*complete)(BlockJob *job, Error **errp);
|
||||
|
||||
/**
|
||||
* If the callback is not NULL, prepare will be invoked when all the jobs
|
||||
* belonging to the same transaction complete; or upon this job's completion
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue