net/virtio: support RSS
authorMaxime Coquelin <maxime.coquelin@redhat.com>
Wed, 27 Oct 2021 14:22:09 +0000 (16:22 +0200)
committerMaxime Coquelin <maxime.coquelin@redhat.com>
Fri, 29 Oct 2021 09:23:10 +0000 (11:23 +0200)
commit0c9d662070547189b65a532d6318de6d793e3155
treee074921148236ea7d989715924d66ef6f6f22fda
parent9446d7fcd9f3993600e918401de667736b72b9bf
net/virtio: support RSS

Provide the capability to update the hash key, hash types
and RETA table on the fly (without needing to stop/start
the device). However, the key length and the number of RETA
entries are fixed to 40B and 128 entries respectively. This
is done in order to simplify the design, but may be
revisited later as the Virtio spec provides this
flexibility.

Note that only VIRTIO_NET_F_RSS support is implemented,
VIRTIO_NET_F_HASH_REPORT, which would enable reporting the
packet RSS hash calculated by the device into mbuf.rss, is
not yet supported.

Regarding the default RSS configuration, it has been
chosen to use the default Intel ixgbe key as default key,
and default RETA is a simple modulo between the hash and
the number of Rx queues.

Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Reviewed-by: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
doc/guides/nics/features/virtio.ini
doc/guides/nics/virtio.rst
doc/guides/rel_notes/release_21_11.rst
drivers/net/virtio/virtio.h
drivers/net/virtio/virtio_ethdev.c
drivers/net/virtio/virtio_ethdev.h
drivers/net/virtio/virtqueue.h