virtio-blk: reorganize virtblk_add_req
authorPaolo Bonzini <pbonzini@redhat.com>
Wed, 20 Mar 2013 05:14:27 +0000 (15:44 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Wed, 20 Mar 2013 05:14:54 +0000 (15:44 +1030)
commit5ee21a52c05b5670ceeaa502c15cf306e379f714
tree99b49e570c77cd7c7114a0d999257e21d2ca144b
parente538ebaf78455ff87dec2c34d4f9c128844e3f3f
virtio-blk: reorganize virtblk_add_req

Right now, both virtblk_add_req and virtblk_add_req_wait call
virtqueue_add_buf.  To prepare for the next patches, abstract the call
to virtqueue_add_buf into a new function __virtblk_add_req, and include
the waiting logic directly in virtblk_add_req.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Asias He <asias@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
drivers/block/virtio_blk.c