[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3 8/9] jobs: remove ret argument to job_complet
From: |
Max Reitz |
Subject: |
Re: [Qemu-devel] [PATCH v3 8/9] jobs: remove ret argument to job_completed; privatize it |
Date: |
Fri, 31 Aug 2018 15:25:00 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 |
On 2018-08-30 03:57, John Snow wrote:
> Jobs are now expected to return their retcode on the stack, from the
> .run callback, so we can remove that argument.
>
> job_cancel does not need to set -ECANCELED because job_completed will
> update the return code itself if the job was canceled.
>
> While we're here, make job_completed static to job.c and remove it from
> job.h; move the documentation of return code to the .run() callback and
> to the job->ret property, accordingly.
>
> Signed-off-by: John Snow <address@hidden>
> ---
> include/qemu/job.h | 28 +++++++++++++++-------------
> job.c | 11 ++++++-----
> trace-events | 2 +-
> 3 files changed, 22 insertions(+), 19 deletions(-)
Reviewed-by: Max Reitz <address@hidden>
signature.asc
Description: OpenPGP digital signature
- [Qemu-devel] [PATCH v3 1/9] jobs: change start callback to run callback, (continued)
- [Qemu-devel] [PATCH v3 1/9] jobs: change start callback to run callback, John Snow, 2018/08/29
- [Qemu-devel] [PATCH v3 2/9] jobs: canonize Error object, John Snow, 2018/08/29
- [Qemu-devel] [PATCH v3 5/9] block/mirror: utilize job_exit shim, John Snow, 2018/08/29
- [Qemu-devel] [PATCH v3 7/9] block/backup: make function variables consistently named, John Snow, 2018/08/29
- [Qemu-devel] [PATCH v3 8/9] jobs: remove ret argument to job_completed; privatize it, John Snow, 2018/08/29
- Re: [Qemu-devel] [PATCH v3 8/9] jobs: remove ret argument to job_completed; privatize it,
Max Reitz <=
- [Qemu-devel] [PATCH v3 9/9] jobs: remove job_defer_to_main_loop, John Snow, 2018/08/29
- [Qemu-devel] [PATCH v3 4/9] block/commit: utilize job_exit shim, John Snow, 2018/08/29
- [Qemu-devel] [PATCH v3 6/9] jobs: utilize job_exit shim, John Snow, 2018/08/29
- [Qemu-devel] [PATCH v3 3/9] jobs: add exit shim, John Snow, 2018/08/29
- Re: [Qemu-devel] [PATCH v3 0/9] jobs: Job Exit Refactoring Pt 1, Max Reitz, 2018/08/31