DPDK patches and discussions
 help / color / mirror / Atom feed
From: Maxime Coquelin <maxime.coquelin@redhat.com>
To: David Marchand <david.marchand@redhat.com>,
	dev@dpdk.org, Chenbo Xia <chenbo.xia@intel.com>
Cc: stable@dpdk.org, Jianfeng Tan <jianfeng.tan@intel.com>,
	Junjie Chen <junjie.j.chen@intel.com>,
	Hyong Youb Kim <hyonkim@cisco.com>,
	Harman Kalra <hkalra@marvell.com>
Subject: Re: [PATCH 3/3] net/vhost: fix Rx interrupt
Date: Tue, 14 Mar 2023 12:07:15 +0100	[thread overview]
Message-ID: <629c72b7-b18e-3bd4-b412-2e26dab52306@redhat.com> (raw)
In-Reply-To: <CAJFAV8wAXD3KyC5vqW9BMAEf1NJYgDR1NtDH1ssOq2SiJe142Q@mail.gmail.com>



On 3/14/23 09:59, David Marchand wrote:
> On Thu, Mar 9, 2023 at 1:38 PM David Marchand <david.marchand@redhat.com> wrote:
>>
>> In the situation when a port was started while no virtio driver was
>> connected, Rx interrupts were broken.
>> They were also broken after a virtio driver reconnects.
>>
>> There were several issues mixed in:
>> - this driver was not exposing a fixed file descriptor per Rx queue,
>>    If a virtio driver was not connected yet, each Rx queue vector was
>>    pointing at a -1 fd, and an application could interpret this as a lack
>>    of Rx interrupt support,
>> - when a virtio driver later (re)connected, this net/vhost driver was
>>    hacking into the EAL layer epoll fd to remove a old vring kickfd and
>>    insert the new vring kickfd. This hack constitutes a layer violation
>>    plus users of rte_eth_dev_rx_intr_ctl_q_get_fd() were not notified of
>>    this change,
>> - in the case of reconnection, because the interrupt handle was
>>    reallocated, a 0 fd was failing to be removed from the EAL layer
>>    epoll fd, which resulted in never fixing the EAL epoll fd,
>>
>> To fix Rx interrupts:
>> - allocating (eth_vhost_install_intr) / releasing
>>    (eth_vhost_uninstall_intr) the interrupt handle is moved when
>>    starting / closing the port, while setting / resetting per rxq fd is
>>    triggered by vhost events via some new helpers (see
>>    eth_vhost_configure_intr and eth_vhost_unconfigure_intr),
>> - a "proxy" epoll fd is created per Rx queue at the time the interrupt
>>    handle is allocated, so applications can start waiting for events on
>>    those fds, even before a virtio driver initialises,
>> - when available, vring kickd are populated in the "proxy" epoll fd,
>>
> 
> Maxime, Chenbo,
> 
> Dukai confirms this series fix it, we can mark this patch as fixing:
> Bugzilla ID: 1135
> 
> Do you want me to respin a series or can you fix when applying?

I can do it while preparing the pull request.

Thanks,
Maxime

> 
>> Fixes: 3f8ff12821e4 ("vhost: support interrupt mode")
>> Fixes: 3d4cd4be577c ("net/vhost: fix interrupt mode")
>> Fixes: d61138d4f0e2 ("drivers: remove direct access to interrupt handle")
>> Cc: stable@dpdk.org
>>
>> Signed-off-by: David Marchand <david.marchand@redhat.com>
> 
> Thanks.
> 
> 


  reply	other threads:[~2023-03-14 11:07 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-09 12:37 [PATCH 0/3] net/vhost pmd fixes for Rx interrupts David Marchand
2023-03-09 12:37 ` [PATCH 1/3] net/vhost: add missing newline in logs David Marchand
2023-03-10  3:16   ` Xia, Chenbo
2023-03-09 12:37 ` [PATCH 2/3] net/vhost: fix leak in interrupt handle setup David Marchand
2023-03-10  3:16   ` Xia, Chenbo
2023-03-09 12:37 ` [PATCH 3/3] net/vhost: fix Rx interrupt David Marchand
2023-03-10  7:35   ` Xia, Chenbo
2023-03-13  2:39   ` Yuan, DukaiX
2023-03-14  8:59   ` David Marchand
2023-03-14 11:07     ` Maxime Coquelin [this message]
2023-03-16 14:47 ` [PATCH 0/3] net/vhost pmd fixes for Rx interrupts Maxime Coquelin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=629c72b7-b18e-3bd4-b412-2e26dab52306@redhat.com \
    --to=maxime.coquelin@redhat.com \
    --cc=chenbo.xia@intel.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=hkalra@marvell.com \
    --cc=hyonkim@cisco.com \
    --cc=jianfeng.tan@intel.com \
    --cc=junjie.j.chen@intel.com \
    --cc=stable@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).