On 10 December 2012 16:45, <fred.kon...@greensocs.com> wrote: > From: KONRAD Frederic <fred.kon...@greensocs.com> > > As the virtio-blk-pci is switched to the new API, we can use QOM casts and > remove the separate init for the old API.
This patch effectively breaks virtio_blk_init() [because it removes the code path that handles s==NULL] but it does not actually remove that function, so it has not completely cleaned up the legacy code. It should be possible to inline the virtio_blk_common_init() function into virtio_device_init() then. We should end up with all the legacy stuff removed so the only APIs for manipulating virtio-blk are the qdev ones. Also some cleanup patch somewhere needs to get rid of the function pointers in VirtIODevice. (If the cleanup phase looks like it would be a bit hard to understand done as a single patch, feel free to split it suitably.) Incidentally this patch should probably have a note in the commit message that it's only intended to be applied after conversion of all the transports (ie of s390). Basically you need to keep going here to actually finish the demonstration of what the final cleaned up transport and backend look like. -- PMM