]> git.proxmox.com Git - mirror_qemu.git/commit - block/vhdx.c
block: Change bdrv_{pread,pwrite,pwrite_sync}() param order
authorAlberto Faria <afaria@redhat.com>
Thu, 9 Jun 2022 15:27:36 +0000 (16:27 +0100)
committerHanna Reitz <hreitz@redhat.com>
Tue, 12 Jul 2022 10:14:55 +0000 (12:14 +0200)
commit32cc71def9e3885f9527af713e6d8dc7521ddc08
tree9ec7c6a1c10523d79b9b8aeb4ba6ace82c3f5b87
parent53fb7844f03241a0e6de2c342c9e1b89df12da4d
block: Change bdrv_{pread,pwrite,pwrite_sync}() param order

Swap 'buf' and 'bytes' around for consistency with
bdrv_co_{pread,pwrite}(), and in preparation to implement these
functions using generated_co_wrapper.

Callers were updated using this Coccinelle script:

    @@ expression child, offset, buf, bytes, flags; @@
    - bdrv_pread(child, offset, buf, bytes, flags)
    + bdrv_pread(child, offset, bytes, buf, flags)

    @@ expression child, offset, buf, bytes, flags; @@
    - bdrv_pwrite(child, offset, buf, bytes, flags)
    + bdrv_pwrite(child, offset, bytes, buf, flags)

    @@ expression child, offset, buf, bytes, flags; @@
    - bdrv_pwrite_sync(child, offset, buf, bytes, flags)
    + bdrv_pwrite_sync(child, offset, bytes, buf, flags)

Resulting overly-long lines were then fixed by hand.

Signed-off-by: Alberto Faria <afaria@redhat.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
Message-Id: <20220609152744.3891847-3-afaria@redhat.com>
Reviewed-by: Hanna Reitz <hreitz@redhat.com>
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
24 files changed:
block/blklogwrites.c
block/bochs.c
block/cloop.c
block/crypto.c
block/dmg.c
block/io.c
block/parallels-ext.c
block/parallels.c
block/qcow.c
block/qcow2-bitmap.c
block/qcow2-cache.c
block/qcow2-cluster.c
block/qcow2-refcount.c
block/qcow2-snapshot.c
block/qcow2.c
block/qed.c
block/vdi.c
block/vhdx-log.c
block/vhdx.c
block/vmdk.c
block/vpc.c
block/vvfat.c
include/block/block-io.h
tests/unit/test-block-iothread.c