qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@gmail.com>
To: Vlad Yasevich <vyasevic@redhat.com>
Cc: qemu-devel@nongnu.org, stefanha@redhat.com, mst@redhat.com
Subject: Re: [Qemu-devel] [PATCH] net: Update netdev peer on link change
Date: Fri, 22 Nov 2013 12:03:05 +0100	[thread overview]
Message-ID: <20131122110305.GF24388@stefanha-thinkpad.redhat.com> (raw)
In-Reply-To: <1385085951-12729-1-git-send-email-vyasevic@redhat.com>

On Thu, Nov 21, 2013 at 09:05:51PM -0500, Vlad Yasevich wrote:
> When a link change occurs on a backend (like tap), we currently do
> not propage such change to the nic.  As a result, when someone turns
> off a link on a tap device, for instance, then a guest doesn't see
> that change and continues to try to send traffic or run DHCP even
> though the lower-layer is disconnected.  This is OK when the network
> is set up as a HUB since the the guest may be connected to other HUB
> ports too, but when it's set up as a netdev, it makes thinkgs worse.
> 
> The patch addresses this by setting the peers link down only when the
> peer is not a HUBPORT device.  With this patch, in the following config
>   -netdev tap,id=net0 -device e1000,mac=XXXXX,netdev=net0
> when net0 link is turned off, the guest e1000 shows lower-layer link
> down. This allows guests to boot much faster in such configurations.
> With windows guest, it also allows the network to recover properly
> since windows will not configure the link-local IPv4 address, and
> when the link is turned on, the proper address address is configured.
> 
> Signed-off-by: Vlad Yasevich <vyasevic@redhat.com>
> ---
>  net/net.c | 26 +++++++++++++++++---------
>  1 file changed, 17 insertions(+), 9 deletions(-)

Merged for QEMU 1.8.  Link state changes can lead to weird bugs so I
don't want to rush this into QEMU 1.7.

Thanks, applied to my net-next tree:
https://github.com/stefanha/qemu/commits/net-next

Stefan

  reply	other threads:[~2013-11-22 11:03 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-22  2:05 [Qemu-devel] [PATCH] net: Update netdev peer on link change Vlad Yasevich
2013-11-22 11:03 ` Stefan Hajnoczi [this message]
2014-04-02  8:51 ` Michael S. Tsirkin
2014-04-02 10:46   ` Yan Vugenfirer
2014-04-02 10:07     ` Michael S. Tsirkin
2014-04-02 14:57     ` Vlad Yasevich
2014-04-02 15:03       ` Michael S. Tsirkin
2014-04-02 15:25         ` Vlad Yasevich
2014-04-02 15:29           ` Michael S. Tsirkin
2014-04-02 15:40             ` Vlad Yasevich
2014-04-02 13:11   ` Vlad Yasevich

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=20131122110305.GF24388@stefanha-thinkpad.redhat.com \
    --to=stefanha@gmail.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.com \
    --cc=vyasevic@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 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).