[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 09/14] backup: Pack Notifier within BackupBlockJ
From: |
Max Reitz |
Subject: |
Re: [Qemu-devel] [PATCH 09/14] backup: Pack Notifier within BackupBlockJob |
Date: |
Fri, 13 May 2016 17:01:46 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.0 |
On 04.05.2016 11:39, Kevin Wolf wrote:
> From: John Snow <address@hidden>
>
> Instead of relying on peeking at bs->job, we want to explicitly get
> a reference to the job that was involved in this notifier callback.
>
> Pack the Notifier inside of the BackupBlockJob so we can use
> container_of to get a reference back to the BackupBlockJob object.
>
> This cuts out one more case where we rely unnecessarily on bs->job.
>
> Suggested-by: Paolo Bonzini <address@hidden>
> Signed-off-by: John Snow <address@hidden>
> Signed-off-by: Kevin Wolf <address@hidden>
> ---
> block/backup.c | 19 ++++++++++---------
> 1 file changed, 10 insertions(+), 9 deletions(-)
Reviewed-by: Max Reitz <address@hidden>
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-devel] [PATCH 02/14] block: Cancel jobs first in bdrv_close_all(), (continued)
- [Qemu-devel] [PATCH 11/14] block: Add blk_co_readv/writev(), Kevin Wolf, 2016/05/04
- [Qemu-devel] [PATCH 10/14] backup: Remove bs parameter from backup_do_cow(), Kevin Wolf, 2016/05/04
- [Qemu-devel] [PATCH 14/14] blockjob: Remove BlockJob.bs, Kevin Wolf, 2016/05/04
- [Qemu-devel] [PATCH 13/14] commit: Use BlockBackend for I/O, Kevin Wolf, 2016/05/04
- [Qemu-devel] [PATCH 09/14] backup: Pack Notifier within BackupBlockJob, Kevin Wolf, 2016/05/04
- Re: [Qemu-devel] [PATCH 09/14] backup: Pack Notifier within BackupBlockJob,
Max Reitz <=
- [Qemu-devel] [PATCH 07/14] mirror: Use BlockBackend for I/O, Kevin Wolf, 2016/05/04
- [Qemu-devel] [PATCH 12/14] backup: Use BlockBackend for I/O, Kevin Wolf, 2016/05/04