qemu-e2k/block
Daniel P. Berrange 064097d919 nbd: convert block client to use I/O channels for connection setup
This converts the NBD block driver client to use the QIOChannelSocket
class for initial connection setup. The NbdClientSession struct has
two pointers, one to the master QIOChannelSocket providing the raw
data channel, and one to a QIOChannel which is the current channel
used for I/O. Initially the two point to the same object, but when
TLS support is added, they will point to different objects.

The qemu-img & qemu-io tools now need to use MODULE_INIT_QOM to
ensure the QIOChannel object classes are registered. The qemu-nbd
tool already did this.

In this initial conversion though, all I/O is still actually done
using the raw POSIX sockets APIs.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Message-Id: <1455129674-17255-4-git-send-email-berrange@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2016-02-16 17:13:22 +01:00
..
Makefile.objs block: convert quorum blockdrv to use crypto APIs 2015-07-08 13:11:01 +02:00
accounting.c block: Clean up includes 2016-01-20 13:36:23 +01:00
archipelago.c block: Clean up includes 2016-01-20 13:36:23 +01:00
backup.c block: Clean up includes 2016-01-20 13:36:23 +01:00
blkdebug.c block: Clean up includes 2016-01-20 13:36:23 +01:00
blkverify.c block: Clean up includes 2016-01-20 13:36:23 +01:00
block-backend.c block: Add blk_remove_all_bs() 2016-02-02 17:50:46 +01:00
bochs.c block: Clean up includes 2016-01-20 13:36:23 +01:00
cloop.c block: Clean up includes 2016-01-20 13:36:23 +01:00
commit.c block: Clean up includes 2016-01-20 13:36:23 +01:00
curl.c block: Clean up includes 2016-01-20 13:36:23 +01:00
dmg.c block: Clean up includes 2016-01-20 13:36:23 +01:00
gluster.c block: Clean up includes 2016-01-20 13:36:23 +01:00
io.c block: add missing call to bdrv_drain_recurse 2016-02-09 13:52:26 +00:00
iscsi.c iscsi: Assign bs to file in iscsi_co_get_block_status 2016-02-02 17:50:47 +01:00
linux-aio.c block: Clean up includes 2016-01-20 13:36:23 +01:00
mirror.c block: Add "file" output parameter to block status query functions 2016-02-02 17:50:47 +01:00
nbd-client.c nbd: convert block client to use I/O channels for connection setup 2016-02-16 17:13:22 +01:00
nbd-client.h nbd: convert block client to use I/O channels for connection setup 2016-02-16 17:13:22 +01:00
nbd.c nbd: convert block client to use I/O channels for connection setup 2016-02-16 17:13:22 +01:00
nfs.c block: Clean up includes 2016-01-20 13:36:23 +01:00
null.c block: Clean up includes 2016-01-20 13:36:23 +01:00
parallels.c parallels: Assign bs->file->bs to file in parallels_co_get_block_status 2016-02-02 17:50:47 +01:00
qapi.c qapi: Swap visit_* arguments for consistent 'name' placement 2016-02-08 17:29:56 +01:00
qcow.c qcow: Assign bs->file->bs to file in qcow_co_get_block_status 2016-02-02 17:50:47 +01:00
qcow2-cache.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qcow2-cluster.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qcow2-refcount.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qcow2-snapshot.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qcow2.c qcow2: Assign bs->file->bs to file in qcow2_co_get_block_status 2016-02-02 17:50:47 +01:00
qcow2.h qcow2: Add function for refcount order amendment 2015-12-18 14:34:43 +01:00
qed-check.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qed-cluster.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qed-gencb.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qed-l2-cache.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qed-table.c block: Clean up includes 2016-01-20 13:36:23 +01:00
qed.c qed: Assign bs->file->bs to file in bdrv_qed_co_get_block_status 2016-02-02 17:50:47 +01:00
qed.h qed: Really remove unused field QEDAIOCB.finished 2015-02-06 17:24:21 +01:00
quorum.c block: Clean up includes 2016-01-20 13:36:23 +01:00
raw-aio.h linux-aio: drop return code from laio_io_unplug and ioq_submit 2014-12-12 16:57:55 +00:00
raw-posix.c raw: Assign bs to file in raw_co_get_block_status 2016-02-02 17:50:47 +01:00
raw-win32.c block: Clean up includes 2016-01-20 13:36:23 +01:00
raw_bsd.c raw: Assign bs to file in raw_co_get_block_status 2016-02-02 17:50:47 +01:00
rbd.c block: Clean up includes 2016-01-20 13:36:23 +01:00
sheepdog.c sheepdog: Assign bs to file in sd_co_get_block_status 2016-02-02 17:50:47 +01:00
snapshot.c block: Clean up includes 2016-01-20 13:36:23 +01:00
ssh.c block: Clean up includes 2016-01-20 13:36:23 +01:00
stream.c block: Clean up includes 2016-01-20 13:36:23 +01:00
throttle-groups.c block: Clean up includes 2016-01-20 13:36:23 +01:00
vdi.c vdi: Assign bs->file->bs to file in vdi_co_get_block_status 2016-02-02 17:50:47 +01:00
vhdx-endian.c block: Clean up includes 2016-01-20 13:36:23 +01:00
vhdx-log.c block: Clean up includes 2016-01-20 13:36:23 +01:00
vhdx.c block: Clean up includes 2016-01-20 13:36:23 +01:00
vhdx.h block: vhdx - update PAYLOAD_BLOCK_UNMAPPED value to match 1.00 spec 2014-12-12 15:42:22 +00:00
vmdk.c vmdk: Return extent's file in bdrv_get_block_status 2016-02-02 17:50:47 +01:00
vpc.c vpc: Assign bs->file->bs to file in vpc_co_get_block_status 2016-02-02 17:50:47 +01:00
vvfat.c block: Add "file" output parameter to block status query functions 2016-02-02 17:50:47 +01:00
win32-aio.c block: Clean up includes 2016-01-20 13:36:23 +01:00
write-threshold.c block: Clean up includes 2016-01-20 13:36:23 +01:00