qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


From: Anthony Liguori
Subject: Re: [Qemu-devel] [RFC PATCH v7 7/8] virtio-pci-blk : Switch to new API.
Date: Thu, 13 Dec 2012 08:51:30 -0600
User-agent: Notmuch/0.13.2+93~ged93d79 (http://notmuchmail.org) Emacs/23.3.1 (x86_64-pc-linux-gnu)

Paolo Bonzini <address@hidden> 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
>> standard]. That means the virtio-bus interface needs a way for
>> the backend to announce to the transport what it is so that
>> the PCI transport can set the right PCI IDs.
>
> There is such an interface (the device_id, aka VIRTIO_ID_*).  Then
> virtio-pci needs a mapping from the device_id to the (default)
> vendor_id/device_id/class tuple.

Why?

I think it's perfectly fine to have to specify a device ID for
virtio-pci.

The way virtio-pci is designed is such that every device that uses
virtio-pci ends up looking like an independent PCI device.

We should always have virtio-blk-pci, virtio-net-pci, etc.  The goal of
this refactoring should not be to eliminate that.

But these devices should be trivial to implement and modelled in a sane
way.

I don't think we should be trying to solve the problem of making
virtio-pci "easy to use".  Why would you say:

  -device virtio-pci,id=foo -device virtio-blk,bus=foo

When you can just say:

  -device virtio-pci-blk

I think we're optimizing for the wrong thing here...

Regards,

Anthony Liguori

>
> Paolo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]