Thread (38 messages) 38 messages, 2 authors, 2017-04-01

Re: [PATCH v2 2/5] net/virtio: add interrupt configure for vdev

From: Yuanhan Liu <hidden>
Date: 2017-03-29 07:11:22

On Wed, Mar 29, 2017 at 03:03:16PM +0800, Tan, Jianfeng wrote:

On 3/29/2017 2:27 PM, Yuanhan Liu wrote:
quoted
On Tue, Mar 28, 2017 at 08:21:53AM +0000, Jianfeng Tan wrote:
quoted
For virtio PCI devices, interrupt should be configured before setting
VIRTIO_CONFIG_STATUS_DRIVER_OK so that QEMU can properly set eventfds
in the host.

For virtio virtual devices, VIRTIO_CONFIG_STATUS_DRIVER_OK should be
set firstly, so that intr_handle is initialized in
virtio_user_start_device().
I'm wondering why can't you let virtio-user follow virtio-pci?
It's because that virtio-user not only counts on virtio_user_start_device()
to allocate intr_handle, it also needs the information in this function to
initialize this struct. For virtio-pci, similar information is from
rte_intr_enable/rte_intr_efd_enable.

Or do you mean we can move calling virtio_user_start_device() ahead? I can
hardly find other place instead of DRIVER_OK.
For example, virtio_user_dev_init()?

	--yliu
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help