All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: linux-kernel@vger.kernel.org
Cc: John Fastabend <john.fastabend@gmail.com>
Subject: [PATCH 0/6] virtio: support extra per-buffer context
Date: Wed, 29 Mar 2017 23:48:43 +0300	[thread overview]
Message-ID: <1490820507-8005-1-git-send-email-mst@redhat.com> (raw)

virtio net is resorting to hacks in order to fit all per-buffer info in a
single 64 bit value. But in fact we have some unused memory there - normally
used for indirect descriptors - that we can utilize without slowing everyone
down.

Add APIs to do exactly that, and use them to simplify mergeable
buffer handling code.

This will also easily enable switching XDP mode on/off without doing device
resets (leading to packet drops), and more optimizations.

Michael S. Tsirkin (6):
  virtio: wrap find_vqs
  virtio: add context flag to find vqs
  virtio: allow extra context per descriptor
  virtio_net: allow specifying context for rx
  virtio_net: rework mergeable buffer handling
  virtio_net: reduce alignment for buffers

 drivers/block/virtio_blk.c                 |   3 +-
 drivers/char/virtio_console.c              |   6 +-
 drivers/crypto/virtio/virtio_crypto_core.c |   3 +-
 drivers/gpu/drm/virtio/virtgpu_kms.c       |   3 +-
 drivers/misc/mic/vop/vop_main.c            |   9 ++-
 drivers/net/caif/caif_virtio.c             |   3 +-
 drivers/net/virtio_net.c                   | 116 ++++++++++++++---------------
 drivers/rpmsg/virtio_rpmsg_bus.c           |   2 +-
 drivers/s390/virtio/kvm_virtio.c           |   6 +-
 drivers/s390/virtio/virtio_ccw.c           |   7 +-
 drivers/scsi/virtio_scsi.c                 |   3 +-
 drivers/virtio/virtio_balloon.c            |   3 +-
 drivers/virtio/virtio_input.c              |   3 +-
 drivers/virtio/virtio_mmio.c               |   8 +-
 drivers/virtio/virtio_pci_common.c         |  18 +++--
 drivers/virtio/virtio_pci_common.h         |   4 +-
 drivers/virtio/virtio_pci_legacy.c         |   4 +-
 drivers/virtio/virtio_pci_modern.c         |  12 ++-
 drivers/virtio/virtio_ring.c               |  77 +++++++++++++++----
 include/linux/virtio.h                     |   9 +++
 include/linux/virtio_config.h              |  25 ++++++-
 include/linux/virtio_ring.h                |   3 +
 net/vmw_vsock/virtio_transport.c           |   6 +-
 23 files changed, 212 insertions(+), 121 deletions(-)

-- 
MST

             reply	other threads:[~2017-03-29 20:53 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-29 20:48 Michael S. Tsirkin [this message]
2017-03-29 20:48 ` [PATCH 1/6] virtio: wrap find_vqs Michael S. Tsirkin
2017-03-29 20:48   ` Michael S. Tsirkin
2017-03-30  0:50   ` Gonglei (Arei)
2017-03-30  0:50   ` Gonglei (Arei)
2017-03-30  0:50     ` Gonglei (Arei)
2017-03-30  0:50     ` Gonglei (Arei)
2017-03-30  0:50     ` Gonglei (Arei)
2017-03-30  6:00   ` Jason Wang
2017-03-30  6:00   ` Jason Wang
2017-03-30  6:00     ` Jason Wang
2017-03-30 14:32     ` Michael S. Tsirkin
2017-03-30 14:32       ` Michael S. Tsirkin
2017-03-31  4:04       ` Jason Wang
2017-03-31  4:04       ` Jason Wang
2017-03-31  4:04         ` Jason Wang
2017-03-31 16:21         ` Michael S. Tsirkin
2017-03-31 16:21           ` Michael S. Tsirkin
2017-03-31 16:21         ` Michael S. Tsirkin
2017-03-30 14:32     ` Michael S. Tsirkin
2017-03-30  7:18   ` Cornelia Huck
2017-03-30  7:18     ` Cornelia Huck
2017-03-30  7:18   ` Cornelia Huck
2017-04-01 16:13   ` Bjorn Andersson
2017-04-01 16:13     ` Bjorn Andersson
2017-03-29 20:48 ` [PATCH 2/6] virtio: add context flag to find vqs Michael S. Tsirkin
2017-03-29 20:48   ` Michael S. Tsirkin
2017-03-30  7:17   ` Cornelia Huck
2017-03-30  7:17     ` Cornelia Huck
2017-03-30 14:57     ` Michael S. Tsirkin
2017-03-30 14:57       ` Michael S. Tsirkin
2017-03-30  7:17   ` Cornelia Huck
2017-03-29 20:48 ` [PATCH 3/6] virtio: allow extra context per descriptor Michael S. Tsirkin
2017-03-29 20:48   ` Michael S. Tsirkin
2017-03-30  7:23   ` Cornelia Huck
2017-03-30  7:23     ` Cornelia Huck
2017-03-30 14:34     ` Michael S. Tsirkin
2017-03-30 14:34       ` Michael S. Tsirkin
2017-03-29 20:48 ` [PATCH 4/6] virtio_net: allow specifying context for rx Michael S. Tsirkin
2017-03-29 20:48   ` Michael S. Tsirkin
2017-03-30  7:26   ` Cornelia Huck
2017-03-30 14:31     ` Michael S. Tsirkin
2017-03-30 14:46       ` Cornelia Huck
2017-03-30 14:46         ` Cornelia Huck
2017-03-30 14:31     ` Michael S. Tsirkin
2017-03-30  7:26   ` Cornelia Huck
2017-03-29 20:48 ` [PATCH 5/6] virtio_net: rework mergeable buffer handling Michael S. Tsirkin
2017-03-29 20:48   ` Michael S. Tsirkin
2017-03-29 20:48 ` [PATCH 6/6] virtio_net: reduce alignment for buffers Michael S. Tsirkin
2017-03-29 20:48   ` 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=1490820507-8005-1-git-send-email-mst@redhat.com \
    --to=mst@redhat.com \
    --cc=john.fastabend@gmail.com \
    --cc=linux-kernel@vger.kernel.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 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.