Several changes:

* NBD client/server for tapdisk.
* block-export for mirroring to xapi's import-raw-vdi
* The ability to add a mirror when unpausing a VDI
Rename nbd.h to tapdisk-nbd.h to avoid collision with system nbd.h

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
* Add pause/unpause logic to the nbd server
* clean up stale unix domain sockets on image close.
* Don't close the nbdserver when you detach the vdi
Several minor fixups:

* On resume, only re-enable events on the listening TCP socket if it had
  previously been in use
* Remove several spammy debug messages
* Kill the read path in the NBD client code - this is for mirroring
  only.

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
Use async IO in block-nbd.c

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
Add status reporting of the mirror status.

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
Add the ability to remove a secondary image on unpause

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
Ensure that an zero length recv in nbdserver_clientcb closes the connection

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
Detect premature server shutdown in NBD client

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
Fix error handling when the NBD mirroring times out

Signed-off-by: Jon Ludlam <jonathan.ludlam@eu.citrix.com>
Merge branch 'master' of git://hg.uk.xensource.com/carbon/trunk-ring3/blktap
Merge commit 'a5fdb9a2301936339259ffe7649aa6af4339c4b9'
Remove unused driver (block-export)
Coding style cleanup for NBD code to match the rest of blktap code.

Linux coding style is used for this repository.
Fix a couple of memory leaks
Clean up fdreceiver sockets on exit
Merge commit 'e4af93420ebfb0569a416f07d02b7c9bfeb8190d'
Fix the build on x86_64

The compiler points out that the comparison between "int request"
and BLKGETSIZE64 is always false, since BLKGETSIZE64 is a large
long long.

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Merge commit '4a556d4599956c885c921fd8648149dbda3e43d2'
correctly set return code