linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Fabio Estevam <festevam@gmail.com>
To: Thomas Zeitlhofer <thomas.zeitlhofer@nt.tuwien.ac.at>
Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	jasowang@redhat.com
Subject: Re: tuntap regression in v3.9.8 and v3.10
Date: Tue, 2 Jul 2013 18:01:12 -0300	[thread overview]
Message-ID: <CAOMZO5B7Yx7tRy8Q5wi6ngcD0FDJzKXHOEGPXyUo52+f3oUHEg@mail.gmail.com> (raw)
In-Reply-To: <20130702195910.GA20271@toau.bambla>

On Tue, Jul 2, 2013 at 4:59 PM, Thomas Zeitlhofer
<thomas.zeitlhofer@nt.tuwien.ac.at> wrote:
> Commit "tuntap: set SOCK_ZEROCOPY flag during open" introduces a
> regression which is observed with live migration of qemu/kvm based
> virtual machines that are connected to an openvswitch bridge.
>
> Reverting this commit (b26c93c46a3dec25ed236d4ba6107eb4ed5d9401 in
> v3.9.8 and accordingly 19a6afb23e5d323e1245baa4e62755492b2f1200 in
> v3.10) fixes the following problem:

Should the sock_set_flag stay in tun_set_iff as it was prior to 54f968d6efd?

--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -1652,6 +1652,7 @@ static int tun_set_iff(struct net *net, struct
file *file, struct ifreq *ifr)
                tun->txflt.count = 0;
                tun->vnet_hdr_sz = sizeof(struct virtio_net_hdr);

+               sock_set_flag(&tfile->sk, SOCK_ZEROCOPY);
                tun->filter_attached = false;
                tun->sndbuf = tfile->socket.sk->sk_sndbuf;

@@ -2159,8 +2160,6 @@ static int tun_chr_open(struct inode *inode,
struct file * file)
        set_bit(SOCK_EXTERNALLY_ALLOCATED, &tfile->socket.flags);
        INIT_LIST_HEAD(&tfile->next);

-       sock_set_flag(&tfile->sk, SOCK_ZEROCOPY);
-
        return 0;
 }

  reply	other threads:[~2013-07-02 21:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-02 19:59 tuntap regression in v3.9.8 and v3.10 Thomas Zeitlhofer
2013-07-02 21:01 ` Fabio Estevam [this message]
2013-07-02 22:06   ` Thomas Zeitlhofer
2013-07-03  2:44     ` Jason Wang
2013-07-03  6:11       ` Thomas Zeitlhofer
2013-07-05  3:43         ` Jason Wang
2013-07-05 13:02           ` Thomas Zeitlhofer

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=CAOMZO5B7Yx7tRy8Q5wi6ngcD0FDJzKXHOEGPXyUo52+f3oUHEg@mail.gmail.com \
    --to=festevam@gmail.com \
    --cc=jasowang@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=thomas.zeitlhofer@nt.tuwien.ac.at \
    /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).