Amit Shah <amit.s...@redhat.com> wrote: Hi
> + buf_size = iov_size(elem.out_sg, elem.out_num); > + buf = qemu_malloc(buf_size); > + ret = iov_to_buf(elem.out_sg, elem.out_num, buf, 0, buf_size); This is independent of the this series, but I think this idiom is going to be very common, perhaps having a helper that does it makes sense? Later, Juan.