aboutsummaryrefslogtreecommitdiff
path: root/hw/timer/puv3_ost.c
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2016-07-15 12:31:59 -0600
committerStefan Hajnoczi <stefanha@redhat.com>2016-07-20 14:11:54 +0100
commit1a62d0accdf85fbeac149018ee8d1728e754de73 (patch)
tree60774298934aa4df5a07c36874d490dd45c35c64 /hw/timer/puv3_ost.c
parent338404d061144956b76f9893ca3434d057dff2d4 (diff)
downloadqemu-1a62d0accdf85fbeac149018ee8d1728e754de73.zip
qemu-1a62d0accdf85fbeac149018ee8d1728e754de73.tar.gz
qemu-1a62d0accdf85fbeac149018ee8d1728e754de73.tar.bz2
block: Fragment reads to max transfer length
Drivers should be able to rely on the block layer honoring the max transfer length, rather than needing to return -EINVAL (iscsi) or manually fragment things (nbd). This patch adds the fragmentation in the block layer, after requests have been aligned (fragmenting before alignment would lead to multiple unaligned requests, rather than just the head and tail). The return value was previously nebulous on success on whether it was zero or the length read; and fragmenting may introduce yet other non-zero values if we use the last length read. But as at least some callers are sloppy and expect only zero on success, it is easiest to just guarantee 0. [Fix uninitialized ret local variable in bdrv_aligned_preadv(). --Stefan] Signed-off-by: Eric Blake <eblake@redhat.com> Message-id: 1468607524-19021-2-git-send-email-eblake@redhat.com Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'hw/timer/puv3_ost.c')
0 files changed, 0 insertions, 0 deletions