Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-16 Thread Andreas Färber
Am 12.12.2012 18:53, schrieb Andreas Färber: > Finally supplying a public device_initialize() or so would be helpful > for the latter since VMState cannot cross pointers IIRC. I'll look into > that part since inlining the old qdev functions cripples my Tegra work. Investigating this, it turned out

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-16 Thread Michael S. Tsirkin
On Thu, Dec 13, 2012 at 08:51:30AM -0600, Anthony Liguori wrote: > Paolo Bonzini writes: > > > Il 12/12/2012 18:58, Peter Maydell ha scritto: > >> It should be equally > >> valid to just use the PCI transport plugged into a VirtioDevice, > >> both of which were created by the user with -device [a

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-13 Thread Anthony Liguori
Paolo Bonzini writes: > Il 12/12/2012 18:58, Peter Maydell ha scritto: >> It should be equally >> valid to just use the PCI transport plugged into a VirtioDevice, >> both of which were created by the user with -device [and for >> new transports, separate transport and backend should be the >> sta

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-13 Thread KONRAD Frédéric
On 13/12/2012 09:24, KONRAD Frédéric wrote: On 12/12/2012 15:25, Peter Maydell wrote: On 10 December 2012 16:45, wrote: -static void virtio_blk_class_init(ObjectClass *klass, void *data) -{ -DeviceClass *dc = DEVICE_CLASS(klass); -PCIDeviceClass *k = PCI_DEVICE_CLASS(klass); - -k->

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-13 Thread Paolo Bonzini
Il 12/12/2012 22:22, Michael S. Tsirkin ha scritto: > > > It should be equally > > > valid to just use the PCI transport plugged into a VirtioDevice, > > > both of which were created by the user with -device [and for > > > new transports, separate transport and backend should be the > > > standard]

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-13 Thread KONRAD Frédéric
On 12/12/2012 18:58, Peter Maydell wrote: On 12 December 2012 17:53, Andreas Färber wrote: Am 12.12.2012 15:25, schrieb Peter Maydell: How will the PCI transport's PCI vendor/device/class IDs be set (a) when a virtio-blk backend is created and separately plugged into a virtio-pci transport (b)

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-13 Thread KONRAD Frédéric
On 11/12/2012 18:50, Peter Maydell wrote: On 10 December 2012 16:45, wrote: From: KONRAD Frederic Here the virtio-blk-pci is modified for the new API. The device virtio-pci-blk extends virtio-pci. It creates and connects a virtio-blk during the init. Did you check whether this maintains bac

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-13 Thread KONRAD Frédéric
On 12/12/2012 15:25, Peter Maydell wrote: On 10 December 2012 16:45, wrote: -static void virtio_blk_class_init(ObjectClass *klass, void *data) -{ -DeviceClass *dc = DEVICE_CLASS(klass); -PCIDeviceClass *k = PCI_DEVICE_CLASS(klass); - -k->init = virtio_blk_init_pci; -k->exit = v

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-12 Thread Michael S. Tsirkin
On Wed, Dec 12, 2012 at 07:03:21PM +0100, Paolo Bonzini wrote: > Il 12/12/2012 18:58, Peter Maydell ha scritto: > > It should be equally > > valid to just use the PCI transport plugged into a VirtioDevice, > > both of which were created by the user with -device [and for > > new transports, separate

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-12 Thread Paolo Bonzini
Il 12/12/2012 18:58, Peter Maydell ha scritto: > It should be equally > valid to just use the PCI transport plugged into a VirtioDevice, > both of which were created by the user with -device [and for > new transports, separate transport and backend should be the > standard]. That means the virtio-b

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-12 Thread Peter Maydell
On 12 December 2012 17:53, Andreas Färber wrote: > Am 12.12.2012 15:25, schrieb Peter Maydell: >> How will the PCI transport's PCI vendor/device/class IDs be >> set (a) when a virtio-blk backend is created and separately >> plugged into a virtio-pci transport (b) for the legacy >> virtio-pci-blk?

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-12 Thread Paolo Bonzini
Il 12/12/2012 18:53, Andreas Färber ha scritto: > Am 12.12.2012 15:25, schrieb Peter Maydell: >> How will the PCI transport's PCI vendor/device/class IDs be >> set (a) when a virtio-blk backend is created and separately >> plugged into a virtio-pci transport (b) for the legacy >> virtio-pci-blk? [i

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-12 Thread Andreas Färber
Am 12.12.2012 15:25, schrieb Peter Maydell: > How will the PCI transport's PCI vendor/device/class IDs be > set (a) when a virtio-blk backend is created and separately > plugged into a virtio-pci transport (b) for the legacy > virtio-pci-blk? [ideally the answer to (b) should be "in the > same way

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-12 Thread Peter Maydell
On 10 December 2012 16:45, wrote: > -static void virtio_blk_class_init(ObjectClass *klass, void *data) > -{ > -DeviceClass *dc = DEVICE_CLASS(klass); > -PCIDeviceClass *k = PCI_DEVICE_CLASS(klass); > - > -k->init = virtio_blk_init_pci; > -k->exit = virtio_blk_exit_pci; > -k->v

Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-11 Thread Peter Maydell
On 10 December 2012 16:45, wrote: > From: KONRAD Frederic > > Here the virtio-blk-pci is modified for the new API. The device virtio-pci-blk > extends virtio-pci. It creates and connects a virtio-blk during the init. Did you check whether this maintains backwards compatibility for vmstate migra

[Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.

2012-12-10 Thread fred . konrad
From: KONRAD Frederic Here the virtio-blk-pci is modified for the new API. The device virtio-pci-blk extends virtio-pci. It creates and connects a virtio-blk during the init. Signed-off-by: KONRAD Frederic --- hw/virtio-pci.c | 113 +++- hw/v