diff options
author | Anthony Liguori <aliguori@us.ibm.com> | 2012-07-09 12:35:06 -0500 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2012-07-09 12:35:06 -0500 |
commit | 23797df3d9f08031d19aaaa1d2863d5feebe3d8b (patch) | |
tree | f5d64b0378d44db24d18dd5e869fdfa2253b6b45 /block/sheepdog.c | |
parent | 3f6e9a5fad982713440c636f5f7b786e1cc86ca2 (diff) | |
parent | 25e5e4c7e9d5ec3e95c9526d1abaca40ada50ab0 (diff) |
Merge remote-tracking branch 'mjt/mjt-iov2' into staging
* mjt/mjt-iov2:
rewrite iov_send_recv() and move it to iov.c
cleanup qemu_co_sendv(), qemu_co_recvv() and friends
export iov_send_recv() and use it in iov_send() and iov_recv()
rename qemu_sendv to iov_send, change proto and move declarations to iov.h
change qemu_iovec_to_buf() to match other to,from_buf functions
consolidate qemu_iovec_copy() and qemu_iovec_concat() and make them consistent
allow qemu_iovec_from_buffer() to specify offset from which to start copying
consolidate qemu_iovec_memset{,_skip}() into single function and use existing iov_memset()
rewrite iov_* functions
change iov_* function prototypes to be more appropriate
virtio-serial-bus: use correct lengths in control_out() message
Conflicts:
tests/Makefile
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'block/sheepdog.c')
-rw-r--r-- | block/sheepdog.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/block/sheepdog.c b/block/sheepdog.c index 6e73efbad1..809df39d9e 100644 --- a/block/sheepdog.c +++ b/block/sheepdog.c @@ -745,8 +745,8 @@ static void coroutine_fn aio_read_response(void *opaque) } break; case AIOCB_READ_UDATA: - ret = qemu_co_recvv(fd, acb->qiov->iov, rsp.data_length, - aio_req->iov_offset); + ret = qemu_co_recvv(fd, acb->qiov->iov, acb->qiov->niov, + aio_req->iov_offset, rsp.data_length); if (ret < 0) { error_report("failed to get the data, %s", strerror(errno)); goto out; @@ -1019,7 +1019,7 @@ static int coroutine_fn add_aio_request(BDRVSheepdogState *s, AIOReq *aio_req, } if (wlen) { - ret = qemu_co_sendv(s->fd, iov, wlen, aio_req->iov_offset); + ret = qemu_co_sendv(s->fd, iov, niov, aio_req->iov_offset, wlen); if (ret < 0) { qemu_co_mutex_unlock(&s->lock); error_report("failed to send a data, %s", strerror(errno)); |