[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOU
From: |
Michael S. Tsirkin |
Subject: |
Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user |
Date: |
Mon, 8 Jun 2015 12:09:38 +0200 |
On Mon, Jun 08, 2015 at 12:01:38PM +0200, Thibaut Collet wrote:
> Hi,
>
> I agree that my patch is OK only for recent drivers. To have a simple patch
> with only few modifications I do not implement a solution for old driver but I
> can be done later.
>
> For legacy guest without VIRTIO_NET_F_GUEST_ANNOUNCE the problem is more
> complex. The RARP must be sent by the vhost client/backend. This component is
> outside QEMU (the reference implementation is snabbswitch: http://
> www.virtualopensystems.com/en/solutions/guides/snabbswitch-qemu/). To do that:
> - a receive function must be defined for the vhost user.
> - a message must be added between QEMU and vapp. This message will be sent
> only
> for old guest driver to avoid GARP duplication.
> - the added self_announce_disabled must be removed (decision to send or not
> the
> RARP is done later by the backend and not by the generic migration method)
>
> Do you agree with this solution ?
>
>
> Regards.
I don't get it. Why do you need any extra messages for old drivers? To
detect old drivers, simply have backend check whether
VIRTIO_NET_F_GUEST_ANNOUNCE is set.
But I don't see this as a blocker for this patch,
this can be added separately as needed.
> On Mon, Jun 8, 2015 at 11:14 AM, Jason Wang <address@hidden> wrote:
>
>
>
> On 06/08/2015 04:21 PM, Thibaut Collet wrote:
> > Hi,
> >
> > My understanding of gratuitous packet with virtio for any backend
> > (vhost user or other):
> > - When the VM is loaded (first start or migration) the virtio net
> > interfaces are loaded ( virtio_net_load_device function in
> > hw/net/virtio-net.c)
> > - If the guest has the VIRTIO_NET_F_GUEST_ANNOUNCE capability, request
> > to send gratuitous packet is done.
> >
> > 1. To enable gratuitous packet through this mechanism I have
> > added VIRTIO_NET_F_GUEST_ANNOUNCE capability to hw/net/vhost_net.c. So
> > host and guest can negotiate this feature when vhost-user is used.
> >
> > 2. self announce occurs in case of live migration. During a live
> > migration a GARP is sent to all net backend through a queue dedicated
> > to the net backend.
> > But for vhost-user:
> > - this operation is not possible (vhost-user has no queue)
> > - it is already done with the previous mechanism.
> > Rather to define a queue to vhost user and notify twice the guest
> > to send gratuitous packet I have disable GARP from self announce and
> > use only the first mechanism for that.
> >
> > I have tested my modifications with guest that supports
> > VIRTIO_NET_F_GUEST_ANNOUNCE and vhost-user on the host. After a live
> > migration I have the GARP from the guest.
>
> Yes, your patch works well for recent drivers. But the problem is legacy
> guest/driver without VIRTIO_NET_F_GUEST_ANNOUNCE. In this case there
> will be no GARP sent after migration.
>
> Thanks
>
>
- Re: [Qemu-devel] [PATCH 1/1] net: fix queue's purge on VM stop, (continued)
- Re: [Qemu-devel] [PATCH 1/1] net: fix queue's purge on VM stop, Stefan Hajnoczi, 2015/06/02
- Re: [Qemu-devel] [PATCH 1/1] net: fix queue's purge on VM stop, Thibaut Collet, 2015/06/03
- Re: [Qemu-devel] [PATCH 1/1] net: fix queue's purge on VM stop, Jason Wang, 2015/06/03
- Re: [Qemu-devel] [PATCH 1/1] net: fix queue's purge on VM stop, Stefan Hajnoczi, 2015/06/03
- Re: [Qemu-devel] [PATCH 1/1] net: fix queue's purge on VM stop, Jason Wang, 2015/06/04
- [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Thibaut Collet, 2015/06/05
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Jason Wang, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Thibaut Collet, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Jason Wang, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Thibaut Collet, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user,
Michael S. Tsirkin <=
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Jason Wang, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Stefan Hajnoczi, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Thibaut Collet, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Stefan Hajnoczi, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Thibaut Collet, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Stefan Hajnoczi, 2015/06/09
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Stefan Hajnoczi, 2015/06/09
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Michael S. Tsirkin, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Jason Wang, 2015/06/08
- Re: [Qemu-devel] [PATCH v2] net: Add support of VIRTIO_NET_F_GUEST_ANNOUNCE for vhost-net/vhost-user, Michael S. Tsirkin, 2015/06/08