From: "Eugenio Pérez" <eperezma@redhat.com>
To: qemu-devel@nongnu.org
Cc: Stefano Garzarella <sgarzare@redhat.com>,
Lei Yang <leiyang@redhat.com>,
Zhu Lingshan <lingshan.zhu@intel.com>,
Eli Cohen <eli@mellanox.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
Gautam Dawar <gdawar@xilinx.com>,
Jason Wang <jasowang@redhat.com>,
Parav Pandit <parav@mellanox.com>,
Laurent Vivier <lvivier@redhat.com>,
Si-Wei Liu <si-wei.liu@oracle.com>,
Harpreet Singh Anand <hanand@xilinx.com>,
Liuxiangdong <liuxiangdong5@huawei.com>,
Cindy Lu <lulu@redhat.com>
Subject: [PATCH v3 0/4] Guest announce feature emulation using Shadow VirtQueue
Date: Wed, 21 Dec 2022 12:50:11 +0100 [thread overview]
Message-ID: <20221221115015.1400889-1-eperezma@redhat.com> (raw)
A gratuitous ARP is recommended after a live migration to reduce the amount of
time needed by the network links to be aware of the new location. A hypervisor
may not have the knowledge of the guest network configuration, and this is
especially true on passthrough devices, so its simpler to ask the guest to
do it.
However, the device control part of this feature can be totally emulated by
qemu and shadow virtqueue, not needing any special feature from the actual
vdpa device.
The vdpa device must offer VIRTIO_NET_F_STATUS for the guest to access the
status of virtio net config where announcement status bit is set. It is
possible to emulate it as always active in case backend does not support it,
but this is left for the future, as there are not many devices not offering it
anyway.
Patch 1 is less useful now that we don't emulate _F_STATUS anymore but QEMU
coding style seems to prefer early return so leaving it in this version.
v3:
* Properly byte swap status field of config space exposed to the guest.
* Fix comment (s/dont/don't)
v2:
* Actually remove VIRTIO_NET_F_STATUS emulation. Comparing with v1, we offer
the feature with virtio instead of using virtio/vhost-vdpa.
v1:
* Move code from vhost_net_get_config to virtio_net_get_config.
RFC v2:
* Add VIRTIO_NET_F_STATUS emulation.
Eugenio Pérez (4):
virtio_net: Modify virtio_net_get_config to early return
virtio_net: copy VIRTIO_NET_S_ANNOUNCE if device model has it
vdpa: handle VIRTIO_NET_CTRL_ANNOUNCE in
vhost_vdpa_net_handle_ctrl_avail
vdpa: do not handle VIRTIO_NET_F_GUEST_ANNOUNCE in vhost-vdpa
hw/net/virtio-net.c | 30 +++++++++++++++++-------------
net/vhost-vdpa.c | 16 ++++++++++++----
2 files changed, 29 insertions(+), 17 deletions(-)
--
2.31.1
next reply other threads:[~2022-12-21 11:51 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-21 11:50 Eugenio Pérez [this message]
2022-12-21 11:50 ` [PATCH v3 1/4] virtio_net: Modify virtio_net_get_config to early return Eugenio Pérez
2022-12-21 11:50 ` [PATCH v3 2/4] virtio_net: copy VIRTIO_NET_S_ANNOUNCE if device model has it Eugenio Pérez
2022-12-22 5:14 ` Jason Wang
2022-12-21 11:50 ` [PATCH v3 3/4] vdpa: handle VIRTIO_NET_CTRL_ANNOUNCE in vhost_vdpa_net_handle_ctrl_avail Eugenio Pérez
2022-12-22 5:16 ` Jason Wang
2022-12-21 11:50 ` [PATCH v3 4/4] vdpa: do not handle VIRTIO_NET_F_GUEST_ANNOUNCE in vhost-vdpa Eugenio Pérez
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=20221221115015.1400889-1-eperezma@redhat.com \
--to=eperezma@redhat.com \
--cc=eli@mellanox.com \
--cc=gdawar@xilinx.com \
--cc=hanand@xilinx.com \
--cc=jasowang@redhat.com \
--cc=leiyang@redhat.com \
--cc=lingshan.zhu@intel.com \
--cc=liuxiangdong5@huawei.com \
--cc=lulu@redhat.com \
--cc=lvivier@redhat.com \
--cc=mst@redhat.com \
--cc=parav@mellanox.com \
--cc=qemu-devel@nongnu.org \
--cc=sgarzare@redhat.com \
--cc=si-wei.liu@oracle.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 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).