It took me a while to work out the "why" of patch 1. The answer is
because methods like sh_can_fua call sh_can_flush, and since
sh_can_flush is also called by core nbdkit you end up calling this
function twice.
I think patches 1 and 3 would have been easier to review if the
mechanical change to the handle struct was in a separate patch from
the change in caching logic, but I've reviewed them now.
ACK
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
virt-p2v converts physical machines to virtual machines. Boot with a
live CD or over the network (PXE) and turn machines into KVM guests.
http://libguestfs.org/virt-v2v