Message ID | 4CC99FDC.9070102@parallels.com |
---|---|
State | Superseded, archived |
Delegated to: | David Miller |
Headers | show |
Le jeudi 28 octobre 2010 à 20:07 +0400, Pavel Emelyanov a écrit : > commit e985aad7 (ip_gre: percpu stats accounting) forgot the fallback > tunnel case (gre0). > > This is the 4th part of the "foo: fix percpu stats accounting" series ;) > > Signed-off-by: Pavel Emelyanov <xemul@openvz.org> > Indeed, right you are ;) Acked-by: Eric Dumazet <eric.dumazet@gmail.com> Anyway, I suspect more work is needed... (check patch against ixgbe : http://patchwork.ozlabs.org/patch/69458/ ) -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Eric Dumazet <eric.dumazet@gmail.com> Date: Thu, 28 Oct 2010 18:33:54 +0200 > Le jeudi 28 octobre 2010 à 20:07 +0400, Pavel Emelyanov a écrit : >> commit e985aad7 (ip_gre: percpu stats accounting) forgot the fallback >> tunnel case (gre0). >> >> This is the 4th part of the "foo: fix percpu stats accounting" series ;) >> >> Signed-off-by: Pavel Emelyanov <xemul@openvz.org> >> > > Indeed, right you are ;) > > Acked-by: Eric Dumazet <eric.dumazet@gmail.com> Applied. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Le jeudi 28 octobre 2010 à 10:29 -0700, David Miller a écrit : > From: Eric Dumazet <eric.dumazet@gmail.com> > Date: Thu, 28 Oct 2010 18:33:54 +0200 > > > Le jeudi 28 octobre 2010 à 20:07 +0400, Pavel Emelyanov a écrit : > >> commit e985aad7 (ip_gre: percpu stats accounting) forgot the fallback > >> tunnel case (gre0). > >> > >> This is the 4th part of the "foo: fix percpu stats accounting" series ;) > >> > >> Signed-off-by: Pavel Emelyanov <xemul@openvz.org> > >> > > > > Indeed, right you are ;) > > > > Acked-by: Eric Dumazet <eric.dumazet@gmail.com> > > Applied. Hmm, actually patch is buggy, sorry... -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Eric Dumazet <eric.dumazet@gmail.com> Date: Thu, 28 Oct 2010 20:38:58 +0200 > Le jeudi 28 octobre 2010 à 10:29 -0700, David Miller a écrit : >> From: Eric Dumazet <eric.dumazet@gmail.com> >> Date: Thu, 28 Oct 2010 18:33:54 +0200 >> >> > Le jeudi 28 octobre 2010 à 20:07 +0400, Pavel Emelyanov a écrit : >> >> commit e985aad7 (ip_gre: percpu stats accounting) forgot the fallback >> >> tunnel case (gre0). >> >> >> >> This is the 4th part of the "foo: fix percpu stats accounting" series ;) >> >> >> >> Signed-off-by: Pavel Emelyanov <xemul@openvz.org> >> >> >> > >> > Indeed, right you are ;) >> > >> > Acked-by: Eric Dumazet <eric.dumazet@gmail.com> >> >> Applied. > > > Hmm, actually patch is buggy, sorry... I am still able to revert this I think without screwing up publicly visible history, so I will double check and do the revert if I can. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Le jeudi 28 octobre 2010 à 11:41 -0700, David Miller a écrit : > I am still able to revert this I think without screwing up > publicly visible history, so I will double check and do the > revert if I can. Cool, I'll provide a patch in a couple of minutes, when tested. Thanks -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Eric Dumazet <eric.dumazet@gmail.com> Date: Thu, 28 Oct 2010 20:47:59 +0200 > Le jeudi 28 octobre 2010 à 11:41 -0700, David Miller a écrit : >> I am still able to revert this I think without screwing up >> publicly visible history, so I will double check and do the >> revert if I can. > > Cool, I'll provide a patch in a couple of minutes, when tested. Thanks. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c index 01087e0..be05d5b 100644 --- a/net/ipv4/ip_gre.c +++ b/net/ipv4/ip_gre.c @@ -1321,7 +1321,7 @@ static int ipgre_tunnel_init(struct net_device *dev) return 0; } -static void ipgre_fb_tunnel_init(struct net_device *dev) +static int ipgre_fb_tunnel_init(struct net_device *dev) { struct ip_tunnel *tunnel = netdev_priv(dev); struct iphdr *iph = &tunnel->parms.iph; @@ -1335,8 +1335,13 @@ static void ipgre_fb_tunnel_init(struct net_device *dev) iph->ihl = 5; tunnel->hlen = sizeof(struct iphdr) + 4; + dev->tstats = alloc_percpu(struct pcpu_tstats); + if (!dev->tstats) + return -ENOMEM; + dev_hold(dev); rcu_assign_pointer(ign->tunnels_wc[0], tunnel); + return 0; } @@ -1377,7 +1382,10 @@ static int __net_init ipgre_init_net(struct net *net) } dev_net_set(ign->fb_tunnel_dev, net); - ipgre_fb_tunnel_init(ign->fb_tunnel_dev); + err = ipgre_fb_tunnel_init(ign->fb_tunnel_dev); + if (err) + goto err_reg_dev; + ign->fb_tunnel_dev->rtnl_link_ops = &ipgre_link_ops; if ((err = register_netdev(ign->fb_tunnel_dev))) @@ -1386,7 +1394,7 @@ static int __net_init ipgre_init_net(struct net *net) return 0; err_reg_dev: - free_netdev(ign->fb_tunnel_dev); + ipgre_dev_free(ign->fb_tunnel_dev); err_alloc_dev: return err; }
commit e985aad7 (ip_gre: percpu stats accounting) forgot the fallback tunnel case (gre0). This is the 4th part of the "foo: fix percpu stats accounting" series ;) Signed-off-by: Pavel Emelyanov <xemul@openvz.org> --- -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html