All of lore.kernel.org
 help / color / mirror / Atom feed
From: Magnus Karlsson <magnus.karlsson@gmail.com>
To: David Ahern <dsahern@gmail.com>
Cc: "Toke Høiland-Jørgensen" <toke@redhat.com>,
	"David Ahern" <dahern@digitalocean.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	"Jason Wang" <jasowang@redhat.com>,
	"David Ahern" <dsahern@kernel.org>,
	"Network Development" <netdev@vger.kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	"Jakub Kicinski" <kuba@kernel.org>,
	"Jesper Dangaard Brouer" <brouer@redhat.com>,
	"Magnus Karlsson" <magnus.karlsson@intel.com>
Subject: Re: [PATCH RFC net-next] virtio_net: Relax queue requirement for using XDP
Date: Mon, 28 Sep 2020 16:25:01 +0200	[thread overview]
Message-ID: <CAJ8uoz2bj0YWH5K6OW8m+BC06QZTSYW=xbApuEDK5pRCx+RLAA@mail.gmail.com> (raw)
In-Reply-To: <b6609e0a-eb2f-78bd-b565-c56dce9e2e48@gmail.com>

On Mon, Sep 28, 2020 at 5:13 AM David Ahern <dsahern@gmail.com> wrote:
>
> On 2/27/20 2:41 AM, Magnus Karlsson wrote:
> > I will unfortunately be after Netdevconf due to other commitments. The
> > plan is to send out the RFC to the co-authors of the Plumbers
> > presentation first, just to check the sanity of it. And after that
> > send it to the mailing list. Note that I have taken two shortcuts in
> > the RFC to be able to make quicker progress. The first on is the
> > driver implementation of the dynamic queue allocation and
> > de-allocation. It just does this within a statically pre-allocated set
> > of queues. The second is that the user space interface is just a
> > setsockopt instead of a rtnetlink interface. Again, just to save some
> > time in this initial phase. The information communicated in the
> > interface is the same though. In the current code, the queue manager
> > can handle the queues of the networking stack, the XDP_TX queues and
> > queues allocated by user space and used for AF_XDP. Other uses from
> > user space is not covered due to my setsockopt shortcut. Hopefully
> > though, this should be enough for an initial assessment.
>
> Any updates on the RFC? I do not recall seeing a patch set on the
> mailing list, but maybe I missed it.

No, you have unfortunately not missed anything. It has been lying on
the shelf collecting dust for most of this time. The reason was that
the driver changes needed to support dynamic queue allocation just
became too complex as it would require major surgery to at least all
Intel drivers, and probably a large number of other ones as well. Do
not think any vendor would support such a high effort solution and I
could not (at that time at least) find a way around it. So, gaining
visibility into what queues have been allocated (by all entities in
the kernel that uses queue) seems to be rather straightforward, but
the dynamic allocation part seems to be anything but.

I also wonder how useful this queue manager proposal would be in light
of Mellanox's subfunction proposal. If people just start to create
many small netdevs (albeit at high cost which people may argue
against) consisting of just an rx/tx queue pair, then the queue
manager dynamic allocation proposal would not be as useful. We could
just use one of these netdevs to bind to in the AF_XDP case and always
just specify queue 0. But one can argue that queue management is
needed even for the subfunction approach, but then it would be at a
much lower level than what I proposed. What is your take on this?
Still worth pursuing in some form or another? If yes, then we really
need to come up with an easy way of supporting this in current
drivers. It is not going to fly otherwise, IMHO.

  reply	other threads:[~2020-09-28 14:25 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-26  0:57 [PATCH RFC net-next] virtio_net: Relax queue requirement for using XDP David Ahern
2020-02-26  1:37 ` Jakub Kicinski
2020-02-26  3:00 ` Jason Wang
2020-02-26  3:24   ` David Ahern
2020-02-26  3:29     ` Jason Wang
2020-02-26  3:34       ` David Ahern
2020-02-26  3:52         ` Jason Wang
2020-02-26  4:35           ` David Ahern
2020-02-26  5:51             ` Jason Wang
2020-02-26  8:19     ` Toke Høiland-Jørgensen
2020-02-26  8:23       ` Michael S. Tsirkin
2020-02-26  8:34         ` Toke Høiland-Jørgensen
2020-02-26  8:42           ` Michael S. Tsirkin
2020-02-26  9:02             ` Toke Høiland-Jørgensen
2020-02-26  9:32               ` Michael S. Tsirkin
2020-02-26 15:58           ` David Ahern
2020-02-26 16:21             ` Toke Høiland-Jørgensen
2020-02-26 17:08             ` Michael S. Tsirkin
2020-02-26 21:31               ` Toke Høiland-Jørgensen
2020-02-27  3:27           ` David Ahern
2020-02-27 10:19             ` Toke Høiland-Jørgensen
2020-02-27 10:41               ` Magnus Karlsson
2020-09-28  3:13                 ` David Ahern
2020-09-28 14:25                   ` Magnus Karlsson [this message]
2020-09-29  2:44                     ` David Ahern
2020-02-26  6:48   ` Michael S. Tsirkin
2020-02-26  7:28     ` Jason Wang
2020-02-26  8:21       ` Michael S. Tsirkin
2020-02-26  6:43 ` Michael S. Tsirkin

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='CAJ8uoz2bj0YWH5K6OW8m+BC06QZTSYW=xbApuEDK5pRCx+RLAA@mail.gmail.com' \
    --to=magnus.karlsson@gmail.com \
    --cc=brouer@redhat.com \
    --cc=dahern@digitalocean.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@gmail.com \
    --cc=dsahern@kernel.org \
    --cc=jasowang@redhat.com \
    --cc=kuba@kernel.org \
    --cc=magnus.karlsson@intel.com \
    --cc=mst@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=toke@redhat.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.