Netdev List
 help / color / mirror / Atom feed
* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Eric Dumazet @ 2010-01-24 16:26 UTC (permalink / raw)
  To: Bruno Prémont; +Cc: Eric Dumazet, David S. Miller, netdev, linux-kernel
In-Reply-To: <20100124162549.2b39b222@neptune.home>

Le 24/01/2010 16:25, Bruno Prémont a écrit :
> 
> In addition to previous mail, I'm also dumping the result of
> vlan_dev_info(dev) shows that the returned pointer is not the same
> during vlan_dev_init() and vlan_skb_recv() ...
> 

> 
> This might explain the NULL rx_stats pointer, but why do there exist
> two distinct vlan_dev_info(dev)? (unless in one case dev would be
> the physical network device and in the other case it would be vlan device?
> that is lan versus lan.658 in my case...)
> 


Ok, I believe I found the problem :)

Please try following patch, if it works I'll submit with appropriate Changelog and signatures

Thanks


diff --git a/net/8021q/vlan_dev.c b/net/8021q/vlan_dev.c
index b788978..c1b92ca 100644
--- a/net/8021q/vlan_dev.c
+++ b/net/8021q/vlan_dev.c
@@ -163,7 +163,7 @@ int vlan_skb_recv(struct sk_buff *skb, struct net_device *dev,
 		goto err_unlock;
 	}
 
-	rx_stats = per_cpu_ptr(vlan_dev_info(dev)->vlan_rx_stats,
+	rx_stats = per_cpu_ptr(vlan_dev_info(skb->dev)->vlan_rx_stats,
 			       smp_processor_id());
 	rx_stats->rx_packets++;
 	rx_stats->rx_bytes += skb->len;

^ permalink raw reply related

* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Américo Wang @ 2010-01-24 16:25 UTC (permalink / raw)
  To: Bruno Prémont; +Cc: Eric Dumazet, David S. Miller, netdev, linux-kernel
In-Reply-To: <20100124162549.2b39b222@neptune.home>

On Sun, Jan 24, 2010 at 04:25:49PM +0100, Bruno Prémont wrote:
>On Sun, 24 January 2010 Eric Dumazet <eric.dumazet@gmail.com> wrote:
>> Le 23/01/2010 22:31, Bruno Prémont a écrit :
>> >> Above part of code did change between 2.6.32 and 2.6.33-rc5 with
>> >> commit 9793241fe92f7d9303fb221e43fc598eb065f267 (vlan: Precise RX
>> >> stats accounting)
>> >> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=9793241fe92f7d9303fb221e43fc598eb065f267
>> > 
>> > Reverting just that commit gets the system running correctly.
>> > 
>> > Bruno
>> 
>> I have no idea how this patch can break vlan networking.
>> 
>> Your disassembly and .config seems to show your machine is not SMP
>
>Exact
>
>> Maybe something is broken on UP and alloc_percpu() ?
>
>Apparently not, see below and previous mail
>
>> Could you add a debug in vlan_dev_init()
>
>In addition to previous mail, I'm also dumping the result of
>vlan_dev_info(dev) shows that the returned pointer is not the same
>during vlan_dev_init() and vlan_skb_recv() ...
>
>diff --git a/net/8021q/vlan_dev.c b/net/8021q/vlan_dev.c
>index b788978..f370ce1 100644
>--- a/net/8021q/vlan_dev.c
>+++ b/net/8021q/vlan_dev.c
>@@ -165,8 +165,11 @@ int vlan_skb_recv(struct sk_buff *skb, struct net_device *dev,
> 
>        rx_stats = per_cpu_ptr(vlan_dev_info(dev)->vlan_rx_stats,
>                               smp_processor_id());


I am thinking if vlan_dev_info(dev) here should be
vlan_dev_info(skb->dev)...



>-       rx_stats->rx_packets++;
>-       rx_stats->rx_bytes += skb->len;
>+       if (rx_stats) {
>+               rx_stats->rx_packets++;
>+               rx_stats->rx_bytes += skb->len;
>+       } else
>+               pr_err("vlan_skb_recv() %p->rx_stats=%p -> %p\n", vlan_dev_info(dev), vlan_dev_info(dev)->vlan_rx_stats, rx_stats);
> 
>        skb_pull_rcsum(skb, VLAN_HLEN);
> 
>@@ -738,6 +741,7 @@ static int vlan_dev_init(struct net_device *dev)
>        vlan_dev_info(dev)->vlan_rx_stats = alloc_percpu(struct vlan_rx_stats);
>        if (!vlan_dev_info(dev)->vlan_rx_stats)
>                return -ENOMEM;
>+       pr_err("vlan_dev_init() %p->rx_stats=%p\n", vlan_dev_info(dev), vlan_dev_info(dev)->vlan_rx_stats);
> 
>        return 0;
> }
>
>This slightly adjusted change produces the following output:
>...
>[ 1192.257978] ADDRCONF(NETDEV_UP): lan: link is not ready
>[ 1192.399059] 802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
>[ 1192.399063] All bugs added by David S. Miller <davem@redhat.com>
>[ 1192.404475] vlan_dev_init() da4ff360->rx_stats=dbd5a340
>                               ^^^^^^^^
>[ 1196.000225] b44: lan: Link is up at 100 Mbps, full duplex.
>[ 1196.000234] b44: lan: Flow control is off for TX and off for RX.
>[ 1196.000379] ADDRCONF(NETDEV_CHANGE): lan: link becomes ready
>[ 1203.160226] lan.658: no IPv6 routers present
>[ 1212.760561] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
>                               ^^^^^^^^
>[ 1212.794961] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
>[ 1219.247018] svc: failed to register lockdv1 RPC service (errno 97).
>[ 1219.249919] mount.nfs used greatest stack depth: 1008 bytes left
>[ 1221.388602] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
>[ 1221.388690] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
>[ 1278.793350] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
>[ 1283.750363] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
>...
>
>This might explain the NULL rx_stats pointer, but why do there exist
>two distinct vlan_dev_info(dev)? (unless in one case dev would be
>the physical network device and in the other case it would be vlan device?
>that is lan versus lan.658 in my case...)
>
>Thanks,
>Bruno
>--
>To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>the body of a message to majordomo@vger.kernel.org
>More majordomo info at  http://vger.kernel.org/majordomo-info.html
>Please read the FAQ at  http://www.tux.org/lkml/

-- 
Live like a child, think like the god.
 

^ permalink raw reply

* [PATCH] netns xfrm: deal with dst entries in netns
From: Alexey Dobriyan @ 2010-01-24 15:40 UTC (permalink / raw)
  To: davem; +Cc: herbert, netdev

GC is non-existent in netns, so after you hit GC threshold, no new
dst entries will be created until someone triggers cleanup in init_net.

Make xfrm4_dst_ops and xfrm6_dst_ops per-netns.
This is not done in a generic way, because it woule waste
(AF_MAX - 2) * sizeof(struct dst_ops) bytes per-netns.

Reorder GC threshold initialization so it'd be done before registering
XFRM policies.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
---

 include/net/netns/xfrm.h |    6 ++++
 net/ipv4/xfrm4_policy.c  |   14 ++++++-----
 net/ipv6/xfrm6_policy.c  |   25 +++++++++++--------
 net/xfrm/xfrm_policy.c   |   59 ++++++++++++++++++++++++++++++++++++++++++++---
 4 files changed, 84 insertions(+), 20 deletions(-)

--- a/include/net/netns/xfrm.h
+++ b/include/net/netns/xfrm.h
@@ -5,6 +5,7 @@
 #include <linux/wait.h>
 #include <linux/workqueue.h>
 #include <linux/xfrm.h>
+#include <net/dst_ops.h>
 
 struct ctl_table_header;
 
@@ -42,6 +43,11 @@ struct netns_xfrm {
 	unsigned int		policy_count[XFRM_POLICY_MAX * 2];
 	struct work_struct	policy_hash_work;
 
+	struct dst_ops		xfrm4_dst_ops;
+#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
+	struct dst_ops		xfrm6_dst_ops;
+#endif
+
 	struct sock		*nlsk;
 	struct sock		*nlsk_stash;
 
--- a/net/ipv4/xfrm4_policy.c
+++ b/net/ipv4/xfrm4_policy.c
@@ -15,7 +15,6 @@
 #include <net/xfrm.h>
 #include <net/ip.h>
 
-static struct dst_ops xfrm4_dst_ops;
 static struct xfrm_policy_afinfo xfrm4_policy_afinfo;
 
 static struct dst_entry *xfrm4_dst_lookup(struct net *net, int tos,
@@ -190,8 +189,10 @@ _decode_session4(struct sk_buff *skb, struct flowi *fl, int reverse)
 
 static inline int xfrm4_garbage_collect(struct dst_ops *ops)
 {
-	xfrm4_policy_afinfo.garbage_collect(&init_net);
-	return (atomic_read(&xfrm4_dst_ops.entries) > xfrm4_dst_ops.gc_thresh*2);
+	struct net *net = container_of(ops, struct net, xfrm.xfrm4_dst_ops);
+
+	xfrm4_policy_afinfo.garbage_collect(net);
+	return (atomic_read(&ops->entries) > ops->gc_thresh * 2);
 }
 
 static void xfrm4_update_pmtu(struct dst_entry *dst, u32 mtu)
@@ -268,7 +269,7 @@ static struct xfrm_policy_afinfo xfrm4_policy_afinfo = {
 static struct ctl_table xfrm4_policy_table[] = {
 	{
 		.procname       = "xfrm4_gc_thresh",
-		.data           = &xfrm4_dst_ops.gc_thresh,
+		.data           = &init_net.xfrm.xfrm4_dst_ops.gc_thresh,
 		.maxlen         = sizeof(int),
 		.mode           = 0644,
 		.proc_handler   = proc_dointvec,
@@ -295,8 +296,6 @@ static void __exit xfrm4_policy_fini(void)
 
 void __init xfrm4_init(int rt_max_size)
 {
-	xfrm4_state_init();
-	xfrm4_policy_init();
 	/*
 	 * Select a default value for the gc_thresh based on the main route
 	 * table hash size.  It seems to me the worst case scenario is when
@@ -308,6 +307,9 @@ void __init xfrm4_init(int rt_max_size)
 	 * and start cleaning when were 1/2 full
 	 */
 	xfrm4_dst_ops.gc_thresh = rt_max_size/2;
+
+	xfrm4_state_init();
+	xfrm4_policy_init();
 #ifdef CONFIG_SYSCTL
 	sysctl_hdr = register_net_sysctl_table(&init_net, net_ipv4_ctl_path,
 						xfrm4_policy_table);
--- a/net/ipv6/xfrm6_policy.c
+++ b/net/ipv6/xfrm6_policy.c
@@ -24,7 +24,6 @@
 #include <net/mip6.h>
 #endif
 
-static struct dst_ops xfrm6_dst_ops;
 static struct xfrm_policy_afinfo xfrm6_policy_afinfo;
 
 static struct dst_entry *xfrm6_dst_lookup(struct net *net, int tos,
@@ -224,8 +223,10 @@ _decode_session6(struct sk_buff *skb, struct flowi *fl, int reverse)
 
 static inline int xfrm6_garbage_collect(struct dst_ops *ops)
 {
-	xfrm6_policy_afinfo.garbage_collect(&init_net);
-	return (atomic_read(&xfrm6_dst_ops.entries) > xfrm6_dst_ops.gc_thresh*2);
+	struct net *net = container_of(ops, struct net, xfrm.xfrm6_dst_ops);
+
+	xfrm6_policy_afinfo.garbage_collect(net);
+	return (atomic_read(&ops->entries) > ops->gc_thresh * 2);
 }
 
 static void xfrm6_update_pmtu(struct dst_entry *dst, u32 mtu)
@@ -310,7 +311,7 @@ static void xfrm6_policy_fini(void)
 static struct ctl_table xfrm6_policy_table[] = {
 	{
 		.procname       = "xfrm6_gc_thresh",
-		.data	   	= &xfrm6_dst_ops.gc_thresh,
+		.data	   	= &init_net.xfrm.xfrm6_dst_ops.gc_thresh,
 		.maxlen	 	= sizeof(int),
 		.mode	   	= 0644,
 		.proc_handler   = proc_dointvec,
@@ -326,13 +327,6 @@ int __init xfrm6_init(void)
 	int ret;
 	unsigned int gc_thresh;
 
-	ret = xfrm6_policy_init();
-	if (ret)
-		goto out;
-
-	ret = xfrm6_state_init();
-	if (ret)
-		goto out_policy;
 	/*
 	 * We need a good default value for the xfrm6 gc threshold.
 	 * In ipv4 we set it to the route hash table size * 8, which
@@ -346,6 +340,15 @@ int __init xfrm6_init(void)
 	 */
 	gc_thresh = FIB6_TABLE_HASHSZ * 8;
 	xfrm6_dst_ops.gc_thresh = (gc_thresh < 1024) ? 1024 : gc_thresh;
+
+	ret = xfrm6_policy_init();
+	if (ret)
+		goto out;
+
+	ret = xfrm6_state_init();
+	if (ret)
+		goto out_policy;
+
 #ifdef CONFIG_SYSCTL
 	sysctl_hdr = register_net_sysctl_table(&init_net, net_ipv6_ctl_path,
 						xfrm6_policy_table);
--- a/net/xfrm/xfrm_policy.c
+++ b/net/xfrm/xfrm_policy.c
@@ -1309,15 +1309,28 @@ static inline int xfrm_get_tos(struct flowi *fl, int family)
 	return tos;
 }
 
-static inline struct xfrm_dst *xfrm_alloc_dst(int family)
+static inline struct xfrm_dst *xfrm_alloc_dst(struct net *net, int family)
 {
 	struct xfrm_policy_afinfo *afinfo = xfrm_policy_get_afinfo(family);
+	struct dst_ops *dst_ops;
 	struct xfrm_dst *xdst;
 
 	if (!afinfo)
 		return ERR_PTR(-EINVAL);
 
-	xdst = dst_alloc(afinfo->dst_ops) ?: ERR_PTR(-ENOBUFS);
+	switch (family) {
+	case AF_INET:
+		dst_ops = &net->xfrm.xfrm4_dst_ops;
+		break;
+#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
+	case AF_INET6:
+		dst_ops = &net->xfrm.xfrm6_dst_ops;
+		break;
+#endif
+	default:
+		BUG();
+	}
+	xdst = dst_alloc(dst_ops) ?: ERR_PTR(-ENOBUFS);
 
 	xfrm_policy_put_afinfo(afinfo);
 
@@ -1366,6 +1379,7 @@ static struct dst_entry *xfrm_bundle_create(struct xfrm_policy *policy,
 					    struct flowi *fl,
 					    struct dst_entry *dst)
 {
+	struct net *net = xp_net(policy);
 	unsigned long now = jiffies;
 	struct net_device *dev;
 	struct dst_entry *dst_prev = NULL;
@@ -1389,7 +1403,7 @@ static struct dst_entry *xfrm_bundle_create(struct xfrm_policy *policy,
 	dst_hold(dst);
 
 	for (; i < nx; i++) {
-		struct xfrm_dst *xdst = xfrm_alloc_dst(family);
+		struct xfrm_dst *xdst = xfrm_alloc_dst(net, family);
 		struct dst_entry *dst1 = &xdst->u.dst;
 
 		err = PTR_ERR(xdst);
@@ -2279,6 +2293,7 @@ EXPORT_SYMBOL(xfrm_bundle_ok);
 
 int xfrm_policy_register_afinfo(struct xfrm_policy_afinfo *afinfo)
 {
+	struct net *net;
 	int err = 0;
 	if (unlikely(afinfo == NULL))
 		return -EINVAL;
@@ -2302,6 +2317,27 @@ int xfrm_policy_register_afinfo(struct xfrm_policy_afinfo *afinfo)
 		xfrm_policy_afinfo[afinfo->family] = afinfo;
 	}
 	write_unlock_bh(&xfrm_policy_afinfo_lock);
+
+	rtnl_lock();
+	for_each_net(net) {
+		struct dst_ops *xfrm_dst_ops;
+
+		switch (afinfo->family) {
+		case AF_INET:
+			xfrm_dst_ops = &net->xfrm.xfrm4_dst_ops;
+			break;
+#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
+		case AF_INET6:
+			xfrm_dst_ops = &net->xfrm.xfrm6_dst_ops;
+			break;
+#endif
+		default:
+			BUG();
+		}
+		*xfrm_dst_ops = *afinfo->dst_ops;
+	}
+	rtnl_unlock();
+
 	return err;
 }
 EXPORT_SYMBOL(xfrm_policy_register_afinfo);
@@ -2332,6 +2368,22 @@ int xfrm_policy_unregister_afinfo(struct xfrm_policy_afinfo *afinfo)
 }
 EXPORT_SYMBOL(xfrm_policy_unregister_afinfo);
 
+static void __net_init xfrm_dst_ops_init(struct net *net)
+{
+	struct xfrm_policy_afinfo *afinfo;
+
+	read_lock_bh(&xfrm_policy_afinfo_lock);
+	afinfo = xfrm_policy_afinfo[AF_INET];
+	if (afinfo)
+		net->xfrm.xfrm4_dst_ops = *afinfo->dst_ops;
+#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
+	afinfo = xfrm_policy_afinfo[AF_INET6];
+	if (afinfo)
+		net->xfrm.xfrm6_dst_ops = *afinfo->dst_ops;
+#endif
+	read_unlock_bh(&xfrm_policy_afinfo_lock);
+}
+
 static struct xfrm_policy_afinfo *xfrm_policy_get_afinfo(unsigned short family)
 {
 	struct xfrm_policy_afinfo *afinfo;
@@ -2494,6 +2546,7 @@ static int __net_init xfrm_net_init(struct net *net)
 	rv = xfrm_policy_init(net);
 	if (rv < 0)
 		goto out_policy;
+	xfrm_dst_ops_init(net);
 	rv = xfrm_sysctl_init(net);
 	if (rv < 0)
 		goto out_sysctl;

^ permalink raw reply

* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Bruno Prémont @ 2010-01-24 15:25 UTC (permalink / raw)
  To: Eric Dumazet; +Cc: David S. Miller, netdev, linux-kernel
In-Reply-To: <20100124160228.366f4e72@neptune.home>

On Sun, 24 January 2010 Eric Dumazet <eric.dumazet@gmail.com> wrote:
> Le 23/01/2010 22:31, Bruno Prémont a écrit :
> >> Above part of code did change between 2.6.32 and 2.6.33-rc5 with
> >> commit 9793241fe92f7d9303fb221e43fc598eb065f267 (vlan: Precise RX
> >> stats accounting)
> >> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=9793241fe92f7d9303fb221e43fc598eb065f267
> > 
> > Reverting just that commit gets the system running correctly.
> > 
> > Bruno
> 
> I have no idea how this patch can break vlan networking.
> 
> Your disassembly and .config seems to show your machine is not SMP

Exact

> Maybe something is broken on UP and alloc_percpu() ?

Apparently not, see below and previous mail

> Could you add a debug in vlan_dev_init()

In addition to previous mail, I'm also dumping the result of
vlan_dev_info(dev) shows that the returned pointer is not the same
during vlan_dev_init() and vlan_skb_recv() ...

diff --git a/net/8021q/vlan_dev.c b/net/8021q/vlan_dev.c
index b788978..f370ce1 100644
--- a/net/8021q/vlan_dev.c
+++ b/net/8021q/vlan_dev.c
@@ -165,8 +165,11 @@ int vlan_skb_recv(struct sk_buff *skb, struct net_device *dev,
 
        rx_stats = per_cpu_ptr(vlan_dev_info(dev)->vlan_rx_stats,
                               smp_processor_id());
-       rx_stats->rx_packets++;
-       rx_stats->rx_bytes += skb->len;
+       if (rx_stats) {
+               rx_stats->rx_packets++;
+               rx_stats->rx_bytes += skb->len;
+       } else
+               pr_err("vlan_skb_recv() %p->rx_stats=%p -> %p\n", vlan_dev_info(dev), vlan_dev_info(dev)->vlan_rx_stats, rx_stats);
 
        skb_pull_rcsum(skb, VLAN_HLEN);
 
@@ -738,6 +741,7 @@ static int vlan_dev_init(struct net_device *dev)
        vlan_dev_info(dev)->vlan_rx_stats = alloc_percpu(struct vlan_rx_stats);
        if (!vlan_dev_info(dev)->vlan_rx_stats)
                return -ENOMEM;
+       pr_err("vlan_dev_init() %p->rx_stats=%p\n", vlan_dev_info(dev), vlan_dev_info(dev)->vlan_rx_stats);
 
        return 0;
 }

This slightly adjusted change produces the following output:
...
[ 1192.257978] ADDRCONF(NETDEV_UP): lan: link is not ready
[ 1192.399059] 802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
[ 1192.399063] All bugs added by David S. Miller <davem@redhat.com>
[ 1192.404475] vlan_dev_init() da4ff360->rx_stats=dbd5a340
                               ^^^^^^^^
[ 1196.000225] b44: lan: Link is up at 100 Mbps, full duplex.
[ 1196.000234] b44: lan: Flow control is off for TX and off for RX.
[ 1196.000379] ADDRCONF(NETDEV_CHANGE): lan: link becomes ready
[ 1203.160226] lan.658: no IPv6 routers present
[ 1212.760561] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
                               ^^^^^^^^
[ 1212.794961] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
[ 1219.247018] svc: failed to register lockdv1 RPC service (errno 97).
[ 1219.249919] mount.nfs used greatest stack depth: 1008 bytes left
[ 1221.388602] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
[ 1221.388690] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
[ 1278.793350] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
[ 1283.750363] vlan_skb_recv() ddbb8b60->rx_stats=(null) -> (null)
...

This might explain the NULL rx_stats pointer, but why do there exist
two distinct vlan_dev_info(dev)? (unless in one case dev would be
the physical network device and in the other case it would be vlan device?
that is lan versus lan.658 in my case...)

Thanks,
Bruno

^ permalink raw reply related

* bridge: mac addresses question (for bluetooth pan-nap)
From: Metuki Sabhe @ 2010-01-24 15:18 UTC (permalink / raw)
  To: netdev-u79uwXL29TY76Z2rM5mHXA
  Cc: bridge-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA,
	linux-bluetooth-u79uwXL29TY76Z2rM5mHXA

Hi,

I have a single bridge with up to 7 virtual TAP ports,
which are being added and removed dynamically.

Can I use the same MAC address for all ports and for the bridge ?
(I don't use STP as the topology is very very simple).

This is needed to allow macaddress header compression of BNEP...
(i plan to use the radio BDADDR as the MAC address for all TAP ports
and for the bridge)

thank you,
sabhe

^ permalink raw reply

* Re: linux bridge problem
From: Metuki Sabhe @ 2010-01-24 15:11 UTC (permalink / raw)
  To: Mark Smith; +Cc: bridge, netdev
In-Reply-To: <20100124092333.230aa8eb@opy.nosense.org>

Hi Mark,

On Sun, Jan 24, 2010 at 12:53 AM, Mark Smith
<lk-netdev@lk-netdev.nosense.org> wrote:
> brctl setfd br0 0

yep, that was it! thanks! unfortunately for me i found the culprit
soon after I send the mail. should have sent earlier to save me hours
of debugging :)

thank you,
sabhe

^ permalink raw reply

* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Bruno Prémont @ 2010-01-24 15:02 UTC (permalink / raw)
  To: Eric Dumazet; +Cc: David S. Miller, netdev, linux-kernel
In-Reply-To: <4B5C4E5E.2010507@gmail.com>

On Sun, 24 January 2010 Eric Dumazet <eric.dumazet@gmail.com> wrote:
> Le 23/01/2010 22:31, Bruno Prémont a écrit :
> >> Above part of code did change between 2.6.32 and 2.6.33-rc5 with
> >> commit 9793241fe92f7d9303fb221e43fc598eb065f267 (vlan: Precise RX
> >> stats accounting)
> >> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=9793241fe92f7d9303fb221e43fc598eb065f267
> > 
> > Reverting just that commit gets the system running correctly.
> > 
> > Bruno
> 
> I have no idea how this patch can break vlan networking.
> 
> Your disassembly and .config seems to show your machine is not SMP
> 
> Maybe something is broken on UP and alloc_percpu() ?
> 
> Could you add a debug in vlan_dev_init()
> 
> 
>  	vlan_dev_info(dev)->vlan_rx_stats = alloc_percpu(struct
> vlan_rx_stats); if (!vlan_dev_info(dev)->vlan_rx_stats)
>  	return -ENOMEM;
> +	pr_err("vlan_dev_init() rx_stats=%p\n",
> vlan_dev_info(dev)->vlan_rx_stats);
> 
> 
> This make sure vlan_dev_init() is called and percpu allocation is
> properly done.
> 
> Thanks

Readding your "precise RX stats" commit with following additional changes I get
(first hunk to avoid crash):

diff --git a/net/8021q/vlan_dev.c b/net/8021q/vlan_dev.c
index b788978..9216a98 100644
--- a/net/8021q/vlan_dev.c
+++ b/net/8021q/vlan_dev.c
@@ -165,8 +165,11 @@ int vlan_skb_recv(struct sk_buff *skb, struct net_device *dev,
 
        rx_stats = per_cpu_ptr(vlan_dev_info(dev)->vlan_rx_stats,
                               smp_processor_id());
-       rx_stats->rx_packets++;
-       rx_stats->rx_bytes += skb->len;
+       if (rx_stats) {
+               rx_stats->rx_packets++;
+               rx_stats->rx_bytes += skb->len;
+       } else
+               pr_err("vlan_skb_recv() rx_stats=%p -> %p\n",
  vlan_dev_info(dev)->vlan_rx_stats, rx_stats); 
        skb_pull_rcsum(skb, VLAN_HLEN);
 
@@ -738,6 +741,7 @@ static int vlan_dev_init(struct net_device *dev)
        vlan_dev_info(dev)->vlan_rx_stats = alloc_percpu(struct
  vlan_rx_stats); if (!vlan_dev_info(dev)->vlan_rx_stats)
                return -ENOMEM;
+       pr_err("vlan_dev_init() rx_stats=%p\n",
  vlan_dev_info(dev)->vlan_rx_stats); 
        return 0;
 }


...
[   13.877610] Ending clean XFS mount for filesystem: loop0
[   15.795601] Adding 1004020k swap on /dev/sda5.  Priority:-1 extents:1 across:1004020k 
[   16.612143] ADDRCONF(NETDEV_UP): lan: link is not ready
[   16.851846] 802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
[   16.851856] All bugs added by David S. Miller <davem@redhat.com>
[   16.878049] vlan_dev_init() rx_stats=dceae290
[   20.040395] b44: lan: Link is up at 100 Mbps, full duplex.
[   20.040404] b44: lan: Flow control is off for TX and off for RX.
[   20.040535] ADDRCONF(NETDEV_CHANGE): lan: link becomes ready
[   25.019941] RPC: Registered udp transport module.
[   25.019950] RPC: Registered tcp transport module.
[   25.019956] RPC: Registered tcp NFSv4.1 backchannel transport module.
[   25.382400] svc: failed to register lockdv1 RPC service (errno 97).
[   25.385278] mount.nfs used greatest stack depth: 1012 bytes left
[   25.872973] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[   26.740561] vlan_skb_recv() rx_stats=(null) -> (null)
[   26.775071] vlan_skb_recv() rx_stats=(null) -> (null)
[   27.050223] lan.658: no IPv6 routers present
[   58.357052] vlan_skb_recv() rx_stats=(null) -> (null)
[   63.350334] vlan_skb_recv() rx_stats=(null) -> (null)
[   91.767589] vlan_skb_recv() rx_stats=(null) -> (null)
[   91.932344] vlan_skb_recv() rx_stats=(null) -> (null)
[   91.933053] vlan_skb_recv() rx_stats=(null) -> (null)
[   91.998628] vlan_skb_recv() rx_stats=(null) -> (null)
[   92.002752] vlan_skb_recv() rx_stats=(null) -> (null)
[   92.007918] vlan_skb_recv() rx_stats=(null) -> (null)
[   92.009644] vlan_skb_recv() rx_stats=(null) -> (null)
[   92.016789] vlan_skb_recv() rx_stats=(null) -> (null)
[   92.018520] vlan_skb_recv() rx_stats=(null) -> (null)
[   92.041737] vlan_skb_recv() rx_stats=(null) -> (null)
...

So during vlan_dev_init() rx_stats is properly initialized, but when
packets reach the vlan dev later on exactly that same pointer is NULL...

So question is, who did reset vlan_dev_info(dev)->vlan_rx_stats to NULL?

Thanks,
Bruno

^ permalink raw reply related

* Re: [net-next-2.6 PATCH 2/3] fs_enet: Add support for MPC512x to fs_enet driver
From: Wolfgang Grandegger @ 2010-01-24 14:40 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: linuxppc-dev, David Miller, wd, dzu, netdev, linuxppc-dev, agust,
	kosmo
In-Reply-To: <201001231023.14372.arnd@arndb.de>

Arnd Bergmann wrote:
> On Thursday 21 January 2010, Wolfgang Grandegger wrote:
>> The major problem that Anatolij tries to solve are the different
>> register layouts of the supported SOCs, MPC52xx and MPC8xx. They use the
>> same registers but at different offsets. Therefore we cannot handle
>> this with a single "fec_t" struct to allow building a single kernel
>> image. Instead it's handled by filling a table with register addresses:
>>
>>         if (of_device_is_compatible(ofdev->node, "fsl,mpc5121-fec")) {
>>                 fep->fec.fec_id = FS_ENET_MPC5121_FEC;
>>                 fec_reg_mpc5121(ievent);
>>                 fec_reg_mpc5121(imask);
>>                 ...
>>         } else {
>>                 fec_reg_mpc8xx(ievent);
>>                 fec_reg_mpc8xx(imask);
>>                 ...
>>         }
>>
>> Do you see a more clever solution to this problem? Nevertheless, the
>> code could be improved by using "offsetof", I think.
> 
> Is there any chance of building a kernel that runs on both mpc8xx and
> mpc5121? AFAIK, the 5121 is built on a 6xx core which is fundamentally
> incompatible with 8xx due to different memory management etc.
> 
> Since this makes it all a compile-time decision, it should be solvable
> with a very small number of carefully placed #ifdef in the header files
> an no runtime detection at all.
> 
> Obviously this approach would not work for drivers that want to be portable
> across different register layouts on otherwise compatible platforms.

You are probably right and your proposal would likely result in more
transparent (less ugly) code. There has been some discussion about
unifying FEC drivers when the patches (with the same subject) have been
submitted for the first time in May last year, but it was not about 512x
and 8xx, IIRC.

Wolfgang.





^ permalink raw reply

* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Eric Dumazet @ 2010-01-24 13:42 UTC (permalink / raw)
  To: Bruno Prémont; +Cc: David S. Miller, netdev, linux-kernel
In-Reply-To: <20100123223132.0e62d8cb@neptune.home>

Le 23/01/2010 22:31, Bruno Prémont a écrit :
>> Above part of code did change between 2.6.32 and 2.6.33-rc5 with
>> commit 9793241fe92f7d9303fb221e43fc598eb065f267 (vlan: Precise RX
>> stats accounting)
>> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=9793241fe92f7d9303fb221e43fc598eb065f267
> 
> Reverting just that commit gets the system running correctly.
> 
> Bruno

I have no idea how this patch can break vlan networking.

Your disassembly and .config seems to show your machine is not SMP

Maybe something is broken on UP and alloc_percpu() ?

Could you add a debug in vlan_dev_init()


 	vlan_dev_info(dev)->vlan_rx_stats = alloc_percpu(struct vlan_rx_stats);
	if (!vlan_dev_info(dev)->vlan_rx_stats)
 	return -ENOMEM;
+	pr_err("vlan_dev_init() rx_stats=%p\n", vlan_dev_info(dev)->vlan_rx_stats);


This make sure vlan_dev_init() is called and percpu allocation is properly done.

Thanks

^ permalink raw reply

* [PATCH net-next-2.6] net: use helpers to access uc list
From: Jiri Pirko @ 2010-01-24 10:42 UTC (permalink / raw)
  To: netdev; +Cc: davem

Instead of accessing netdev->uc.count and netdev->uc.list by hand in each
driver, this patch converts it to use two macros netdev_uc_count and
netdev_for_each_uc_addr and makes the code nicer. Will post similar helpers for
mc list soon.

Signed-off-by: Jiri Pirko <jpirko@redhat.com>

diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c
index d83512d..aa46cc6 100644
--- a/drivers/net/bnx2.c
+++ b/drivers/net/bnx2.c
@@ -48,7 +48,6 @@
 #include <linux/cache.h>
 #include <linux/firmware.h>
 #include <linux/log2.h>
-#include <linux/list.h>
 
 #if defined(CONFIG_CNIC) || defined(CONFIG_CNIC_MODULE)
 #define BCM_CNIC 1
@@ -3520,7 +3519,7 @@ bnx2_set_rx_mode(struct net_device *dev)
 {
 	struct bnx2 *bp = netdev_priv(dev);
 	u32 rx_mode, sort_mode;
-	struct netdev_hw_addr *ha;
+	unsigned char *ha;
 	int i;
 
 	if (!netif_running(dev))
@@ -3579,15 +3578,15 @@ bnx2_set_rx_mode(struct net_device *dev)
 		sort_mode |= BNX2_RPM_SORT_USER0_MC_HSH_EN;
 	}
 
-	if (dev->uc.count > BNX2_MAX_UNICAST_ADDRESSES) {
+	if (netdev_uc_count(dev) > BNX2_MAX_UNICAST_ADDRESSES) {
 		rx_mode |= BNX2_EMAC_RX_MODE_PROMISCUOUS;
 		sort_mode |= BNX2_RPM_SORT_USER0_PROM_EN |
 			     BNX2_RPM_SORT_USER0_PROM_VLAN;
 	} else if (!(dev->flags & IFF_PROMISC)) {
 		/* Add all entries into to the match filter list */
 		i = 0;
-		list_for_each_entry(ha, &dev->uc.list, list) {
-			bnx2_set_mac_addr(bp, ha->addr,
+		netdev_for_each_uc_addr(ha, dev) {
+			bnx2_set_mac_addr(bp, ha,
 					  i + BNX2_START_UNICAST_ADDRESS_INDEX);
 			sort_mode |= (1 <<
 				      (i + BNX2_START_UNICAST_ADDRESS_INDEX));
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
index 87f575c..caddbd6 100644
--- a/drivers/net/e1000/e1000_main.c
+++ b/drivers/net/e1000/e1000_main.c
@@ -2108,7 +2108,7 @@ static void e1000_set_rx_mode(struct net_device *netdev)
 {
 	struct e1000_adapter *adapter = netdev_priv(netdev);
 	struct e1000_hw *hw = &adapter->hw;
-	struct netdev_hw_addr *ha;
+	unsigned char *ha;
 	bool use_uc = false;
 	struct dev_addr_list *mc_ptr;
 	u32 rctl;
@@ -2139,7 +2139,7 @@ static void e1000_set_rx_mode(struct net_device *netdev)
 			rctl |= E1000_RCTL_VFE;
 	}
 
-	if (netdev->uc.count > rar_entries - 1) {
+	if (netdev_uc_count(netdev) > rar_entries - 1) {
 		rctl |= E1000_RCTL_UPE;
 	} else if (!(netdev->flags & IFF_PROMISC)) {
 		rctl &= ~E1000_RCTL_UPE;
@@ -2162,10 +2162,10 @@ static void e1000_set_rx_mode(struct net_device *netdev)
 	 */
 	i = 1;
 	if (use_uc)
-		list_for_each_entry(ha, &netdev->uc.list, list) {
+		netdev_for_each_uc_addr(ha, netdev) {
 			if (i == rar_entries)
 				break;
-			e1000_rar_set(hw, ha->addr, i++);
+			e1000_rar_set(hw, ha, i++);
 		}
 
 	WARN_ON(i == rar_entries);
diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index d967949..c29283c 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -2905,17 +2905,16 @@ static int igb_write_uc_addr_list(struct net_device *netdev)
 	int count = 0;
 
 	/* return ENOMEM indicating insufficient memory for addresses */
-	if (netdev->uc.count > rar_entries)
+	if (netdev_uc_count(netdev) > rar_entries)
 		return -ENOMEM;
 
-	if (netdev->uc.count && rar_entries) {
-		struct netdev_hw_addr *ha;
-		list_for_each_entry(ha, &netdev->uc.list, list) {
+	if (netdev_uc_count(netdev) && rar_entries) {
+		unsigned char *ha;
+
+		netdev_for_each_uc_addr(ha, netdev) {
 			if (!rar_entries)
 				break;
-			igb_rar_set_qsel(adapter, ha->addr,
-			                 rar_entries--,
-			                 vfn);
+			igb_rar_set_qsel(adapter, ha, rar_entries--, vfn);
 			count++;
 		}
 	}
diff --git a/drivers/net/ixgbe/ixgbe_common.c b/drivers/net/ixgbe/ixgbe_common.c
index 276c2aa..05e7d5c 100644
--- a/drivers/net/ixgbe/ixgbe_common.c
+++ b/drivers/net/ixgbe/ixgbe_common.c
@@ -28,7 +28,6 @@
 #include <linux/pci.h>
 #include <linux/delay.h>
 #include <linux/sched.h>
-#include <linux/list.h>
 #include <linux/netdevice.h>
 
 #include "ixgbe.h"
@@ -1347,7 +1346,7 @@ static void ixgbe_add_uc_addr(struct ixgbe_hw *hw, u8 *addr, u32 vmdq)
 /**
  *  ixgbe_update_uc_addr_list_generic - Updates MAC list of secondary addresses
  *  @hw: pointer to hardware structure
- *  @uc_list: the list of new addresses
+ *  @netdev: pointer to net device structure
  *
  *  The given list replaces any existing list.  Clears the secondary addrs from
  *  receive address registers.  Uses unused receive address registers for the
@@ -1357,13 +1356,13 @@ static void ixgbe_add_uc_addr(struct ixgbe_hw *hw, u8 *addr, u32 vmdq)
  *  manually putting the device into promiscuous mode.
  **/
 s32 ixgbe_update_uc_addr_list_generic(struct ixgbe_hw *hw,
-				      struct list_head *uc_list)
+				      struct net_device *netdev)
 {
 	u32 i;
 	u32 old_promisc_setting = hw->addr_ctrl.overflow_promisc;
 	u32 uc_addr_in_use;
 	u32 fctrl;
-	struct netdev_hw_addr *ha;
+	unsigned char *ha;
 
 	/*
 	 * Clear accounting of old secondary address list,
@@ -1381,9 +1380,9 @@ s32 ixgbe_update_uc_addr_list_generic(struct ixgbe_hw *hw,
 	}
 
 	/* Add the new addresses */
-	list_for_each_entry(ha, uc_list, list) {
+	netdev_for_each_uc_addr(ha, netdev) {
 		hw_dbg(hw, " Adding the secondary addresses:\n");
-		ixgbe_add_uc_addr(hw, ha->addr, 0);
+		ixgbe_add_uc_addr(hw, ha, 0);
 	}
 
 	if (hw->addr_ctrl.overflow_promisc) {
diff --git a/drivers/net/ixgbe/ixgbe_common.h b/drivers/net/ixgbe/ixgbe_common.h
index dfff0ff..13606d4 100644
--- a/drivers/net/ixgbe/ixgbe_common.h
+++ b/drivers/net/ixgbe/ixgbe_common.h
@@ -60,7 +60,7 @@ s32 ixgbe_update_mc_addr_list_generic(struct ixgbe_hw *hw, u8 *mc_addr_list,
                                       u32 mc_addr_count,
                                       ixgbe_mc_addr_itr func);
 s32 ixgbe_update_uc_addr_list_generic(struct ixgbe_hw *hw,
-				      struct list_head *uc_list);
+				      struct net_device *netdev);
 s32 ixgbe_enable_mc_generic(struct ixgbe_hw *hw);
 s32 ixgbe_disable_mc_generic(struct ixgbe_hw *hw);
 s32 ixgbe_enable_rx_dma_generic(struct ixgbe_hw *hw, u32 regval);
diff --git a/drivers/net/ixgbe/ixgbe_main.c b/drivers/net/ixgbe/ixgbe_main.c
index ee41d33..439645d 100644
--- a/drivers/net/ixgbe/ixgbe_main.c
+++ b/drivers/net/ixgbe/ixgbe_main.c
@@ -2568,7 +2568,7 @@ void ixgbe_set_rx_mode(struct net_device *netdev)
 	IXGBE_WRITE_REG(hw, IXGBE_VLNCTRL, vlnctrl);
 
 	/* reprogram secondary unicast list */
-	hw->mac.ops.update_uc_addr_list(hw, &netdev->uc.list);
+	hw->mac.ops.update_uc_addr_list(hw, netdev);
 
 	/* reprogram multicast list */
 	addr_count = netdev->mc_count;
diff --git a/drivers/net/ixgbe/ixgbe_type.h b/drivers/net/ixgbe/ixgbe_type.h
index b4caa70..0db67c1 100644
--- a/drivers/net/ixgbe/ixgbe_type.h
+++ b/drivers/net/ixgbe/ixgbe_type.h
@@ -30,7 +30,7 @@
 
 #include <linux/types.h>
 #include <linux/mdio.h>
-#include <linux/list.h>
+#include <linux/netdevice.h>
 
 /* Vendor ID */
 #define IXGBE_INTEL_VENDOR_ID   0x8086
@@ -2405,7 +2405,7 @@ struct ixgbe_mac_operations {
 	s32 (*set_vmdq)(struct ixgbe_hw *, u32, u32);
 	s32 (*clear_vmdq)(struct ixgbe_hw *, u32, u32);
 	s32 (*init_rx_addrs)(struct ixgbe_hw *);
-	s32 (*update_uc_addr_list)(struct ixgbe_hw *, struct list_head *);
+	s32 (*update_uc_addr_list)(struct ixgbe_hw *, struct net_device *);
 	s32 (*update_mc_addr_list)(struct ixgbe_hw *, u8 *, u32,
 	                           ixgbe_mc_addr_itr);
 	s32 (*enable_mc)(struct ixgbe_hw *);
diff --git a/drivers/net/mv643xx_eth.c b/drivers/net/mv643xx_eth.c
index af67af5..e2821be 100644
--- a/drivers/net/mv643xx_eth.c
+++ b/drivers/net/mv643xx_eth.c
@@ -55,7 +55,6 @@
 #include <linux/types.h>
 #include <linux/inet_lro.h>
 #include <asm/system.h>
-#include <linux/list.h>
 
 static char mv643xx_eth_driver_name[] = "mv643xx_eth";
 static char mv643xx_eth_driver_version[] = "1.4";
@@ -1690,20 +1689,20 @@ static void uc_addr_set(struct mv643xx_eth_private *mp, unsigned char *addr)
 
 static u32 uc_addr_filter_mask(struct net_device *dev)
 {
-	struct netdev_hw_addr *ha;
+	unsigned char *ha;
 	u32 nibbles;
 
 	if (dev->flags & IFF_PROMISC)
 		return 0;
 
 	nibbles = 1 << (dev->dev_addr[5] & 0x0f);
-	list_for_each_entry(ha, &dev->uc.list, list) {
-		if (memcmp(dev->dev_addr, ha->addr, 5))
+	netdev_for_each_uc_addr(ha, dev) {
+		if (memcmp(dev->dev_addr, ha, 5))
 			return 0;
-		if ((dev->dev_addr[5] ^ ha->addr[5]) & 0xf0)
+		if ((dev->dev_addr[5] ^ ha[5]) & 0xf0)
 			return 0;
 
-		nibbles |= 1 << (ha->addr[5] & 0x0f);
+		nibbles |= 1 << (ha[5] & 0x0f);
 	}
 
 	return nibbles;
diff --git a/drivers/net/niu.c b/drivers/net/niu.c
index 0e260cf..6dcf735 100644
--- a/drivers/net/niu.c
+++ b/drivers/net/niu.c
@@ -6359,7 +6359,7 @@ static void niu_set_rx_mode(struct net_device *dev)
 	struct niu *np = netdev_priv(dev);
 	int i, alt_cnt, err;
 	struct dev_addr_list *addr;
-	struct netdev_hw_addr *ha;
+	unsigned char *ha;
 	unsigned long flags;
 	u16 hash[16] = { 0, };
 
@@ -6372,7 +6372,7 @@ static void niu_set_rx_mode(struct net_device *dev)
 	if ((dev->flags & IFF_ALLMULTI) || (dev->mc_count > 0))
 		np->flags |= NIU_FLAGS_MCAST;
 
-	alt_cnt = dev->uc.count;
+	alt_cnt = netdev_uc_count(dev);
 	if (alt_cnt > niu_num_alt_addr(np)) {
 		alt_cnt = 0;
 		np->flags |= NIU_FLAGS_PROMISC;
@@ -6381,8 +6381,8 @@ static void niu_set_rx_mode(struct net_device *dev)
 	if (alt_cnt) {
 		int index = 0;
 
-		list_for_each_entry(ha, &dev->uc.list, list) {
-			err = niu_set_alt_mac(np, index, ha->addr);
+		netdev_for_each_uc_addr(ha, dev) {
+			err = niu_set_alt_mac(np, index, ha);
 			if (err)
 				printk(KERN_WARNING PFX "%s: Error %d "
 				       "adding alt mac %d\n",
diff --git a/drivers/net/stmmac/dwmac1000_core.c b/drivers/net/stmmac/dwmac1000_core.c
index 928eac0..d66f78b 100644
--- a/drivers/net/stmmac/dwmac1000_core.c
+++ b/drivers/net/stmmac/dwmac1000_core.c
@@ -83,7 +83,7 @@ static void dwmac1000_set_filter(struct net_device *dev)
 	unsigned int value = 0;
 
 	DBG(KERN_INFO "%s: # mcasts %d, # unicast %d\n",
-	    __func__, dev->mc_count, dev->uc.count);
+	    __func__, dev->mc_count, netdev_uc_count(dev));
 
 	if (dev->flags & IFF_PROMISC)
 		value = GMAC_FRAME_FILTER_PR;
@@ -117,17 +117,17 @@ static void dwmac1000_set_filter(struct net_device *dev)
 	}
 
 	/* Handle multiple unicast addresses (perfect filtering)*/
-	if (dev->uc.count > GMAC_MAX_UNICAST_ADDRESSES)
+	if (netdev_uc_count(dev) > GMAC_MAX_UNICAST_ADDRESSES)
 		/* Switch to promiscuous mode is more than 16 addrs
 		   are required */
 		value |= GMAC_FRAME_FILTER_PR;
 	else {
 		int reg = 1;
-		struct netdev_hw_addr *ha;
+		unsigned char *ha;
 
-			list_for_each_entry(ha, &dev->uc.list, list) {
-				dwmac1000_set_umac_addr(ioaddr, ha->addr, reg);
-				reg++;
+		netdev_for_each_uc_addr(ha, dev) {
+			dwmac1000_set_umac_addr(ioaddr, ha, reg);
+			reg++;
 		}
 	}
 
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index c708ecc..20c337f 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers/net/virtio_net.c
@@ -674,7 +674,8 @@ static void virtnet_set_rx_mode(struct net_device *dev)
 	u8 promisc, allmulti;
 	struct virtio_net_ctrl_mac *mac_data;
 	struct dev_addr_list *addr;
-	struct netdev_hw_addr *ha;
+	unsigned char *ha;
+	int uc_count;
 	void *buf;
 	int i;
 
@@ -701,8 +702,9 @@ static void virtnet_set_rx_mode(struct net_device *dev)
 		dev_warn(&dev->dev, "Failed to %sable allmulti mode.\n",
 			 allmulti ? "en" : "dis");
 
+	uc_count = netdev_uc_count(dev);
 	/* MAC filter - use one buffer for both lists */
-	mac_data = buf = kzalloc(((dev->uc.count + dev->mc_count) * ETH_ALEN) +
+	mac_data = buf = kzalloc(((uc_count + dev->mc_count) * ETH_ALEN) +
 				 (2 * sizeof(mac_data->entries)), GFP_ATOMIC);
 	if (!buf) {
 		dev_warn(&dev->dev, "No memory for MAC address buffer\n");
@@ -712,16 +714,16 @@ static void virtnet_set_rx_mode(struct net_device *dev)
 	sg_init_table(sg, 2);
 
 	/* Store the unicast list and count in the front of the buffer */
-	mac_data->entries = dev->uc.count;
+	mac_data->entries = uc_count;
 	i = 0;
-	list_for_each_entry(ha, &dev->uc.list, list)
-		memcpy(&mac_data->macs[i++][0], ha->addr, ETH_ALEN);
+	netdev_for_each_uc_addr(ha, dev)
+		memcpy(&mac_data->macs[i++][0], ha, ETH_ALEN);
 
 	sg_set_buf(&sg[0], mac_data,
-		   sizeof(mac_data->entries) + (dev->uc.count * ETH_ALEN));
+		   sizeof(mac_data->entries) + (uc_count * ETH_ALEN));
 
 	/* multicast list and count fill the end */
-	mac_data = (void *)&mac_data->macs[dev->uc.count][0];
+	mac_data = (void *)&mac_data->macs[uc_count][0];
 
 	mac_data->entries = dev->mc_count;
 	addr = dev->mc_list;
diff --git a/drivers/s390/net/qeth_l2_main.c b/drivers/s390/net/qeth_l2_main.c
index c3258b0..b67f365 100644
--- a/drivers/s390/net/qeth_l2_main.c
+++ b/drivers/s390/net/qeth_l2_main.c
@@ -608,7 +608,7 @@ static void qeth_l2_set_multicast_list(struct net_device *dev)
 {
 	struct qeth_card *card = dev->ml_priv;
 	struct dev_addr_list *dm;
-	struct netdev_hw_addr *ha;
+	unsigned char *ha;
 
 	if (card->info.type == QETH_CARD_TYPE_OSN)
 		return ;
@@ -622,8 +622,8 @@ static void qeth_l2_set_multicast_list(struct net_device *dev)
 	for (dm = dev->mc_list; dm; dm = dm->next)
 		qeth_l2_add_mc(card, dm->da_addr, 0);
 
-	list_for_each_entry(ha, &dev->uc.list, list)
-		qeth_l2_add_mc(card, ha->addr, 1);
+	netdev_for_each_uc_addr(ha, dev)
+		qeth_l2_add_mc(card, ha, 1);
 
 	spin_unlock_bh(&card->mclock);
 	if (!qeth_adp_supported(card, IPA_SETADP_SET_PROMISC_MODE))
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 19aac2b..0d8688d 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -263,6 +263,23 @@ struct netdev_hw_addr_list {
 	int			count;
 };
 
+#define netdev_uc_count(dev) ((dev)->uc.count)
+
+#define netdev_get_list_by_addr(a) \
+	(container_of((void *) a, struct netdev_hw_addr, addr)->list)
+
+#define netdev_get_addr_by_list(l) \
+	(list_entry(l, struct netdev_hw_addr, list)->addr)
+
+#define netdev_for_each_addr(a, head)					\
+	for (a = netdev_get_addr_by_list((head)->next);			\
+	     prefetch(netdev_get_list_by_addr(a).next),			\
+	     &netdev_get_list_by_addr(a) != (head);			\
+	     a = netdev_get_addr_by_list(netdev_get_list_by_addr(a).next))
+
+#define netdev_for_each_uc_addr(a, dev)	\
+	netdev_for_each_addr(a, &dev->uc.list)
+
 struct hh_cache {
 	struct hh_cache *hh_next;	/* Next entry			     */
 	atomic_t	hh_refcnt;	/* number of users                   */
diff --git a/net/core/dev.c b/net/core/dev.c
index 4fad9db..123ffee 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3665,10 +3665,10 @@ void __dev_set_rx_mode(struct net_device *dev)
 		/* Unicast addresses changes may only happen under the rtnl,
 		 * therefore calling __dev_set_promiscuity here is safe.
 		 */
-		if (dev->uc.count > 0 && !dev->uc_promisc) {
+		if (netdev_uc_count(dev) > 0 && !dev->uc_promisc) {
 			__dev_set_promiscuity(dev, 1);
 			dev->uc_promisc = 1;
-		} else if (dev->uc.count == 0 && dev->uc_promisc) {
+		} else if (netdev_uc_count(dev) == 0 && dev->uc_promisc) {
 			__dev_set_promiscuity(dev, -1);
 			dev->uc_promisc = 0;
 		}

^ permalink raw reply related

* Re: [PATCH] netns xfrm: fix "ip xfrm state|policy count" misreport
From: David Miller @ 2010-01-24  7:30 UTC (permalink / raw)
  To: herbert; +Cc: adobriyan, netdev, containers
In-Reply-To: <20100124001252.GA11585@gondor.apana.org.au>

From: Herbert Xu <herbert@gondor.apana.org.au>
Date: Sun, 24 Jan 2010 13:12:52 +1300

> On Sun, Jan 24, 2010 at 01:37:10AM +0200, Alexey Dobriyan wrote:
>> "ip xfrm state|policy count" report SA/SP count from init_net,
>> not from netns of caller process.
>> 
>> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
> 
> Looks good to me.
> 
> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

Applied, thanks.

^ permalink raw reply

* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Américo Wang @ 2010-01-24  7:30 UTC (permalink / raw)
  To: Alexey Dobriyan
  Cc: Américo Wang, Bruno Prémont, Eric Dumazet,
	David S. Miller, netdev, linux-kernel
In-Reply-To: <20100124071728.GA3993@x200>

On Sun, Jan 24, 2010 at 09:17:28AM +0200, Alexey Dobriyan wrote:
>On Sun, Jan 24, 2010 at 03:12:52PM +0800, Américo Wang wrote:
>> On Sat, Jan 23, 2010 at 04:56:57PM +0100, Bruno Prémont wrote:
>> >Today I tried out 2.6.33-rc5 but always got crashing system:
>> >
>> >[   26.390576] BUG: unable to handle kernel NULL pointer dereference at (null)
>> >[   26.396369] IP: [<df856b89>] vlan_skb_recv+0x89/0x280 [8021q]
>> 
>> 
>> What does 'addr2line -e vmlinux 0xdf856b89' say?
>
>EIP is in module, so it will say nothing.

Oh, ok, then '-e net/8021q/vlan_dev.o'.

-- 
Live like a child, think like the god.
 

^ permalink raw reply

* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Alexey Dobriyan @ 2010-01-24  7:17 UTC (permalink / raw)
  To: Américo Wang
  Cc: Bruno Prémont, Eric Dumazet, David S. Miller, netdev,
	linux-kernel
In-Reply-To: <20100124071252.GA11037@hack>

On Sun, Jan 24, 2010 at 03:12:52PM +0800, Américo Wang wrote:
> On Sat, Jan 23, 2010 at 04:56:57PM +0100, Bruno Prémont wrote:
> >Today I tried out 2.6.33-rc5 but always got crashing system:
> >
> >[   26.390576] BUG: unable to handle kernel NULL pointer dereference at (null)
> >[   26.396369] IP: [<df856b89>] vlan_skb_recv+0x89/0x280 [8021q]
> 
> 
> What does 'addr2line -e vmlinux 0xdf856b89' say?

EIP is in module, so it will say nothing.

^ permalink raw reply

* Re: [2.6.33-rc5 regression] NULL pointer dereference in vlan_skb_recv - probably introduced by commit 9793241fe92f7d9303fb221e43fc598eb065f267
From: Américo Wang @ 2010-01-24  7:12 UTC (permalink / raw)
  To: Bruno Prémont; +Cc: Eric Dumazet, David S. Miller, netdev, linux-kernel
In-Reply-To: <20100123165657.187c11e4@neptune.home>

On Sat, Jan 23, 2010 at 04:56:57PM +0100, Bruno Prémont wrote:
>Today I tried out 2.6.33-rc5 but always got crashing system:
>
>[   26.390576] BUG: unable to handle kernel NULL pointer dereference at (null)
>[   26.396369] IP: [<df856b89>] vlan_skb_recv+0x89/0x280 [8021q]


What does 'addr2line -e vmlinux 0xdf856b89' say?

Thanks.


-- 
Live like a child, think like the god.
 

^ permalink raw reply

* Re: [PATCH 1/2] e1000: Fix DMA mapping error handling on TX
From: Jeff Kirsher @ 2010-01-24  3:58 UTC (permalink / raw)
  To: Anton Blanchard
  Cc: Yi Zou, e1000-devel, Bruce Allan, Jesse Brandeburg, John Ronciak,
	netdev, Roel Kluin
In-Reply-To: <20100124004753.GB2996@kryten>

On Sat, Jan 23, 2010 at 16:47, Anton Blanchard <anton@samba.org> wrote:
>
> Hi,
>
>> This patch does not apply to the current e1000 driver in net-2.6, much
>> of this patch has already been corrected (applied) by Roel Kluin
>> recent patch.
>
> Sorry I was basing off net-next. I just compared it to my fix and looks like
> the patch in net-2.6 has an off by one error doesn't it?
>
> Anton
>
> --
>

This was discussed during our code review of Roel's patch, and it was
found that there was not an issue.  But I will review the code again
to ensure that there is not "an off by one error".  Thanks for looking
at this.

-- 
Cheers,
Jeff

------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
E1000-devel mailing list
E1000-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/e1000-devel
To learn more about Intel&#174; Ethernet, visit http://communities.intel.com/community/wired

^ permalink raw reply

* Re: Hang: 2.6.32.4 sky2/DMAR (was [PATCH] sky2: Fix WARNING: at lib/dma-debug.c:902 check_sync)
From: Michael Breuer @ 2010-01-24  1:53 UTC (permalink / raw)
  To: Jarek Poplawski
  Cc: David Miller, Stephen Hemminger, akpm, flyboy, linux-kernel,
	netdev, Michael Chan, Don Fry, Francois Romieu, Matt Carlson
In-Reply-To: <20100123232133.GA3487@del.dom.local>

On 1/23/2010 6:21 PM, Jarek Poplawski wrote:
> On Fri, Jan 22, 2010 at 06:50:21PM -0500, Michael Breuer wrote:
>    
>> When the packets were dropped, there was a different sequence in the
>> log - DISCOVER/OFFER repeated. The "normal" is that the sequence
>> appeared correct and complete - DISCOVER/OFFER/REQUEST/ACK - or
>> INFORM/ACK (vs. INFORM repeatedly sans ACK) as the case may be.
>>      
> Anyway, I'd be intersted if the switch matters here.
>
> Plus one more test: could you try to load sky2 with the parameter:
> "copybreak=1" (the rest as in any recent test, which gave you dmar
> errors; any switch).
>
> Thanks,
> Jarek P.
>    
Ok - will try with and without the copybreak=1 after I'm done bisecting 
2.6.33 rc5 for something unrelated (it'll take a couple of days for each 
unless a crash occurs in less that 48 hours).

^ permalink raw reply

* Re: Bug#565404: linux-image-2.6.26-2-amd64: atl1e: TSO is broken
From: Herbert Xu @ 2010-01-24  1:36 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: anders, Jie.Yang, netdev, 565404, Xiong.Huang
In-Reply-To: <1264260580.373.77.camel@localhost>

Ben Hutchings <ben@decadent.org.uk> wrote:
> 
> Based on the TCP sequence numbers, it seems that the length of the
> broken packet is correct but its IP header is wrong.
> 
> My understanding is that the length of the TCP payload in a GSO skb must
> always be a multiple of the gso_size, so that hardware is not required
> to adjust length fields.  So I see several possible explanations:

No, there is no such requirement.  The trailer skb can be of any
size less than or equal to gso_size.

However, if the hardware assumed this then yes it would explain
the problem.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply

* Re: [PATCH 1/2] e1000: Fix DMA mapping error handling on TX
From: Anton Blanchard @ 2010-01-24  0:47 UTC (permalink / raw)
  To: Jeff Kirsher
  Cc: Yi Zou, e1000-devel, Bruce Allan, Jesse Brandeburg, John Ronciak,
	netdev, Roel Kluin
In-Reply-To: <9929d2391001221940r4482dde4k8e5409bc7933bc21@mail.gmail.com>

 
Hi,

> This patch does not apply to the current e1000 driver in net-2.6, much
> of this patch has already been corrected (applied) by Roel Kluin
> recent patch.

Sorry I was basing off net-next. I just compared it to my fix and looks like
the patch in net-2.6 has an off by one error doesn't it?

Anton

--

Subject: [PATCH] e1000: Fix DMA mapping error handling on TX

e1000_tx_map has an off by one error in the dma mapping error cleanup path.
We decrement count and never clean the first successfully mapped descriptor.

Signed-off-by: Anton Blanchard <anton@samba.org>
---

diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
index d29bb53..427cedd 100644
--- a/drivers/net/e1000/e1000_main.c
+++ b/drivers/net/e1000/e1000_main.c
@@ -2790,8 +2790,6 @@ static int e1000_tx_map(struct e1000_adapter *adapter,
 dma_error:
 	dev_err(&pdev->dev, "TX DMA map failed\n");
 	buffer_info->dma = 0;
-	if (count)
-		count--;
 
 	while (count--) {
 		if (i==0)

------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
E1000-devel mailing list
E1000-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/e1000-devel
To learn more about Intel&#174; Ethernet, visit http://communities.intel.com/community/wired

^ permalink raw reply related

* Re: [PATCH] netns xfrm: fix "ip xfrm state|policy count" misreport
From: Herbert Xu @ 2010-01-24  0:12 UTC (permalink / raw)
  To: Alexey Dobriyan; +Cc: davem, netdev, containers
In-Reply-To: <20100123233709.GA4157@x200>

On Sun, Jan 24, 2010 at 01:37:10AM +0200, Alexey Dobriyan wrote:
> "ip xfrm state|policy count" report SA/SP count from init_net,
> not from netns of caller process.
> 
> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>

Looks good to me.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

Thanks,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply

* [PATCH] netns xfrm: fix "ip xfrm state|policy count" misreport
From: Alexey Dobriyan @ 2010-01-23 23:37 UTC (permalink / raw)
  To: davem-fT/PcQaiUtIeIZ0/mPfg9Q
  Cc: netdev-u79uwXL29TY76Z2rM5mHXA,
	containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA,
	herbert-lOAM2aK0SrRLBo1qDEOMRrpzq4S04n8Q

"ip xfrm state|policy count" report SA/SP count from init_net,
not from netns of caller process.

Signed-off-by: Alexey Dobriyan <adobriyan-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
---

 include/net/xfrm.h     |    4 ++--
 net/xfrm/xfrm_policy.c |   16 ++++++++--------
 net/xfrm/xfrm_state.c  |    6 +++---
 net/xfrm/xfrm_user.c   |   14 ++++++++------
 4 files changed, 21 insertions(+), 19 deletions(-)

--- a/include/net/xfrm.h
+++ b/include/net/xfrm.h
@@ -1367,8 +1367,8 @@ struct xfrmk_spdinfo {
 extern struct xfrm_state *xfrm_find_acq_byseq(struct net *net, u32 seq);
 extern int xfrm_state_delete(struct xfrm_state *x);
 extern int xfrm_state_flush(struct net *net, u8 proto, struct xfrm_audit *audit_info);
-extern void xfrm_sad_getinfo(struct xfrmk_sadinfo *si);
-extern void xfrm_spd_getinfo(struct xfrmk_spdinfo *si);
+extern void xfrm_sad_getinfo(struct net *net, struct xfrmk_sadinfo *si);
+extern void xfrm_spd_getinfo(struct net *net, struct xfrmk_spdinfo *si);
 extern int xfrm_replay_check(struct xfrm_state *x,
 			     struct sk_buff *skb, __be32 seq);
 extern void xfrm_replay_advance(struct xfrm_state *x, __be32 seq);
--- a/net/xfrm/xfrm_policy.c
+++ b/net/xfrm/xfrm_policy.c
@@ -469,16 +469,16 @@ static inline int xfrm_byidx_should_resize(struct net *net, int total)
 	return 0;
 }
 
-void xfrm_spd_getinfo(struct xfrmk_spdinfo *si)
+void xfrm_spd_getinfo(struct net *net, struct xfrmk_spdinfo *si)
 {
 	read_lock_bh(&xfrm_policy_lock);
-	si->incnt = init_net.xfrm.policy_count[XFRM_POLICY_IN];
-	si->outcnt = init_net.xfrm.policy_count[XFRM_POLICY_OUT];
-	si->fwdcnt = init_net.xfrm.policy_count[XFRM_POLICY_FWD];
-	si->inscnt = init_net.xfrm.policy_count[XFRM_POLICY_IN+XFRM_POLICY_MAX];
-	si->outscnt = init_net.xfrm.policy_count[XFRM_POLICY_OUT+XFRM_POLICY_MAX];
-	si->fwdscnt = init_net.xfrm.policy_count[XFRM_POLICY_FWD+XFRM_POLICY_MAX];
-	si->spdhcnt = init_net.xfrm.policy_idx_hmask;
+	si->incnt = net->xfrm.policy_count[XFRM_POLICY_IN];
+	si->outcnt = net->xfrm.policy_count[XFRM_POLICY_OUT];
+	si->fwdcnt = net->xfrm.policy_count[XFRM_POLICY_FWD];
+	si->inscnt = net->xfrm.policy_count[XFRM_POLICY_IN+XFRM_POLICY_MAX];
+	si->outscnt = net->xfrm.policy_count[XFRM_POLICY_OUT+XFRM_POLICY_MAX];
+	si->fwdscnt = net->xfrm.policy_count[XFRM_POLICY_FWD+XFRM_POLICY_MAX];
+	si->spdhcnt = net->xfrm.policy_idx_hmask;
 	si->spdhmcnt = xfrm_policy_hashmax;
 	read_unlock_bh(&xfrm_policy_lock);
 }
--- a/net/xfrm/xfrm_state.c
+++ b/net/xfrm/xfrm_state.c
@@ -641,11 +641,11 @@ out:
 }
 EXPORT_SYMBOL(xfrm_state_flush);
 
-void xfrm_sad_getinfo(struct xfrmk_sadinfo *si)
+void xfrm_sad_getinfo(struct net *net, struct xfrmk_sadinfo *si)
 {
 	spin_lock_bh(&xfrm_state_lock);
-	si->sadcnt = init_net.xfrm.state_num;
-	si->sadhcnt = init_net.xfrm.state_hmask;
+	si->sadcnt = net->xfrm.state_num;
+	si->sadhcnt = net->xfrm.state_hmask;
 	si->sadhmcnt = xfrm_state_hashmax;
 	spin_unlock_bh(&xfrm_state_lock);
 }
--- a/net/xfrm/xfrm_user.c
+++ b/net/xfrm/xfrm_user.c
@@ -781,7 +781,8 @@ static inline size_t xfrm_spdinfo_msgsize(void)
 	       + nla_total_size(sizeof(struct xfrmu_spdhinfo));
 }
 
-static int build_spdinfo(struct sk_buff *skb, u32 pid, u32 seq, u32 flags)
+static int build_spdinfo(struct sk_buff *skb, struct net *net,
+			 u32 pid, u32 seq, u32 flags)
 {
 	struct xfrmk_spdinfo si;
 	struct xfrmu_spdinfo spc;
@@ -795,7 +796,7 @@ static int build_spdinfo(struct sk_buff *skb, u32 pid, u32 seq, u32 flags)
 
 	f = nlmsg_data(nlh);
 	*f = flags;
-	xfrm_spd_getinfo(&si);
+	xfrm_spd_getinfo(net, &si);
 	spc.incnt = si.incnt;
 	spc.outcnt = si.outcnt;
 	spc.fwdcnt = si.fwdcnt;
@@ -828,7 +829,7 @@ static int xfrm_get_spdinfo(struct sk_buff *skb, struct nlmsghdr *nlh,
 	if (r_skb == NULL)
 		return -ENOMEM;
 
-	if (build_spdinfo(r_skb, spid, seq, *flags) < 0)
+	if (build_spdinfo(r_skb, net, spid, seq, *flags) < 0)
 		BUG();
 
 	return nlmsg_unicast(net->xfrm.nlsk, r_skb, spid);
@@ -841,7 +842,8 @@ static inline size_t xfrm_sadinfo_msgsize(void)
 	       + nla_total_size(4); /* XFRMA_SAD_CNT */
 }
 
-static int build_sadinfo(struct sk_buff *skb, u32 pid, u32 seq, u32 flags)
+static int build_sadinfo(struct sk_buff *skb, struct net *net,
+			 u32 pid, u32 seq, u32 flags)
 {
 	struct xfrmk_sadinfo si;
 	struct xfrmu_sadhinfo sh;
@@ -854,7 +856,7 @@ static int build_sadinfo(struct sk_buff *skb, u32 pid, u32 seq, u32 flags)
 
 	f = nlmsg_data(nlh);
 	*f = flags;
-	xfrm_sad_getinfo(&si);
+	xfrm_sad_getinfo(net, &si);
 
 	sh.sadhmcnt = si.sadhmcnt;
 	sh.sadhcnt = si.sadhcnt;
@@ -882,7 +884,7 @@ static int xfrm_get_sadinfo(struct sk_buff *skb, struct nlmsghdr *nlh,
 	if (r_skb == NULL)
 		return -ENOMEM;
 
-	if (build_sadinfo(r_skb, spid, seq, *flags) < 0)
+	if (build_sadinfo(r_skb, net, spid, seq, *flags) < 0)
 		BUG();
 
 	return nlmsg_unicast(net->xfrm.nlsk, r_skb, spid);

^ permalink raw reply

* Re: [PATCH] tcp: fix ICMP-RTO war
From: Denys Fedoryshchenko @ 2010-01-23 23:28 UTC (permalink / raw)
  To: Ilpo Järvinen; +Cc: Damian Lukowski, Netdev, David Miller
In-Reply-To: <alpine.DEB.2.00.1001240007530.16552@melkinpaasi.cs.helsinki.fi>

On Sunday 24 January 2010 00:34:43 Ilpo Järvinen wrote:
> Restored Damian cc, please keep them.
> 
> On Sat, 23 Jan 2010, Denys Fedoryshchenko wrote:
> > On Tuesday 19 January 2010 13:17:51 you wrote:
> > > On Tue, 19 Jan 2010, Denys Fedoryshchenko wrote:
> > > > On Tuesday 19 January 2010 11:10:12 you wrote:
> > > > > Hi,
> > > > > thank you for testing. So srtt and rttvar is zero in any of those
> > > > > cases. Ilpo, it is a bug in tcp_rtt_estimator then, I suppose?
> > > > >
> > > > > There is also a code comment in tcp_input.c, saying:
> > > > > > * NOTE: clamping at TCP_RTO_MIN is not required, current algo
> > > > > > * guarantees that rto is higher.
> > > > >
> > > > > So we either fix tcp_rtt_estimator or simply clamp at TCP_RTO_MIN?
> > > > >
> > > > > Damian
> > > > >
> > > > > > On Monday 11 January 2010 15:02:34 you wrote:
> > > > > >> On Sat, 26 Dec 2009, Denys Fedoryshchenko wrote:
> > > > > >>> Few more dumps. I notice:
> > > > > >>> 1)Ack always equal 1
> > > > > >>> 2)It is usually first segment of data sent (?)
> > > > > >>>
> > > > > >>> Maybe some value not initialised properly?
> > > > > >>
> > > > > >> Can you see if the RTO lower bound is violated (I added some
> > > > > >> printing of vars there too already now if it turns out to be
> > > > > >> something):
> > > > > >>
> > > > > >> diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c
> > > > > >> index 65b8ebf..d84469f 100644
> > > > > >> --- a/net/ipv4/tcp_ipv4.c
> > > > > >> +++ b/net/ipv4/tcp_ipv4.c
> > > >
> > > > As i see in code it is rounding RTO to minimum value.
> > > > It fixes my problem seems.
> > > >
> > > > Btw just a bit about my environment - wireless networks (sometimes
> > > > lossy!) with low speed (128-512Kbps) customers working over pppoe.
> > > > Maybe it will give a tip why rtt value is too low.
> > >
> > > What I find most strange in it is the fact that when it triggers for
> > > the first time, the srtt and mdev are zero, not some value in between 0
> > > and 200ms. Therefore I suspect that this case might be something that
> > > we've overlooked where srtt/mdev are not valid at all.
> > >
> > > Maybe the patch below helps...
> >
> > Seems after this patch (and debug patch with warnings) my dmesg is clean.
> 
> Cool, thanks for testing.
> 
> Dave, please send into stable too (besides net-2.6). If we want less strict
> state check we can continue playing with that in net-next, IMHO.
> 
I extend a little bit debug to 
printk("lower bound violation: %u code %u sk_state %u\n", icsk->icsk_rto, 
code,sk->sk_state);

Here is result:
[  566.990065] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  566.990111] rto: 200 (0 >> 3 + 0, 5) time: 266990 sent: 263925 pen: 1 
383925 rem: 0                                                                                           
[  570.058555] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  570.058603] rto: 200 (0 >> 3 + 0, 8) time: 270058 sent: 269790 pen: 1 
272990 rem: 0                                                                                           
[  570.058660] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  570.058698] rto: 200 (0 >> 3 + 0, 8) time: 270058 sent: 270058 pen: 1 
270458 rem: 200                                                                                         
[  573.122550] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  573.122626] rto: 200 (0 >> 3 + 0, 11) time: 273122 sent: 273058 pen: 1 
276258 rem: 136                                                                                        
[  573.122745] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  573.122815] rto: 200 (0 >> 3 + 0, 10) time: 273122 sent: 273058 pen: 1 
273258 rem: 136                                                                                        
[  573.122931] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  573.123001] rto: 200 (0 >> 3 + 0, 9) time: 273122 sent: 273058 pen: 1 
273258 rem: 136                                                                                         
[  576.304338] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  576.304423] rto: 200 (0 >> 3 + 0, 12) time: 276304 sent: 276059 pen: 1 
279259 rem: 0                                                                                          
[  576.326167] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  576.326251] rto: 200 (0 >> 3 + 0, 12) time: 276326 sent: 276304 pen: 1 
276704 rem: 178                                                                                        
[  579.360343] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  579.360427] rto: 200 (0 >> 3 + 0, 15) time: 279360 sent: 279304 pen: 1 
282504 rem: 144                                                                                        
[  582.566834] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  582.566919] rto: 200 (0 >> 3 + 0, 18) time: 282566 sent: 282304 pen: 1 
285504 rem: 0                                                                                          
[  582.567085] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  582.567162] rto: 200 (0 >> 3 + 0, 18) time: 282567 sent: 282567 pen: 1 
282967 rem: 200                                                                                        
[  582.567280] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  582.567351] rto: 200 (0 >> 3 + 0, 17) time: 282567 sent: 282567 pen: 1 
282767 rem: 200                                                                                        
[  585.649877] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  585.649962] rto: 200 (0 >> 3 + 0, 20) time: 285649 sent: 285567 pen: 1 
288767 rem: 118                                                                                        
[  585.650097] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  585.650178] rto: 200 (0 >> 3 + 0, 19) time: 285650 sent: 285567 pen: 1 
285768 rem: 117                                                                                        
[  588.836754] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  588.836845] rto: 200 (0 >> 3 + 0, 22) time: 288836 sent: 288567 pen: 1 
291767 rem: 0                                                                                          
[  588.836970] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  588.837042] rto: 200 (0 >> 3 + 0, 22) time: 288836 sent: 288836 pen: 1 
289236 rem: 200                                                                                        
[  591.902908] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  591.902996] rto: 200 (0 >> 3 + 0, 25) time: 291902 sent: 291837 pen: 1 
295037 rem: 135                                                                                        
[  591.903129] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  591.903205] rto: 200 (0 >> 3 + 0, 24) time: 291903 sent: 291837 pen: 1 
292038 rem: 134                                                                                        
[  595.091391] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  595.091477] rto: 200 (0 >> 3 + 0, 27) time: 295091 sent: 294837 pen: 1 
298037 rem: 0                                                                                          
[  595.091627] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  595.091702] rto: 200 (0 >> 3 + 0, 27) time: 295091 sent: 295091 pen: 1 
295491 rem: 200                                                                                        
[  598.141828] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  598.141913] rto: 200 (0 >> 3 + 0, 30) time: 298141 sent: 298091 pen: 1 
301291 rem: 150                                                                                        
[  598.142043] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  598.142114] rto: 200 (0 >> 3 + 0, 29) time: 298141 sent: 298091 pen: 1 
298291 rem: 150                                                                                        
[  598.142252] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  598.142344] rto: 200 (0 >> 3 + 0, 28) time: 298142 sent: 298091 pen: 1 
298291 rem: 149                                                                                        
[  601.146649] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  601.146734] rto: 200 (0 >> 3 + 0, 31) time: 301146 sent: 301091 pen: 1 
304291 rem: 145                                                                                        
[  601.178998] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  601.179090] rto: 200 (0 >> 3 + 0, 30) time: 301179 sent: 301091 pen: 1 
301291 rem: 112                                                                                        
[  601.179227] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  601.179298] rto: 200 (0 >> 3 + 0, 29) time: 301179 sent: 301091 pen: 1 
301291 rem: 112                                                                                        
[  604.193304] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  604.193389] rto: 200 (0 >> 3 + 0, 32) time: 304193 sent: 304091 pen: 1 
307291 rem: 98                                                                                         
[  604.193518] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  604.193589] rto: 200 (0 >> 3 + 0, 31) time: 304193 sent: 304091 pen: 1 
304291 rem: 98                                                                                         
[  604.193706] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  604.193776] rto: 200 (0 >> 3 + 0, 30) time: 304193 sent: 304091 pen: 1 
304291 rem: 98                                                                                         
[  607.341327] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  607.341412] rto: 200 (0 >> 3 + 0, 33) time: 307341 sent: 307091 pen: 1 
310291 rem: 0                                                                                          
[  607.370345] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  607.370427] rto: 200 (0 >> 3 + 0, 33) time: 307370 sent: 307341 pen: 1 
307741 rem: 171                                                                                        
[  607.370657] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  607.370730] rto: 200 (0 >> 3 + 0, 32) time: 307370 sent: 307341 pen: 1 
307541 rem: 171                                                                                        
[  610.437075] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  610.437161] rto: 200 (0 >> 3 + 0, 35) time: 310437 sent: 310341 pen: 1 
313541 rem: 104                                                                                        
[  610.437302] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  610.437374] rto: 200 (0 >> 3 + 0, 34) time: 310437 sent: 310341 pen: 1 
310541 rem: 104                                                                                        
[  610.437497] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  610.437567] rto: 200 (0 >> 3 + 0, 33) time: 310437 sent: 310341 pen: 1 
310541 rem: 104                                                                                        
[  613.429680] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  613.429770] rto: 200 (0 >> 3 + 0, 36) time: 313429 sent: 313341 pen: 1 
316541 rem: 112                                                                                        
[  613.429899] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  613.429970] rto: 200 (0 >> 3 + 0, 35) time: 313429 sent: 313341 pen: 1 
313541 rem: 112                                                                                        
[  613.430087] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  613.430164] rto: 200 (0 >> 3 + 0, 34) time: 313430 sent: 313341 pen: 1 
313542 rem: 111                                                                                        
[  616.644279] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  616.644364] rto: 200 (0 >> 3 + 0, 37) time: 316644 sent: 316341 pen: 1 
319541 rem: 0                                                                                          
[  616.644500] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  616.644572] rto: 200 (0 >> 3 + 0, 37) time: 316644 sent: 316644 pen: 1 
317044 rem: 200                                                                                        
[  616.644689] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  616.644760] rto: 200 (0 >> 3 + 0, 36) time: 316644 sent: 316644 pen: 1 
316844 rem: 200                                                                                        
[  617.028542] rto: 120000 (788 >> 3 + 266, 10) time: 317028 sent: 313993 pen: 
1 433993 rem: 116965                                                                              
[  619.711969] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  619.712050] rto: 200 (0 >> 3 + 0, 39) time: 319712 sent: 319644 pen: 1 
322844 rem: 132                                                                                        
[  619.712169] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  619.712240] rto: 200 (0 >> 3 + 0, 38) time: 319712 sent: 319644 pen: 1 
319844 rem: 132                                                                                        
[  619.712364] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  619.712435] rto: 200 (0 >> 3 + 0, 37) time: 319712 sent: 319644 pen: 1 
319844 rem: 132                                                                                        
[  622.908447] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  622.908531] rto: 200 (0 >> 3 + 0, 40) time: 322908 sent: 322644 pen: 1 
325844 rem: 0                                                                                          
[  622.909274] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  622.909347] rto: 200 (0 >> 3 + 0, 40) time: 322909 sent: 322908 pen: 1 
323308 rem: 199                                                                                        
[  622.914930] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  622.915014] rto: 200 (0 >> 3 + 0, 39) time: 322914 sent: 322908 pen: 1 
323108 rem: 194                                                                                        
[  625.975145] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  625.975232] rto: 200 (0 >> 3 + 0, 42) time: 325975 sent: 325909 pen: 1 
329109 rem: 134                                                                                        
[  625.975350] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  625.975422] rto: 200 (0 >> 3 + 0, 41) time: 325975 sent: 325909 pen: 1 
326109 rem: 134                                                                                        
[  625.975538] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  625.975609] rto: 200 (0 >> 3 + 0, 40) time: 325975 sent: 325909 pen: 1 
326109 rem: 134                                                                                        
[  629.187199] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  629.187286] rto: 200 (0 >> 3 + 0, 43) time: 329187 sent: 328909 pen: 1 
332109 rem: 0                                                                                          
[  629.187454] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  629.187529] rto: 200 (0 >> 3 + 0, 43) time: 329187 sent: 329187 pen: 1 
329587 rem: 200                                                                                        
[  629.187646] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  629.187717] rto: 200 (0 >> 3 + 0, 42) time: 329187 sent: 329187 pen: 1 
329387 rem: 200                                                                                        
[  632.232822] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  632.232907] rto: 200 (0 >> 3 + 0, 45) time: 332232 sent: 332187 pen: 1 
335387 rem: 155                                                                                        
[  632.250500] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  632.250585] rto: 200 (0 >> 3 + 0, 44) time: 332250 sent: 332187 pen: 1 
332388 rem: 137                                                                                        
[  632.250714] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  632.250785] rto: 200 (0 >> 3 + 0, 43) time: 332250 sent: 332187 pen: 1 
332387 rem: 137                                                                                        
[  635.247889] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  635.247974] rto: 200 (0 >> 3 + 0, 46) time: 335247 sent: 335187 pen: 1 
338387 rem: 140                                                                                        
[  635.248416] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  635.248490] rto: 200 (0 >> 3 + 0, 45) time: 335248 sent: 335187 pen: 1 
335387 rem: 139                                                                                        
[  635.251046] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  635.251122] rto: 200 (0 >> 3 + 0, 44) time: 335251 sent: 335187 pen: 1 
335387 rem: 136                                                                                        
[  638.434799] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  638.434883] rto: 200 (0 >> 3 + 0, 47) time: 338434 sent: 338187 pen: 1 
341387 rem: 0                                                                                          
[  638.435018] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  638.435090] rto: 200 (0 >> 3 + 0, 47) time: 338435 sent: 338434 pen: 1 
338834 rem: 199                                                                                        
[  638.435215] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  638.435993] rto: 200 (0 >> 3 + 0, 46) time: 338435 sent: 338434 pen: 1 
338634 rem: 199                                                                                        
[  641.501303] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  641.501380] rto: 200 (0 >> 3 + 0, 49) time: 341501 sent: 341435 pen: 1 
344635 rem: 134                                                                                        
[  641.501501] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  641.501571] rto: 200 (0 >> 3 + 0, 48) time: 341501 sent: 341435 pen: 1 
341635 rem: 134                                                                                        
[  641.501687] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  641.501757] rto: 200 (0 >> 3 + 0, 47) time: 341501 sent: 341435 pen: 1 
341635 rem: 134                                                                                        
[  644.518586] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  644.518672] rto: 200 (0 >> 3 + 0, 50) time: 344518 sent: 344435 pen: 1 
347635 rem: 117                                                                                        
[  644.518849] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  644.518930] rto: 200 (0 >> 3 + 0, 49) time: 344518 sent: 344435 pen: 1 
344635 rem: 117                                                                                        
[  644.519071] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  644.519158] rto: 200 (0 >> 3 + 0, 48) time: 344519 sent: 344435 pen: 1 
344636 rem: 116                                                                                        
[  647.725632] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  647.725717] rto: 200 (0 >> 3 + 0, 51) time: 347725 sent: 347435 pen: 1 
350635 rem: 0                                                                                          
[  647.725850] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  647.725921] rto: 200 (0 >> 3 + 0, 51) time: 347725 sent: 347725 pen: 1 
348125 rem: 200                                                                                        
[  647.729343] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  647.729417] rto: 200 (0 >> 3 + 0, 50) time: 347729 sent: 347725 pen: 1 
347925 rem: 196                                                                                        
[  650.787543] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  650.787619] rto: 200 (0 >> 3 + 0, 53) time: 350787 sent: 350726 pen: 1 
353926 rem: 139                                                                                        
[  650.798651] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  650.798749] rto: 200 (0 >> 3 + 0, 52) time: 350798 sent: 350726 pen: 1 
350926 rem: 128                                                                                        
[  650.805039] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  650.805123] rto: 200 (0 >> 3 + 0, 51) time: 350805 sent: 350726 pen: 1 
350926 rem: 121                                                                                        
[  653.801712] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  653.801788] rto: 200 (0 >> 3 + 0, 54) time: 353801 sent: 353726 pen: 1 
356926 rem: 125                                                                                        
[  653.801937] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  653.802023] rto: 200 (0 >> 3 + 0, 53) time: 353802 sent: 353726 pen: 1 
353926 rem: 124                                                                                        
[  653.802475] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  653.802548] rto: 200 (0 >> 3 + 0, 52) time: 353802 sent: 353726 pen: 1 
353926 rem: 124                                                                                        
[  656.985567] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  656.985653] rto: 200 (0 >> 3 + 0, 55) time: 356985 sent: 356726 pen: 1 
359926 rem: 0                                                                                          
[  656.986226] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  656.986299] rto: 200 (0 >> 3 + 0, 55) time: 356986 sent: 356985 pen: 1 
357385 rem: 199                                                                                        
[  656.986416] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  656.986486] rto: 200 (0 >> 3 + 0, 54) time: 356986 sent: 356985 pen: 1 
357185 rem: 199                                                                                        
[  660.042091] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  660.042168] rto: 200 (0 >> 3 + 0, 57) time: 360042 sent: 359985 pen: 1 
363185 rem: 143                                                                                        
[  660.042286] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  660.042357] rto: 200 (0 >> 3 + 0, 56) time: 360042 sent: 359985 pen: 1 
360185 rem: 143                                                                                        
[  660.076230] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  660.076315] rto: 200 (0 >> 3 + 0, 55) time: 360076 sent: 359985 pen: 1 
360185 rem: 109                                                                                        
[  663.256655] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  663.256731] rto: 200 (0 >> 3 + 0, 58) time: 363256 sent: 362985 pen: 1 
366185 rem: 0                                                                                          
[  663.341934] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  663.342010] rto: 200 (0 >> 3 + 0, 58) time: 363341 sent: 363256 pen: 1 
363656 rem: 115                                                                                        
[  663.428067] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  663.428156] rto: 200 (0 >> 3 + 0, 57) time: 363428 sent: 363256 pen: 1 
363457 rem: 28                                                                                         
[  666.308896] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  666.308980] rto: 200 (0 >> 3 + 0, 60) time: 366308 sent: 366256 pen: 1 
369456 rem: 148                                                                                        
[  666.309110] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  666.309186] rto: 200 (0 >> 3 + 0, 59) time: 366309 sent: 366256 pen: 1 
366457 rem: 147                                                                                        
[  666.309315] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  666.309386] rto: 200 (0 >> 3 + 0, 58) time: 366309 sent: 366256 pen: 1 
366456 rem: 147                                                                                        
[  669.519782] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  669.519866] rto: 200 (0 >> 3 + 0, 61) time: 369519 sent: 369256 pen: 1 
372456 rem: 0                                                                                          
[  669.520011] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  669.520083] rto: 200 (0 >> 3 + 0, 61) time: 369520 sent: 369519 pen: 1 
369919 rem: 199                                                                                        
[  669.520206] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  669.520286] rto: 200 (0 >> 3 + 0, 60) time: 369520 sent: 369519 pen: 1 
369719 rem: 199                                                                                        
[  672.641672] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  672.641756] rto: 200 (0 >> 3 + 0, 63) time: 372641 sent: 372519 pen: 1 
375719 rem: 78                                                                                         
[  672.642325] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  672.642407] rto: 200 (0 >> 3 + 0, 62) time: 372642 sent: 372519 pen: 1 
372719 rem: 77                                                                                         
[  672.642524] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  672.642596] rto: 200 (0 >> 3 + 0, 61) time: 372642 sent: 372519 pen: 1 
372719 rem: 77                                                                                         
[  675.789437] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  675.789522] rto: 200 (0 >> 3 + 0, 64) time: 375789 sent: 375519 pen: 1 
378719 rem: 0                                                                                          
[  675.789657] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  675.789727] rto: 200 (0 >> 3 + 0, 64) time: 375789 sent: 375789 pen: 1 
376189 rem: 200                                                                                        
[  675.813158] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  675.813242] rto: 200 (0 >> 3 + 0, 63) time: 375813 sent: 375789 pen: 1 
375989 rem: 176                                                                                        
[  678.902625] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  678.902689] rto: 200 (0 >> 3 + 0, 66) time: 378902 sent: 378789 pen: 1 
381989 rem: 87                                                                                         
[  678.902808] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  678.902869] rto: 200 (0 >> 3 + 0, 65) time: 378902 sent: 378789 pen: 1 
378989 rem: 87                                                                                         
[  678.902967] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  678.903027] rto: 200 (0 >> 3 + 0, 64) time: 378903 sent: 378789 pen: 1 
378989 rem: 86                                                                                         
[  682.086610] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  682.086673] rto: 200 (0 >> 3 + 0, 67) time: 382086 sent: 381789 pen: 1 
384989 rem: 0                                                                                          
[  682.086823] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  682.086885] rto: 200 (0 >> 3 + 0, 67) time: 382086 sent: 382086 pen: 1 
382486 rem: 200                                                                                        
[  682.086988] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  682.087042] rto: 200 (0 >> 3 + 0, 66) time: 382087 sent: 382086 pen: 1 
382286 rem: 199                                                                                        
[  685.177400] lower bound violation: 0 code 1 sk_state 1                                                                                                                        
[  685.177460] rto: 200 (0 >> 3 + 0, 69) time: 385177 sent: 385086 pen: 1 
388286 rem: 109                                                                                        
[  685.177566] lower bound violation: 0 code 1 sk_state 1
[  685.177630] rto: 200 (0 >> 3 + 0, 68) time: 385177 sent: 385086 pen: 1 
385286 rem: 109
[  685.177734] lower bound violation: 0 code 1 sk_state 1
[  685.177790] rto: 200 (0 >> 3 + 0, 67) time: 385177 sent: 385086 pen: 1 
385286 rem: 109
[  688.339503] lower bound violation: 0 code 1 sk_state 1
[  688.339565] rto: 200 (0 >> 3 + 0, 70) time: 388339 sent: 388086 pen: 1 
391286 rem: 0
[  688.339684] lower bound violation: 0 code 1 sk_state 1
[  688.339745] rto: 200 (0 >> 3 + 0, 70) time: 388339 sent: 388339 pen: 1 
388739 rem: 200
[  688.339844] lower bound violation: 0 code 1 sk_state 1
[  688.339896] rto: 200 (0 >> 3 + 0, 69) time: 388339 sent: 388339 pen: 1 
388539 rem: 200
[  691.925180] lower bound violation: 0 code 1 sk_state 1
[  691.925242] rto: 200 (0 >> 3 + 0, 72) time: 391925 sent: 391339 pen: 1 
394539 rem: 0
[  692.010074] lower bound violation: 0 code 1 sk_state 1
[  692.010131] rto: 200 (0 >> 3 + 0, 72) time: 392009 sent: 391925 pen: 1 
392325 rem: 116
[  692.096188] lower bound violation: 0 code 1 sk_state 1
[  692.096254] rto: 200 (0 >> 3 + 0, 71) time: 392096 sent: 391925 pen: 1 
392126 rem: 29
[  694.474680] lower bound violation: 0 code 1 sk_state 1
[  694.474742] rto: 200 (0 >> 3 + 0, 73) time: 394474 sent: 393325 pen: 1 
394925 rem: 0
[  694.475751] lower bound violation: 0 code 1 sk_state 1
[  694.475810] rto: 200 (0 >> 3 + 0, 73) time: 394475 sent: 394474 pen: 1 
394874 rem: 199
[  694.475918] lower bound violation: 0 code 1 sk_state 1
[  694.475975] rto: 200 (0 >> 3 + 0, 72) time: 394475 sent: 394474 pen: 1 
394674 rem: 199
[  697.572814] lower bound violation: 0 code 1 sk_state 1
[  697.572877] rto: 200 (0 >> 3 + 0, 75) time: 397572 sent: 397474 pen: 1 
400674 rem: 102
[  697.572986] lower bound violation: 0 code 1 sk_state 1
[  697.573052] rto: 200 (0 >> 3 + 0, 74) time: 397573 sent: 397474 pen: 1 
397674 rem: 101
[  697.573159] lower bound violation: 0 code 1 sk_state 1
[  697.573211] rto: 200 (0 >> 3 + 0, 73) time: 397573 sent: 397474 pen: 1 
397674 rem: 101
[  700.728072] lower bound violation: 0 code 1 sk_state 1
[  700.728135] rto: 200 (0 >> 3 + 0, 76) time: 400728 sent: 400474 pen: 1 
403674 rem: 0
[  700.734010] lower bound violation: 0 code 1 sk_state 1
[  700.734079] rto: 200 (0 >> 3 + 0, 76) time: 400734 sent: 400728 pen: 1 
401128 rem: 194
[  700.734191] lower bound violation: 0 code 1 sk_state 1
[  700.734944] rto: 200 (0 >> 3 + 0, 75) time: 400734 sent: 400728 pen: 1 
400928 rem: 194
[  703.779459] lower bound violation: 0 code 1 sk_state 1
[  703.779521] rto: 200 (0 >> 3 + 0, 78) time: 403779 sent: 403729 pen: 1 
406929 rem: 150
[  703.779628] lower bound violation: 0 code 1 sk_state 1
[  703.779680] rto: 200 (0 >> 3 + 0, 77) time: 403779 sent: 403729 pen: 1 
403929 rem: 150
[  703.779797] lower bound violation: 0 code 1 sk_state 1
[  703.779850] rto: 200 (0 >> 3 + 0, 76) time: 403779 sent: 403729 pen: 1 
403929 rem: 150

^ permalink raw reply

* Re: Hang: 2.6.32.4 sky2/DMAR (was [PATCH] sky2: Fix WARNING: at lib/dma-debug.c:902 check_sync)
From: Jarek Poplawski @ 2010-01-23 23:21 UTC (permalink / raw)
  To: Michael Breuer
  Cc: David Miller, Stephen Hemminger, akpm, flyboy, linux-kernel,
	netdev, Michael Chan, Don Fry, Francois Romieu, Matt Carlson
In-Reply-To: <4B5A39BD.8020305@majjas.com>

On Fri, Jan 22, 2010 at 06:50:21PM -0500, Michael Breuer wrote:
> When the packets were dropped, there was a different sequence in the
> log - DISCOVER/OFFER repeated. The "normal" is that the sequence
> appeared correct and complete - DISCOVER/OFFER/REQUEST/ACK - or
> INFORM/ACK (vs. INFORM repeatedly sans ACK) as the case may be.

Anyway, I'd be intersted if the switch matters here.

Plus one more test: could you try to load sky2 with the parameter:
"copybreak=1" (the rest as in any recent test, which gave you dmar
errors; any switch).

Thanks,
Jarek P.

^ permalink raw reply

* Re: linux bridge problem
From: Mark Smith @ 2010-01-23 22:53 UTC (permalink / raw)
  To: Metuki Sabhe; +Cc: bridge, netdev
In-Reply-To: <549992e51001230641n2e40d2co31573386e258a5cb@mail.gmail.com>

On Sat, 23 Jan 2010 16:41:40 +0200
Metuki Sabhe <sabhe.metuki@gmail.com> wrote:

> CC'ing netdev too:
> 
> 
>  Hello,
> 
>  When I add interfaces to the bridge *after* I have "tcpdump -n -i br0"
>  running on the bridge,
>  my tcpdump don't see any communication. If I kill tcpdump and
>  re-execute it *after* I added
>  the interface to the bridge, it works just fine.
> 

How long are you waiting? Make sure you're not encountering the default
forwarding delay of 20 seconds You can change that value to zero using

brctl setfd br0 0

which brings new interfaces into forwarding state immediately, rather
than going through the listening and/or learning states.

>  The same behavior happens with my DHCP server (which listens only on
>  my bridge interface);
>  I need to re-execute (reset) it after I add the interface to the bridge.
> 
>  Is that normal ?
> 
>  Why does it happen ?
> 
>  What should I do ?
> 
>  It's a little awkward to reset my DHCP server every time I add a new
>  interface to the bridge..
> 
>  Thanks,
>  Sabhe
> --
> 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

^ permalink raw reply

* Re: [PATCH] tcp: fix ICMP-RTO war
From: Denys Fedoryshchenko @ 2010-01-23 22:45 UTC (permalink / raw)
  To: Ilpo Järvinen; +Cc: Damian Lukowski, Netdev, David Miller
In-Reply-To: <alpine.DEB.2.00.1001240007530.16552@melkinpaasi.cs.helsinki.fi>


> 
> Cool, thanks for testing.
> 
> Dave, please send into stable too (besides net-2.6). If we want less strict
> state check we can continue playing with that in net-next, IMHO.
> 
Maybe better to wait. Sad news, got messages after while (before they was 
appearing  almost immediately on such load).

Here it is
[ 1253.821745] rto: 26496 (58 >> 3 + 200, 7) time: 953821 sent: 953283 pen: 1 
1006275 rem: 25958                                                                                 
[ 1278.791976] rto: 75264 (398 >> 3 + 245, 8) time: 978791 sent: 977749 pen: 1 
1097749 rem: 74222                                                                                
[ 1299.537823] lower bound violation: 0                                                                                                                                          
[ 1299.537846] rto: 200 (0 >> 3 + 0, 1) time: 999537 sent: 997699 pen: 1 
1009699 rem: 0                                                                                          
[ 1324.022158] rto: 11072 (2512 >> 3 + 1070, 3) time: 1024022 sent: 1023672 
pen: 1 1045816 rem: 10722                                                                            
[ 1333.112517] rto: 52992 (58 >> 3 + 200, 8) time: 1033112 sent: 1032771 pen: 
1 1138755 rem: 52651                                                                               
[ 1336.152839] rto: 11072 (2512 >> 3 + 1070, 3) time: 1036152 sent: 1034744 
pen: 1 1056888 rem: 9664                                                                             
[ 1426.219799] lower bound violation: 0                                                                                                                                          
[ 1426.219858] rto: 200 (0 >> 3 + 0, 1) time: 1126219 sent: 1125040 pen: 1 
1137040 rem: 0                                                                                        
[ 1429.235911] lower bound violation: 0                                                                                                                                          
[ 1429.235964] rto: 200 (0 >> 3 + 0, 4) time: 1129235 sent: 1129019 pen: 1 
1132219 rem: 0                                                                                        
[ 1432.279829] lower bound violation: 0                                                                                                                                          
[ 1432.279887] rto: 200 (0 >> 3 + 0, 7) time: 1132279 sent: 1132036 pen: 1 
1135236 rem: 0                                                                                        
[ 1435.311008] lower bound violation: 0                                                                                                                                          
[ 1435.311068] rto: 200 (0 >> 3 + 0, 10) time: 1135311 sent: 1135079 pen: 1 
1138279 rem: 0                                                                                       
[ 1479.029269] lower bound violation: 0                                                                                                                                          
[ 1479.029323] rto: 200 (0 >> 3 + 0, 9) time: 1179029 sent: 1174129 pen: 1 
1294129 rem: 0                                                                                        
[ 1483.851712] lower bound violation: 0                                                                                                                                          
[ 1483.851773] rto: 200 (0 >> 3 + 0, 12) time: 1183851 sent: 1181829 pen: 1 
1185029 rem: 0                                                                                       
[ 1483.851878] lower bound violation: 0                                                                                                                                          
[ 1483.851926] rto: 200 (0 >> 3 + 0, 12) time: 1183851 sent: 1183851 pen: 1 
1184251 rem: 200                                                                                     
[ 1483.852034] lower bound violation: 0                                                                                                                                          
[ 1483.852082] rto: 200 (0 >> 3 + 0, 11) time: 1183852 sent: 1183851 pen: 1 
1184052 rem: 199                                                                                     
[ 1486.934283] lower bound violation: 0                                                                                                                                          
[ 1486.934339] rto: 200 (0 >> 3 + 0, 14) time: 1186934 sent: 1186851 pen: 1 
1190051 rem: 117                                                                                     
[ 1486.934500] lower bound violation: 0                                                                                                                                          
[ 1486.934554] rto: 200 (0 >> 3 + 0, 13) time: 1186934 sent: 1186851 pen: 1 
1187051 rem: 117                                                                                     
[ 1490.170941] lower bound violation: 0                                                                                                                                          
[ 1490.171000] rto: 200 (0 >> 3 + 0, 16) time: 1190170 sent: 1189851 pen: 1 
1193051 rem: 0                                                                                       
[ 1490.171126] lower bound violation: 0                                                                                                                                          
[ 1490.171189] rto: 200 (0 >> 3 + 0, 16) time: 1190171 sent: 1190171 pen: 1 
1190571 rem: 200                                                                                     
[ 1490.171312] lower bound violation: 0                                                                                                                                          
[ 1490.171361] rto: 200 (0 >> 3 + 0, 15) time: 1190171 sent: 1190171 pen: 1 
1190371 rem: 200                                                                                     
[ 1494.052047] lower bound violation: 0                                                                                                                                          
[ 1494.052105] rto: 200 (0 >> 3 + 0, 18) time: 1194052 sent: 1193171 pen: 1 
1196371 rem: 0                                                                                       
[ 1494.052704] lower bound violation: 0                                                                                                                                          
[ 1494.052760] rto: 200 (0 >> 3 + 0, 18) time: 1194052 sent: 1194052 pen: 1 
1194452 rem: 200                                                                                     
[ 1497.678945] lower bound violation: 0                                                                                                                                          
[ 1497.679004] rto: 200 (0 >> 3 + 0, 21) time: 1197678 sent: 1197052 pen: 1 
1200252 rem: 0                                                                                       
[ 1497.679205] lower bound violation: 0                                                                                                                                          
[ 1497.679255] rto: 200 (0 >> 3 + 0, 21) time: 1197679 sent: 1197679 pen: 1 
1198079 rem: 200                                                                                     
[ 1497.679356] rto: 120000 (18111 >> 3 + 2633, 7) time: 1197679 sent: 1195423 
pen: 1 1315423 rem: 117744                                                                         
[ 1501.113733] lower bound violation: 0                                                                                                                                          
[ 1501.113786] rto: 200 (0 >> 3 + 0, 24) time: 1201113 sent: 1200679 pen: 1 
1203879 rem: 0                                                                                       
[ 1501.116064] rto: 120000 (17704 >> 3 + 4426, 8) time: 1201116 sent: 1198638 
pen: 1 1318638 rem: 117522                                                                         
[ 1501.116168] lower bound violation: 0                                                                                                                                          
[ 1501.116216] rto: 200 (0 >> 3 + 0, 24) time: 1201116 sent: 1201113 pen: 1 
1201513 rem: 197                                                                                     
[ 1504.165893] lower bound violation: 0                                                                                                                                          
[ 1504.165953] rto: 200 (0 >> 3 + 0, 27) time: 1204165 sent: 1204113 pen: 1 
1207313 rem: 148                                                                                     
[ 1504.168090] lower bound violation: 0                                                                                                                                          
[ 1504.168151] rto: 200 (0 >> 3 + 0, 26) time: 1204168 sent: 1204113 pen: 1 
1204313 rem: 145                                                                                     
[ 1504.168272] lower bound violation: 0                                                                                                                                          
[ 1504.168327] rto: 200 (0 >> 3 + 0, 25) time: 1204168 sent: 1204113 pen: 1 
1204313 rem: 145                                                                                     
[ 1507.280037] lower bound violation: 0                                                                                                                                          
[ 1507.280096] rto: 200 (0 >> 3 + 0, 28) time: 1207280 sent: 1207113 pen: 1 
1210313 rem: 33                                                                                      
[ 1507.280207] lower bound violation: 0                                                                                                                                          
[ 1507.280255] rto: 200 (0 >> 3 + 0, 27) time: 1207280 sent: 1207113 pen: 1 
1207313 rem: 33                                                                                      
[ 1510.974508] lower bound violation: 0                                                                                                                                          
[ 1510.974574] rto: 200 (0 >> 3 + 0, 30) time: 1210974 sent: 1210113 pen: 1 
1213313 rem: 0                                                                                       
[ 1510.974716] lower bound violation: 0                                                                                                                                          
[ 1510.974766] rto: 200 (0 >> 3 + 0, 30) time: 1210974 sent: 1210974 pen: 1 
1211374 rem: 200                                                                                     
[ 1514.436146] lower bound violation: 0                                                                                                                                          
[ 1514.436214] rto: 200 (0 >> 3 + 0, 33) time: 1214436 sent: 1213974 pen: 1 
1217174 rem: 0                                                                                       
[ 1514.436329] lower bound violation: 0                                                                                                                                          
[ 1514.436378] rto: 200 (0 >> 3 + 0, 33) time: 1214436 sent: 1214436 pen: 1 
1214836 rem: 200                                                                                     
[ 1514.436477] lower bound violation: 0                                                                                                                                          
[ 1514.436525] rto: 200 (0 >> 3 + 0, 32) time: 1214436 sent: 1214436 pen: 1 
1214636 rem: 200                                                                                     
[ 1517.516478] lower bound violation: 0                                                                                                                                          
[ 1517.516537] rto: 200 (0 >> 3 + 0, 35) time: 1217516 sent: 1217436 pen: 1 
1220636 rem: 120                                                                                     
[ 1517.520665] lower bound violation: 0                                                                                                                                          
[ 1517.520724] rto: 200 (0 >> 3 + 0, 34) time: 1217520 sent: 1217436 pen: 1 
1217636 rem: 116                                                                                     
[ 1517.520865] lower bound violation: 0                                                                                                                                          
[ 1517.520919] rto: 200 (0 >> 3 + 0, 33) time: 1217520 sent: 1217436 pen: 1 
1217636 rem: 116                                                                                     
[ 1520.579941] lower bound violation: 0                                                                                                                                          
[ 1520.580000] rto: 200 (0 >> 3 + 0, 36) time: 1220579 sent: 1220436 pen: 1 
1223636 rem: 57                                                                                      
[ 1520.580111] lower bound violation: 0                                                                                                                                          
[ 1520.580165] rto: 200 (0 >> 3 + 0, 35) time: 1220580 sent: 1220436 pen: 1 
1220637 rem: 56                                                                                      
[ 1520.580686] lower bound violation: 0                                                                                                                                          
[ 1520.580744] rto: 200 (0 >> 3 + 0, 34) time: 1220580 sent: 1220436 pen: 1 
1220636 rem: 56                                                                                      
[ 1523.693352] lower bound violation: 0                                                                                                                                          
[ 1523.693412] rto: 200 (0 >> 3 + 0, 37) time: 1223693 sent: 1223436 pen: 1 
1226636 rem: 0                                                                                       
[ 1523.693538] lower bound violation: 0                                                                                                                                          
[ 1523.693588] rto: 200 (0 >> 3 + 0, 37) time: 1223693 sent: 1223693 pen: 1 
1224093 rem: 200                                                                                     
[ 1523.693686] lower bound violation: 0                                                                                                                                          
[ 1523.693735] rto: 200 (0 >> 3 + 0, 36) time: 1223693 sent: 1223693 pen: 1 
1223893 rem: 200                                                                                     
[ 1526.737059] lower bound violation: 0                                                                                                                                          
[ 1526.737125] rto: 200 (0 >> 3 + 0, 39) time: 1226737 sent: 1226693 pen: 1 
1229893 rem: 156                                                                                     
[ 1526.737271] lower bound violation: 0                                                                                                                                          
[ 1526.737323] rto: 200 (0 >> 3 + 0, 38) time: 1226737 sent: 1226693 pen: 1 
1226893 rem: 156                                                                                     
[ 1526.737557] lower bound violation: 0                                                                                                                                          
[ 1526.737607] rto: 200 (0 >> 3 + 0, 37) time: 1226737 sent: 1226693 pen: 1 
1226893 rem: 156                                                                                     
[ 1529.979070] lower bound violation: 0                                                                                                                                          
[ 1529.979130] rto: 200 (0 >> 3 + 0, 40) time: 1229979 sent: 1229693 pen: 1 
1232893 rem: 0                                                                                       
[ 1529.979249] lower bound violation: 0                                                                                                                                          
[ 1529.979304] rto: 200 (0 >> 3 + 0, 40) time: 1229979 sent: 1229979 pen: 1 
1230379 rem: 200                                                                                     
[ 1529.979412] lower bound violation: 0                                                                                                                                          
[ 1529.979461] rto: 200 (0 >> 3 + 0, 39) time: 1229979 sent: 1229979 pen: 1 
1230179 rem: 200                                                                                     
[ 1533.211875] lower bound violation: 0                                                                                                                                          
[ 1533.211934] rto: 200 (0 >> 3 + 0, 42) time: 1233211 sent: 1232979 pen: 1 
1236179 rem: 0                                                                                       
[ 1533.212049] lower bound violation: 0                                                                                                                                          
[ 1533.212098] rto: 200 (0 >> 3 + 0, 42) time: 1233211 sent: 1233211 pen: 1 
1233611 rem: 200                                                                                     
[ 1533.212203] lower bound violation: 0                                                                                                                                          
[ 1533.212259] rto: 200 (0 >> 3 + 0, 41) time: 1233212 sent: 1233211 pen: 1 
1233412 rem: 199                                                                                     
[ 1536.287558] lower bound violation: 0                                                                                                                                          
[ 1536.287611] rto: 200 (0 >> 3 + 0, 44) time: 1236287 sent: 1236211 pen: 1 
1239411 rem: 124                                                                                     
[ 1536.287712] lower bound violation: 0                                                                                                                                          
[ 1536.287760] rto: 200 (0 >> 3 + 0, 43) time: 1236287 sent: 1236211 pen: 1 
1236411 rem: 124                                                                                     
[ 1536.291704] lower bound violation: 0                                                                                                                                          
[ 1536.291767] rto: 200 (0 >> 3 + 0, 42) time: 1236291 sent: 1236211 pen: 1 
1236411 rem: 120                                                                                     
[ 1539.530596] lower bound violation: 0                                                                                                                                          
[ 1539.530657] rto: 200 (0 >> 3 + 0, 45) time: 1239530 sent: 1239211 pen: 1 
1242411 rem: 0                                                                                       
[ 1539.530804] lower bound violation: 0                                                                                                                                          
[ 1539.530862] rto: 200 (0 >> 3 + 0, 45) time: 1239530 sent: 1239530 pen: 1 
1239930 rem: 200                                                                                     
[ 1544.020855] lower bound violation: 0                                                                                                                                          
[ 1544.020916] rto: 200 (0 >> 3 + 0, 48) time: 1244020 sent: 1242530 pen: 1 
1245730 rem: 0                                                                                       
[ 1544.021022] lower bound violation: 0                                                                                                                                          
[ 1544.021071] rto: 200 (0 >> 3 + 0, 48) time: 1244021 sent: 1244020 pen: 1 
1244421 rem: 199                                                                                     
[ 1544.021186] lower bound violation: 0                                                                                                                                          
[ 1544.021243] rto: 200 (0 >> 3 + 0, 47) time: 1244021 sent: 1244020 pen: 1 
1244220 rem: 199                                                                                     
[ 1547.214143] lower bound violation: 0                                                                                                                                          
[ 1547.214212] rto: 200 (0 >> 3 + 0, 50) time: 1247214 sent: 1247020 pen: 1 
1250220 rem: 6                                                                                       
[ 1547.214330] lower bound violation: 0                                                                                                                                          
[ 1547.214388] rto: 200 (0 >> 3 + 0, 49) time: 1247214 sent: 1247020 pen: 1 
1247220 rem: 6                                                                                       
[ 1547.215213] lower bound violation: 0                                                                                                                                          
[ 1547.215269] rto: 200 (0 >> 3 + 0, 48) time: 1247215 sent: 1247020 pen: 1 
1247221 rem: 5                                                                                       
[ 1551.820989] lower bound violation: 0                                                                                                                                          
[ 1551.821059] rto: 200 (0 >> 3 + 0, 51) time: 1251821 sent: 1250020 pen: 1 
1253220 rem: 0                                                                                       
[ 1551.821211] lower bound violation: 0                                                                                                                                          
[ 1551.821265] rto: 200 (0 >> 3 + 0, 51) time: 1251821 sent: 1251821 pen: 1 
1252221 rem: 200                                                                                     
[ 1551.824378] lower bound violation: 0                                                                                                                                          
[ 1551.824437] rto: 200 (0 >> 3 + 0, 50) time: 1251824 sent: 1251821 pen: 1 
1252021 rem: 197                                                                                     
[ 1556.833941] lower bound violation: 0                                                                                                                                          
[ 1556.834001] rto: 200 (0 >> 3 + 0, 53) time: 1256833 sent: 1254821 pen: 1 
1258021 rem: 0                                                                                       
[ 1556.834120] lower bound violation: 0                                                                                                                                          
[ 1556.834168] rto: 200 (0 >> 3 + 0, 53) time: 1256834 sent: 1256834 pen: 1 
1257234 rem: 200                                                                                     
[ 1556.834280] lower bound violation: 0                                                                                                                                          
[ 1556.834335] rto: 200 (0 >> 3 + 0, 52) time: 1256834 sent: 1256834 pen: 1 
1257034 rem: 200                                                                                     
[ 1559.862274] lower bound violation: 0                                                                                                                                          
[ 1559.862332] rto: 200 (0 >> 3 + 0, 55) time: 1259862 sent: 1259834 pen: 1 
1263034 rem: 172                                                                                     
[ 1559.862439] lower bound violation: 0                                                                                                                                          
[ 1559.862488] rto: 200 (0 >> 3 + 0, 54) time: 1259862 sent: 1259834 pen: 1 
1260034 rem: 172                                                                                     
[ 1559.862599] lower bound violation: 0                                                                                                                                          
[ 1559.862653] rto: 200 (0 >> 3 + 0, 53) time: 1259862 sent: 1259834 pen: 1 
1260034 rem: 172                                                                                     
[ 1563.299323] lower bound violation: 0                                                                                                                                          
[ 1563.299392] rto: 200 (0 >> 3 + 0, 56) time: 1263299 sent: 1262834 pen: 1 
1266034 rem: 0                                                                                       
[ 1563.299544] lower bound violation: 0                                                                                                                                          
[ 1563.299593] rto: 200 (0 >> 3 + 0, 56) time: 1263299 sent: 1263299 pen: 1 
1263699 rem: 200                                                                                     
[ 1563.299692] lower bound violation: 0                                                                                                                                          
[ 1563.299740] rto: 200 (0 >> 3 + 0, 55) time: 1263299 sent: 1263299 pen: 1 
1263499 rem: 200                                                                                     
[ 1566.413518] lower bound violation: 0                                                                                                                                          
[ 1566.413571] rto: 200 (0 >> 3 + 0, 58) time: 1266413 sent: 1266299 pen: 1 
1269499 rem: 86                                                                                      
[ 1566.413689] lower bound violation: 0                                                                                                                                          
[ 1566.413745] rto: 200 (0 >> 3 + 0, 57) time: 1266413 sent: 1266299 pen: 1 
1266499 rem: 86                                                                                      
[ 1566.413844] lower bound violation: 0                                                                                                                                          
[ 1566.413892] rto: 200 (0 >> 3 + 0, 56) time: 1266413 sent: 1266299 pen: 1 
1266499 rem: 86                                                                                      
[ 1569.443770] lower bound violation: 0                                                                                                                                          
[ 1569.443829] rto: 200 (0 >> 3 + 0, 59) time: 1269443 sent: 1269299 pen: 1 
1272499 rem: 56                                                                                      
[ 1569.444010] lower bound violation: 0                                                                                                                                          
[ 1569.444064] rto: 200 (0 >> 3 + 0, 58) time: 1269444 sent: 1269299 pen: 1 
1269499 rem: 55                                                                                      
[ 1569.451656] lower bound violation: 0                                                                                                                                          
[ 1569.451714] rto: 200 (0 >> 3 + 0, 57) time: 1269451 sent: 1269299 pen: 1 
1269499 rem: 48                                                                                      
[ 1573.751979] lower bound violation: 0                                                                                                                                          
[ 1573.752048] rto: 200 (0 >> 3 + 0, 60) time: 1273752 sent: 1272299 pen: 1 
1275499 rem: 0                                                                                       
[ 1573.752172] lower bound violation: 0                                                                                                                                          
[ 1573.752229] rto: 200 (0 >> 3 + 0, 60) time: 1273752 sent: 1273752 pen: 1 
1274152 rem: 200                                                                                     
[ 1573.752343] lower bound violation: 0                                                                                                                                          
[ 1573.752392] rto: 200 (0 >> 3 + 0, 59) time: 1273752 sent: 1273752 pen: 1 
1273952 rem: 200                                                                                     
[ 1579.041006] lower bound violation: 0                                                                                                                                          
[ 1579.041068] rto: 200 (0 >> 3 + 0, 62) time: 1279041 sent: 1276752 pen: 1 
1279952 rem: 0                                                                                       
[ 1579.041177] lower bound violation: 0                                                                                                                                          
[ 1579.041226] rto: 200 (0 >> 3 + 0, 62) time: 1279041 sent: 1279041 pen: 1 
1279441 rem: 200                                                                                     
[ 1579.041325] lower bound violation: 0                                                                                                                                          
[ 1579.041373] rto: 200 (0 >> 3 + 0, 61) time: 1279041 sent: 1279041 pen: 1 
1279241 rem: 200                                                                                     
[ 1584.072083] lower bound violation: 0                                                                                                                                          
[ 1584.072149] rto: 200 (0 >> 3 + 0, 64) time: 1284072 sent: 1282041 pen: 1 
1285241 rem: 0                                                                                       
[ 1587.094402] lower bound violation: 0                                                                                                                                          
[ 1587.094461] rto: 200 (0 >> 3 + 0, 67) time: 1287094 sent: 1286872 pen: 1 
1290072 rem: 0                                                                                       
[ 1587.095380] lower bound violation: 0                                                                                                                                          
[ 1587.095442] rto: 200 (0 >> 3 + 0, 67) time: 1287095 sent: 1287094 pen: 1 
1287494 rem: 199                                                                                     
[ 1590.118759] lower bound violation: 0                                                                                                                                          
[ 1590.118818] rto: 200 (0 >> 3 + 0, 70) time: 1290118 sent: 1290094 pen: 1 
1293294 rem: 176                                                                                     
[ 1590.118931] lower bound violation: 0                                                                                                                                          
[ 1590.118979] rto: 200 (0 >> 3 + 0, 69) time: 1290118 sent: 1290094 pen: 1 
1290294 rem: 176                                                                                     
[ 1590.119085] lower bound violation: 0                                                                                                                                          
[ 1590.119142] rto: 200 (0 >> 3 + 0, 68) time: 1290119 sent: 1290094 pen: 1 
1290295 rem: 175                                                                                     
[ 1593.342497] lower bound violation: 0                                                                                                                                          
[ 1593.342556] rto: 200 (0 >> 3 + 0, 71) time: 1293342 sent: 1293094 pen: 1 
1296294 rem: 0                                                                                       
[ 1593.342675] lower bound violation: 0                                                                                                                                          
[ 1593.342723] rto: 200 (0 >> 3 + 0, 71) time: 1293342 sent: 1293342 pen: 1 
1293742 rem: 200                                                                                     
[ 1593.342822] lower bound violation: 0                                                                                                                                          
[ 1593.342870] rto: 200 (0 >> 3 + 0, 70) time: 1293342 sent: 1293342 pen: 1 
1293542 rem: 200                                                                                     
[ 1597.517273] lower bound violation: 0                                                                                                                                          
[ 1597.517326] rto: 200 (0 >> 3 + 0, 73) time: 1297517 sent: 1296342 pen: 1 
1299542 rem: 0                                                                                       
[ 1597.517433] lower bound violation: 0                                                                                                                                          
[ 1597.517481] rto: 200 (0 >> 3 + 0, 73) time: 1297517 sent: 1297517 pen: 1 
1297917 rem: 200                                                                                     
[ 1597.517579] lower bound violation: 0                                                                                                                                          
[ 1597.517627] rto: 200 (0 >> 3 + 0, 72) time: 1297517 sent: 1297517 pen: 1 
1297717 rem: 200                                                                                     
[ 1600.931564] lower bound violation: 0                                                                                                                                          
[ 1600.931625] rto: 200 (0 >> 3 + 0, 75) time: 1300931 sent: 1300517 pen: 1 
1303717 rem: 0                                                                                       
[ 1600.931743] lower bound violation: 0                                                                                                                                          
[ 1600.931792] rto: 200 (0 >> 3 + 0, 75) time: 1300931 sent: 1300931 pen: 1 
1301331 rem: 200                                                                                     
[ 1600.931903] lower bound violation: 0                                                                                                                                          
[ 1600.931954] rto: 200 (0 >> 3 + 0, 74) time: 1300931 sent: 1300931 pen: 1 
1301131 rem: 200                                                                                     
[ 1603.939116] lower bound violation: 0                                                                                                                                          
[ 1603.939176] rto: 200 (0 >> 3 + 0, 77) time: 1303939 sent: 1303932 pen: 1 
1307132 rem: 193                                                                                     
[ 1603.939289] lower bound violation: 0                                                                                                                                          
[ 1603.939337] rto: 200 (0 >> 3 + 0, 76) time: 1303939 sent: 1303932 pen: 1 
1304132 rem: 193                                                                                     
[ 1603.939436] lower bound violation: 0                                                                                                                                          
[ 1603.939484] rto: 200 (0 >> 3 + 0, 75) time: 1303939 sent: 1303932 pen: 1 
1304132 rem: 193                                                                                     
[ 1607.414745] lower bound violation: 0                                                                                                                                          
[ 1607.414808] rto: 200 (0 >> 3 + 0, 78) time: 1307414 sent: 1306932 pen: 1 
1310132 rem: 0                                                                                       
[ 1607.414956] lower bound violation: 0                                                                                                                                          
[ 1607.415015] rto: 200 (0 >> 3 + 0, 78) time: 1307414 sent: 1307414 pen: 1 
1307814 rem: 200                                                                                     
[ 1610.428738] lower bound violation: 0                                                                                                                                          
[ 1610.428797] rto: 200 (0 >> 3 + 0, 81) time: 1310428 sent: 1310414 pen: 1 
1313614 rem: 186                                                                                     
[ 1610.428909] lower bound violation: 0                                                                                                                                          
[ 1610.428957] rto: 200 (0 >> 3 + 0, 80) time: 1310428 sent: 1310414 pen: 1 
1310614 rem: 186                                                                                     
[ 1610.429061] lower bound violation: 0                                                                                                                                          
[ 1610.429118] rto: 200 (0 >> 3 + 0, 79) time: 1310428 sent: 1310414 pen: 1 
1310614 rem: 186                                                                                     
[ 1613.744633] lower bound violation: 0                                                                                                                                          
[ 1613.744696] rto: 200 (0 >> 3 + 0, 82) time: 1313744 sent: 1313415 pen: 1 
1316615 rem: 0                                                                                       
[ 1613.745417] lower bound violation: 0                                                                                                                                          
[ 1613.745480] rto: 200 (0 >> 3 + 0, 82) time: 1313745 sent: 1313744 pen: 1 
1314144 rem: 199                                                                                     
[ 1617.868468] lower bound violation: 0                                                                                                                                          
[ 1617.868531] rto: 200 (0 >> 3 + 0, 85) time: 1317868 sent: 1316744 pen: 1 
1319944 rem: 0                                                                                       
[ 1617.868657] lower bound violation: 0                                                                                                                                          
[ 1617.868716] rto: 200 (0 >> 3 + 0, 85) time: 1317868 sent: 1317868 pen: 1 
1318268 rem: 200                                                                                     
[ 1617.868831] rto: 120000 (18111 >> 3 + 2633, 7) time: 1317868 sent: 1315423 
pen: 1 1435423 rem: 117555                                                                         
[ 1621.001005] lower bound violation: 0                                                                                                                                          
[ 1621.001064] rto: 200 (0 >> 3 + 0, 88) time: 1321000 sent: 1320868 pen: 1 
1324068 rem: 68                                                                                      
[ 1621.001176] lower bound violation: 0                                                                                                                                          
[ 1621.001225] rto: 200 (0 >> 3 + 0, 87) time: 1321000 sent: 1320868 pen: 1 
1321068 rem: 68                                                                                      
[ 1621.002106] rto: 120000 (17704 >> 3 + 4426, 8) time: 1321002 sent: 1318638 
pen: 1 1438638 rem: 117636                                                                         
[ 1624.776425] lower bound violation: 0                                                                                                                                          
[ 1624.776484] rto: 200 (0 >> 3 + 0, 90) time: 1324776 sent: 1323868 pen: 1 
1327068 rem: 0                                                                                       
[ 1624.776602] lower bound violation: 0                                                                                                                                          
[ 1624.776651] rto: 200 (0 >> 3 + 0, 90) time: 1324776 sent: 1324776 pen: 1 
1325176 rem: 200                                                                                     
[ 1624.776766] lower bound violation: 0                                                                                                                                          
[ 1624.776815] rto: 200 (0 >> 3 + 0, 89) time: 1324776 sent: 1324776 pen: 1 
1324976 rem: 200                                                                                     
[ 1628.635107] lower bound violation: 0                                                                                                                                          
[ 1628.635166] rto: 200 (0 >> 3 + 0, 92) time: 1328635 sent: 1327776 pen: 1 
1330976 rem: 0                                                                                       
[ 1628.635292] lower bound violation: 0                                                                                                                                          
[ 1628.635340] rto: 200 (0 >> 3 + 0, 92) time: 1328635 sent: 1328635 pen: 1 
1329035 rem: 200                                                                                     
[ 1628.636141] lower bound violation: 0                                                                                                                                          
[ 1628.636189] rto: 200 (0 >> 3 + 0, 91) time: 1328636 sent: 1328635 pen: 1 
1328836 rem: 199                                                                                     
[ 1632.229674] lower bound violation: 0                                                                                                                                          
[ 1632.229736] rto: 200 (0 >> 3 + 0, 94) time: 1332229 sent: 1331635 pen: 1 
1334835 rem: 0                                                                                       
[ 1632.231588] lower bound violation: 0                                                                                                                                          
[ 1632.231645] rto: 200 (0 >> 3 + 0, 94) time: 1332231 sent: 1332229 pen: 1 
1332629 rem: 198                                                                                     
[ 1636.335644] lower bound violation: 0                                                                                                                                          
[ 1636.335704] rto: 200 (0 >> 3 + 0, 97) time: 1336335 sent: 1335229 pen: 1 
1338429 rem: 0                                                                                       
[ 1636.335821] lower bound violation: 0                                                                                                                                          
[ 1636.335870] rto: 200 (0 >> 3 + 0, 97) time: 1336335 sent: 1336335 pen: 1 
1336735 rem: 200                                                                                     
[ 1636.335968] lower bound violation: 0                                                                                                                                          
[ 1636.336015] rto: 200 (0 >> 3 + 0, 96) time: 1336335 sent: 1336335 pen: 1 
1336535 rem: 200                                                                                     
[ 1639.557760] lower bound violation: 0                                                                                                                                          
[ 1639.557819] rto: 200 (0 >> 3 + 0, 99) time: 1339557 sent: 1339336 pen: 1 
1342536 rem: 0                                                                                       
[ 1639.557937] lower bound violation: 0                                                                                                                                          
[ 1639.557985] rto: 200 (0 >> 3 + 0, 99) time: 1339557 sent: 1339557 pen: 1 
1339957 rem: 200                                                                                     
[ 1639.558575] lower bound violation: 0                                                                                                                                          
[ 1639.558631] rto: 200 (0 >> 3 + 0, 98) time: 1339558 sent: 1339557 pen: 1 
1339758 rem: 199                                                                                     
[ 1642.786990] lower bound violation: 0                                                                                                                                          
[ 1642.787060] rto: 200 (0 >> 3 + 0, 101) time: 1342787 sent: 1342557 pen: 1 
1345757 rem: 0                                                                                      
[ 1642.787238] lower bound violation: 0                                                                                                                                          
[ 1642.787296] rto: 200 (0 >> 3 + 0, 101) time: 1342787 sent: 1342787 pen: 1 
1343187 rem: 200                                                                                    
[ 1642.787395] lower bound violation: 0                                                                                                                                          
[ 1642.787444] rto: 200 (0 >> 3 + 0, 100) time: 1342787 sent: 1342787 pen: 1 
1342987 rem: 200                                                                                    
[ 1647.154582] lower bound violation: 0                                                                                                                                          
[ 1647.154634] rto: 200 (0 >> 3 + 0, 103) time: 1347154 sent: 1345787 pen: 1 
1348987 rem: 0                                                                                      
[ 1647.154744] lower bound violation: 0                                                                                                                                          
[ 1647.154792] rto: 200 (0 >> 3 + 0, 103) time: 1347154 sent: 1347154 pen: 1 
1347554 rem: 200                                                                                    
[ 1647.154904] lower bound violation: 0                                                                                                                                          
[ 1647.154952] rto: 200 (0 >> 3 + 0, 102) time: 1347154 sent: 1347154 pen: 1 
1347354 rem: 200                                                                                    
[ 1650.574345] lower bound violation: 0                                                                                                                                          
[ 1650.574406] rto: 200 (0 >> 3 + 0, 105) time: 1350574 sent: 1350155 pen: 1 
1353355 rem: 0                                                                                      
[ 1650.574532] lower bound violation: 0                                                                                                                                          
[ 1650.574591] rto: 200 (0 >> 3 + 0, 105) time: 1350574 sent: 1350574 pen: 1 
1350974 rem: 200                                                                                    
[ 1650.574691] lower bound violation: 0                                                                                                                                          
[ 1650.574739] rto: 200 (0 >> 3 + 0, 104) time: 1350574 sent: 1350574 pen: 1 
1350774 rem: 200                                                                                    
[ 1653.629874] lower bound violation: 0                                                                                                                                          
[ 1653.629937] rto: 200 (0 >> 3 + 0, 107) time: 1353629 sent: 1353574 pen: 1 
1356774 rem: 145                                                                                    
[ 1653.630037] lower bound violation: 0                                                                                                                                          
[ 1653.630086] rto: 200 (0 >> 3 + 0, 106) time: 1353629 sent: 1353574 pen: 1 
1353774 rem: 145                                                                                    
[ 1653.630185] lower bound violation: 0                                                                                                                                          
[ 1653.630233] rto: 200 (0 >> 3 + 0, 105) time: 1353629 sent: 1353574 pen: 1 
1353774 rem: 145                                                                                    
[ 1656.859174] lower bound violation: 0                                                                                                                                          
[ 1656.859236] rto: 200 (0 >> 3 + 0, 108) time: 1356859 sent: 1356574 pen: 1 
1359774 rem: 0                                                                                      
[ 1656.860594] lower bound violation: 0                                                                                                                                          
[ 1656.860650] rto: 200 (0 >> 3 + 0, 108) time: 1356860 sent: 1356859 pen: 1 
1357259 rem: 199                                                                                    
[ 1656.860770] lower bound violation: 0                                                                                                                                          
[ 1656.860818] rto: 200 (0 >> 3 + 0, 107) time: 1356860 sent: 1356859 pen: 1 
1357059 rem: 199                                                                                    
[ 1661.395294] lower bound violation: 0                                                                                                                                          
[ 1661.395347] rto: 200 (0 >> 3 + 0, 110) time: 1361395 sent: 1359859 pen: 1 
1363059 rem: 0                                                                                      
[ 1661.395716] lower bound violation: 0                                                                                                                                          
[ 1661.395772] rto: 200 (0 >> 3 + 0, 110) time: 1361395 sent: 1361395 pen: 1 
1361795 rem: 200                                                                                    
[ 1700.995078] rto: 120000 (2636 >> 3 + 542, 8) time: 1400995 sent: 1397985 
pen: 1 1517985 rem: 116990                                                                           
[ 1730.706641] lower bound violation: 0                                                                                                                                          
[ 1730.706700] rto: 200 (0 >> 3 + 0, 7) time: 1430706 sent: 1429991 pen: 1 
1549991 rem: 0                                                                                        
[ 1733.727118] lower bound violation: 0                                                                                                                                          
[ 1733.727186] rto: 200 (0 >> 3 + 0, 10) time: 1433727 sent: 1433506 pen: 1 
1436706 rem: 0                                                                                       
[ 1736.737622] lower bound violation: 0                                                                                                                                          
[ 1736.737674] rto: 200 (0 >> 3 + 0, 13) time: 1436737 sent: 1436527 pen: 1 
1439727 rem: 0                                                                                       
[ 1739.769166] lower bound violation: 0                                                                                                                                          
[ 1739.769219] rto: 200 (0 >> 3 + 0, 16) time: 1439769 sent: 1439537 pen: 1 
1442737 rem: 0                                                                                       
[ 1739.818141] lower bound violation: 0                                                                                                                                          
[ 1739.818197] rto: 200 (0 >> 3 + 0, 16) time: 1439818 sent: 1439769 pen: 1 
1440169 rem: 151                                                                                     
[ 1742.779541] lower bound violation: 0                                                                                                                                          
[ 1742.779610] rto: 200 (0 >> 3 + 0, 19) time: 1442779 sent: 1442769 pen: 1 
1445969 rem: 190                                                                                     
[ 1742.828450] lower bound violation: 0                                                                                                                                          
[ 1742.828509] rto: 200 (0 >> 3 + 0, 18) time: 1442828 sent: 1442769 pen: 1 
1442969 rem: 141                                                                                     
[ 1745.838989] lower bound violation: 0                                                                                                                                          
[ 1745.839059] rto: 200 (0 >> 3 + 0, 21) time: 1445839 sent: 1445769 pen: 1 
1448969 rem: 130                                                                                     
[ 1748.849390] lower bound violation: 0                                                                                                                                          
[ 1748.849450] rto: 200 (0 >> 3 + 0, 24) time: 1448849 sent: 1448769 pen: 1 
1451969 rem: 120                                                                                     
[ 1751.851312] lower bound violation: 0                                                                                                                                          
[ 1751.851371] rto: 200 (0 >> 3 + 0, 27) time: 1451851 sent: 1451769 pen: 1 
1454969 rem: 118                                                                                     
[ 1755.020232] lower bound violation: 0                                                                                                                                          
[ 1755.020294] rto: 200 (0 >> 3 + 0, 30) time: 1455020 sent: 1454769 pen: 1 
1457969 rem: 0                                                                                       
[ 1758.032994] lower bound violation: 0                                                                                                                                          
[ 1758.033065] rto: 200 (0 >> 3 + 0, 33) time: 1458032 sent: 1457820 pen: 1 
1461020 rem: 0                                                                                       
[ 1761.044708] lower bound violation: 0                                                                                                                                          
[ 1761.044766] rto: 200 (0 >> 3 + 0, 36) time: 1461044 sent: 1460833 pen: 1 
1464033 rem: 0                                                                                       
[ 1764.057713] lower bound violation: 0                                                                                                                                          
[ 1764.057773] rto: 200 (0 >> 3 + 0, 39) time: 1464057 sent: 1463844 pen: 1 
1467044 rem: 0                                                                                       
[ 1767.081929] lower bound violation: 0                                                                                                                                          
[ 1767.082002] rto: 200 (0 >> 3 + 0, 42) time: 1467081 sent: 1466857 pen: 1 
1470057 rem: 0                                                                                       
[ 1770.093869] lower bound violation: 0                                                                                                                                          
[ 1770.093928] rto: 200 (0 >> 3 + 0, 45) time: 1470093 sent: 1469882 pen: 1 
1473082 rem: 0                                                                                       
[ 1773.152744] lower bound violation: 0                                                                                                                                          
[ 1773.152796] rto: 200 (0 >> 3 + 0, 48) time: 1473152 sent: 1472893 pen: 1 
1476093 rem: 0                                                                                       
[ 1818.986470] rto: 120000 (2636 >> 3 + 542, 8) time: 1518986 sent: 1517985 
pen: 1 1637985 rem: 118999                                                                           
[ 1939.433063] rto: 120000 (2636 >> 3 + 542, 8) time: 1639432 sent: 1637985 
pen: 1 1757985 rem: 118553                                                                           
[ 2127.032954] lower bound violation: 0                                                                                                                                          
[ 2127.033019] rto: 200 (0 >> 3 + 0, 5) time: 1827033 sent: 1824734 pen: 1 
1944734 rem: 0                                                                                        
[ 2130.198949] lower bound violation: 0                                                                                                                                          
[ 2130.199008] rto: 200 (0 >> 3 + 0, 8) time: 1830198 sent: 1829833 pen: 1 
1833033 rem: 0                                                                                        
[ 2130.199134] lower bound violation: 0                                                                                                                                          
[ 2130.199191] rto: 200 (0 >> 3 + 0, 8) time: 1830199 sent: 1830199 pen: 1 
1830599 rem: 200                                                                                      
[ 2130.199289] lower bound violation: 0                                                                                                                                          
[ 2130.199336] rto: 200 (0 >> 3 + 0, 7) time: 1830199 sent: 1830199 pen: 1 
1830399 rem: 200                                                                                      
[ 2133.313262] lower bound violation: 0                                                                                                                                          
[ 2133.313321] rto: 200 (0 >> 3 + 0, 10) time: 1833313 sent: 1833199 pen: 1 
1836399 rem: 86                                                                                      
[ 2133.313430] lower bound violation: 0                                                                                                                                          
[ 2133.313483] rto: 200 (0 >> 3 + 0, 9) time: 1833313 sent: 1833199 pen: 1 
1833399 rem: 86                                                                                       
[ 2136.355135] lower bound violation: 0                                                                                                                                          
[ 2136.355194] rto: 200 (0 >> 3 + 0, 12) time: 1836355 sent: 1836199 pen: 1 
1839399 rem: 44                                                                                      
[ 2136.355302] lower bound violation: 0                                                                                                                                          
[ 2136.355355] rto: 200 (0 >> 3 + 0, 11) time: 1836355 sent: 1836199 pen: 1 
1836399 rem: 44                                                                                      
[ 2136.355462] lower bound violation: 0                                                                                                                                          
[ 2136.355510] rto: 200 (0 >> 3 + 0, 10) time: 1836355 sent: 1836199 pen: 1 
1836399 rem: 44                                                                                      
[ 2139.336730] lower bound violation: 0                                                                                                                                          
[ 2139.336790] rto: 200 (0 >> 3 + 0, 13) time: 1839336 sent: 1839199 pen: 1 
1842399 rem: 63                                                                                      
[ 2139.336911] lower bound violation: 0                                                                                                                                          
[ 2139.336960] rto: 200 (0 >> 3 + 0, 12) time: 1839336 sent: 1839199 pen: 1 
1839399 rem: 63                                                                                      
[ 2142.603552] lower bound violation: 0                                                                                                                                          
[ 2142.603612] rto: 200 (0 >> 3 + 0, 15) time: 1842603 sent: 1842200 pen: 1 
1845400 rem: 0                                                                                       
[ 2142.603729] lower bound violation: 0                                                                                                                                          
[ 2142.603777] rto: 200 (0 >> 3 + 0, 15) time: 1842603 sent: 1842603 pen: 1 
1843003 rem: 200                                                                                     
[ 2145.821472] lower bound violation: 0                                                                                                                                          
[ 2145.821533] rto: 200 (0 >> 3 + 0, 18) time: 1845821 sent: 1845603 pen: 1 
1848803 rem: 0                                                                                       
[ 2145.821638] lower bound violation: 0                                                                                                                                          
[ 2145.821687] rto: 200 (0 >> 3 + 0, 18) time: 1845821 sent: 1845821 pen: 1 
1846221 rem: 200                                                                                     
[ 2149.113311] lower bound violation: 0                                                                                                                                          
[ 2149.113371] rto: 200 (0 >> 3 + 0, 21) time: 1849113 sent: 1848822 pen: 1 
1852022 rem: 0                                                                                       
[ 2149.124655] lower bound violation: 0                                                                                                                                          
[ 2149.124717] rto: 200 (0 >> 3 + 0, 21) time: 1849124 sent: 1849113 pen: 1 
1849513 rem: 189                                                                                     
[ 2152.214537] lower bound violation: 0                                                                                                                                          
[ 2152.214596] rto: 200 (0 >> 3 + 0, 24) time: 1852214 sent: 1852113 pen: 1 
1855313 rem: 99                                                                                      
[ 2152.214836] lower bound violation: 0                                                                                                                                          
[ 2152.214892] rto: 200 (0 >> 3 + 0, 23) time: 1852214 sent: 1852113 pen: 1 
1852313 rem: 99                                                                                      
[ 2152.216836] lower bound violation: 0                                                                                                                                          
[ 2152.216892] rto: 200 (0 >> 3 + 0, 22) time: 1852216 sent: 1852113 pen: 1 
1852313 rem: 97                                                                                      
[ 2155.212630] lower bound violation: 0                                                                                                                                          
[ 2155.212683] rto: 200 (0 >> 3 + 0, 25) time: 1855212 sent: 1855113 pen: 1 
1858313 rem: 101                                                                                     
[ 2155.271403] lower bound violation: 0                                                                                                                                          
[ 2155.271462] rto: 200 (0 >> 3 + 0, 24) time: 1855271 sent: 1855113 pen: 1 
1855313 rem: 42                                                                                      
[ 2155.271570] lower bound violation: 0                                                                                                                                          
[ 2155.271624] rto: 200 (0 >> 3 + 0, 23) time: 1855271 sent: 1855113 pen: 1 
1855313 rem: 42                                                                                      
[ 2158.247617] lower bound violation: 0                                                                                                                                          
[ 2158.247676] rto: 200 (0 >> 3 + 0, 26) time: 1858247 sent: 1858113 pen: 1 
1861313 rem: 66                                                                                      
[ 2158.308891] lower bound violation: 0                                                                                                                                          
[ 2158.308949] rto: 200 (0 >> 3 + 0, 25) time: 1858308 sent: 1858113 pen: 1 
1858313 rem: 5                                                                                       
[ 2161.267856] lower bound violation: 0                                                                                                                                          
[ 2161.267918] rto: 200 (0 >> 3 + 0, 28) time: 1861267 sent: 1861114 pen: 1 
1864314 rem: 47                                                                                      
[ 2161.268020] lower bound violation: 0                                                                                                                                          
[ 2161.268068] rto: 200 (0 >> 3 + 0, 27) time: 1861268 sent: 1861114 pen: 1 
1861315 rem: 46                                                                                      
[ 2161.268283] lower bound violation: 0                                                                                                                                          
[ 2161.268339] rto: 200 (0 >> 3 + 0, 26) time: 1861268 sent: 1861114 pen: 1 
1861314 rem: 46                                                                                      
[ 2164.483740] lower bound violation: 0                                                                                                                                          
[ 2164.483799] rto: 200 (0 >> 3 + 0, 29) time: 1864483 sent: 1864114 pen: 1 
1867314 rem: 0                                                                                       
[ 2164.485758] lower bound violation: 0                                                                                                                                          
[ 2164.485809] rto: 200 (0 >> 3 + 0, 29) time: 1864485 sent: 1864483 pen: 1 
1864883 rem: 198                                                                                     
[ 2460.739324] rto: 7040 (757 >> 3 + 346, 4) time: 2160739 sent: 2160696 pen: 
1 2174776 rem: 6997                                                                                
[ 2477.769916] rto: 120000 (17147 >> 3 + 1705, 6) time: 2177769 sent: 2174642 
pen: 1 2294642 rem: 116873                                                                         
[ 2484.364919] rto: 69440 (3542 >> 3 + 643, 6) time: 2184364 sent: 2182505 
pen: 1 2302505 rem: 67581                                                                             
[ 2555.105348] rto: 69440 (3542 >> 3 + 643, 6) time: 2255105 sent: 2251946 
pen: 1 2371946 rem: 66281                                                                             
[ 2597.920272] rto: 120000 (17147 >> 3 + 1705, 6) time: 2297920 sent: 2294643 
pen: 1 2414643 rem: 116723                                                                         
[ 2624.616823] rto: 69440 (3542 >> 3 + 643, 6) time: 2324616 sent: 2321386 
pen: 1 2441386 rem: 66210                                                                             
[ 2693.911647] rto: 69440 (3542 >> 3 + 643, 6) time: 2393911 sent: 2390826 
pen: 1 2510826 rem: 66355                                                                             
[ 2763.385982] rto: 69440 (3542 >> 3 + 643, 6) time: 2463385 sent: 2460266 
pen: 1 2580266 rem: 66321                                                                             
[ 2779.512699] rto: 1256 (1556 >> 3 + 434, 1) time: 2479512 sent: 2478219 pen: 
1 2480731 rem: 0                                                                                  
[ 2832.786161] rto: 69440 (3542 >> 3 + 643, 6) time: 2532786 sent: 2529707 
pen: 1 2649707 rem: 66361                                                                             
[ 2851.953268] rto: 120000 (9704 >> 3 + 2426, 7) time: 2551953 sent: 2548934 
pen: 1 2668934 rem: 116981                                                                          
[ 2902.338631] rto: 69440 (3542 >> 3 + 643, 6) time: 2602338 sent: 2599147 
pen: 1 2719147 rem: 66249                                                                             
[ 2957.718611] rto: 120000 (17147 >> 3 + 1705, 8) time: 2657718 sent: 2654643 
pen: 1 2774643 rem: 116925                                                                         
[ 2971.736295] rto: 69440 (3542 >> 3 + 643, 6) time: 2671736 sent: 2668587 
pen: 1 2788587 rem: 66291                                                                             
[ 2972.118479] rto: 120000 (9704 >> 3 + 2426, 7) time: 2672118 sent: 2668934 
pen: 1 2788934 rem: 116816                                                                          
[ 3041.036185] rto: 69440 (3542 >> 3 + 643, 6) time: 2741036 sent: 2738027 
pen: 1 2858027 rem: 66431                                                                             
[ 3091.942676] rto: 120000 (9704 >> 3 + 2426, 7) time: 2791942 sent: 2788934 
pen: 1 2908934 rem: 116992                                                                          
[ 3110.560285] rto: 69440 (3542 >> 3 + 643, 6) time: 2810560 sent: 2807467 
pen: 1 2927467 rem: 66347                                                                             
[ 3180.044502] rto: 69440 (3542 >> 3 + 643, 6) time: 2880044 sent: 2876907 
pen: 1 2996907 rem: 66303                                                                             
[ 3211.952300] rto: 120000 (9704 >> 3 + 2426, 7) time: 2911952 sent: 2908934 
pen: 1 3028934 rem: 116982                                                                          
[ 3288.275909] rto: 120000 (9674 >> 3 + 2484, 9) time: 2988275 sent: 2987173 
pen: 1 3107173 rem: 118898                                                                          
[ 3330.221683] rto: 120000 (200 >> 3 + 200, 13) time: 3030221 sent: 3027658 
pen: 1 3147658 rem: 117437                                                                           
[ 3383.376964] rto: 13296 (1388 >> 3 + 658, 4) time: 3083376 sent: 3082998 
pen: 1 3109590 rem: 12918                                                                             
[ 3408.805976] rto: 120000 (9674 >> 3 + 2484, 9) time: 3108805 sent: 3107174 
pen: 1 3227174 rem: 118369                                                                          
[ 3447.968663] rto: 120000 (200 >> 3 + 200, 13) time: 3147968 sent: 3147658 
pen: 1 3267658 rem: 119690                                                                           
[ 3798.180697] rto: 1482 (1976 >> 3 + 494, 1) time: 3498180 sent: 3497035 pen: 
1 3499999 rem: 337
[ 3798.180827] rto: 741 (1976 >> 3 + 494, 0) time: 3498180 sent: 3497035 pen: 
1 3498517 rem: 0
[ 3801.277029] rto: 1482 (1976 >> 3 + 494, 1) time: 3501276 sent: 3499662 pen: 
1 3502626 rem: 0
[ 3801.277184] rto: 1482 (1976 >> 3 + 494, 1) time: 3501277 sent: 3501277 pen: 
1 3504241 rem: 1482
[ 3804.486861] rto: 1482 (1976 >> 3 + 494, 1) time: 3504486 sent: 3502759 pen: 
1 3505723 rem: 0
[ 3804.487007] rto: 1482 (1976 >> 3 + 494, 1) time: 3504486 sent: 3504486 pen: 
1 3507450 rem: 1482
[ 3812.053012] rto: 2964 (1976 >> 3 + 494, 2) time: 3512052 sent: 3508933 pen: 
1 3514861 rem: 0
[ 3815.238764] rto: 2964 (1976 >> 3 + 494, 2) time: 3515238 sent: 3512053 pen: 
1 3517981 rem: 0
[ 3818.394748] rto: 2964 (1976 >> 3 + 494, 2) time: 3518394 sent: 3515238 pen: 
1 3521166 rem: 0
[ 3821.481936] rto: 2964 (1976 >> 3 + 494, 2) time: 3521481 sent: 3518394 pen: 
1 3524322 rem: 0
[ 3824.873120] rto: 2964 (1976 >> 3 + 494, 2) time: 3524873 sent: 3521482 pen: 
1 3527410 rem: 0
[ 3827.898656] rto: 2964 (1976 >> 3 + 494, 2) time: 3527898 sent: 3524873 pen: 
1 3530801 rem: 0
[ 3830.943112] rto: 2964 (1976 >> 3 + 494, 2) time: 3530943 sent: 3527898 pen: 
1 3533826 rem: 0
[ 3833.974064] rto: 2964 (1976 >> 3 + 494, 2) time: 3533974 sent: 3530943 pen: 
1 3536871 rem: 0
[ 3837.112487] rto: 2964 (1976 >> 3 + 494, 2) time: 3537112 sent: 3533974 pen: 
1 3539902 rem: 0
[ 3840.130296] rto: 2964 (1976 >> 3 + 494, 2) time: 3540130 sent: 3537112 pen: 
1 3543040 rem: 0
[ 3843.191881] rto: 2964 (1976 >> 3 + 494, 2) time: 3543191 sent: 3540130 pen: 
1 3546058 rem: 0
[ 3846.633862] rto: 2964 (1976 >> 3 + 494, 2) time: 3546633 sent: 3543191 pen: 
1 3549119 rem: 0
[ 3849.682215] rto: 2964 (1976 >> 3 + 494, 2) time: 3549682 sent: 3546633 pen: 
1 3552561 rem: 0
[ 3852.728190] rto: 2964 (1976 >> 3 + 494, 2) time: 3552728 sent: 3549682 pen: 
1 3555610 rem: 0
[ 3869.778290] rto: 79136 (14257 >> 3 + 691, 5) time: 3569778 sent: 3564894 
pen: 1 3684894 rem: 74252
[ 3942.001467] rto: 47424 (1976 >> 3 + 494, 6) time: 3642001 sent: 3641648 
pen: 1 3736496 rem: 47071
[ 3948.754452] rto: 79136 (14257 >> 3 + 691, 5) time: 3648754 sent: 3644030 
pen: 1 3764030 rem: 74412
[ 3972.841345] rto: 47168 (1911 >> 3 + 499, 6) time: 3672841 sent: 3672158 
pen: 1 3766494 rem: 46485
[ 3992.364664] rto: 47424 (1976 >> 3 + 494, 6) time: 3692364 sent: 3689072 
pen: 1 3783920 rem: 44132
[ 4019.342183] rto: 47168 (1911 >> 3 + 499, 6) time: 3719342 sent: 3719326 
pen: 1 3813662 rem: 47152
[ 4028.049905] rto: 79136 (14257 >> 3 + 691, 5) time: 3728049 sent: 3723166 
pen: 1 3843166 rem: 74253
[ 4039.530444] rto: 47424 (1976 >> 3 + 494, 6) time: 3739530 sent: 3736496 
pen: 1 3831344 rem: 44390
[ 4067.954752] rto: 47168 (1911 >> 3 + 499, 6) time: 3767954 sent: 3766494 
pen: 1 3860830 rem: 45708
[ 4087.534683] rto: 47424 (1976 >> 3 + 494, 6) time: 3787534 sent: 3783920 
pen: 1 3878768 rem: 43810
[ 4116.817143] rto: 47168 (1911 >> 3 + 499, 6) time: 3816817 sent: 3813662 
pen: 1 3907998 rem: 44013
[ 4134.515420] rto: 47424 (1976 >> 3 + 494, 6) time: 3834515 sent: 3831344 
pen: 1 3926192 rem: 44253
[ 4146.622061] rto: 40592 (3300 >> 3 + 2125, 4) time: 3846622 sent: 3846199 
pen: 1 3927383 rem: 40169
[ 4182.217172] rto: 47424 (1976 >> 3 + 494, 6) time: 3882217 sent: 3878768 
pen: 1 3973616 rem: 43975
[ 4226.387945] rto: 120000 (14257 >> 3 + 691, 6) time: 3926387 sent: 3922303 
pen: 1 4042303 rem: 115916
[ 4228.876327] rto: 85152 (11055 >> 3 + 1280, 5) time: 3928876 sent: 3925792 
pen: 1 4045792 rem: 82068
[ 4229.248393] rto: 47424 (1976 >> 3 + 494, 6) time: 3929248 sent: 3926192 
pen: 1 4021040 rem: 44368
[ 4264.022196] rto: 103072 (11062 >> 3 + 1839, 5) time: 3964022 sent: 3963411 
pen: 1 4083411 rem: 102461
[ 4271.074364] rto: 81184 (3300 >> 3 + 2125, 5) time: 3971074 sent: 3967975 
pen: 1 4087975 rem: 78085
[ 4276.683784] rto: 47424 (1976 >> 3 + 494, 6) time: 3976683 sent: 3973616 
pen: 1 4068464 rem: 44357

^ permalink raw reply

* [PATCH] tcp: fix ICMP-RTO war
From: Ilpo Järvinen @ 2010-01-23 22:34 UTC (permalink / raw)
  To: Denys Fedoryshchenko; +Cc: Damian Lukowski, Netdev, David Miller
In-Reply-To: <201001232337.19122.denys@visp.net.lb>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 3482 bytes --]

Restored Damian cc, please keep them.

On Sat, 23 Jan 2010, Denys Fedoryshchenko wrote:
> On Tuesday 19 January 2010 13:17:51 you wrote:
> > On Tue, 19 Jan 2010, Denys Fedoryshchenko wrote:
> > > On Tuesday 19 January 2010 11:10:12 you wrote:
> > > > Hi,
> > > > thank you for testing. So srtt and rttvar is zero in any of those
> > > > cases. Ilpo, it is a bug in tcp_rtt_estimator then, I suppose?
> > > >
> > > > There is also a code comment in tcp_input.c, saying:
> > > > > * NOTE: clamping at TCP_RTO_MIN is not required, current algo
> > > > > * guarantees that rto is higher.
> > > >
> > > > So we either fix tcp_rtt_estimator or simply clamp at TCP_RTO_MIN?
> > > >
> > > > Damian
> > > >
> > > > > On Monday 11 January 2010 15:02:34 you wrote:
> > > > >> On Sat, 26 Dec 2009, Denys Fedoryshchenko wrote:
> > > > >>> Few more dumps. I notice:
> > > > >>> 1)Ack always equal 1
> > > > >>> 2)It is usually first segment of data sent (?)
> > > > >>>
> > > > >>> Maybe some value not initialised properly?
> > > > >>
> > > > >> Can you see if the RTO lower bound is violated (I added some
> > > > >> printing of vars there too already now if it turns out to be
> > > > >> something):
> > > > >>
> > > > >> diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c
> > > > >> index 65b8ebf..d84469f 100644
> > > > >> --- a/net/ipv4/tcp_ipv4.c
> > > > >> +++ b/net/ipv4/tcp_ipv4.c
> > >
> > > As i see in code it is rounding RTO to minimum value.
> > > It fixes my problem seems.
> > >
> > > Btw just a bit about my environment - wireless networks (sometimes
> > > lossy!) with low speed (128-512Kbps) customers working over pppoe. Maybe
> > > it will give a tip why rtt value is too low.
> > 
> > What I find most strange in it is the fact that when it triggers for the
> > first time, the srtt and mdev are zero, not some value in between 0 and
> > 200ms. Therefore I suspect that this case might be something that we've
> > overlooked where srtt/mdev are not valid at all.
> > 
> > Maybe the patch below helps...
> > 
> Seems after this patch (and debug patch with warnings) my dmesg is clean.

Cool, thanks for testing.

Dave, please send into stable too (besides net-2.6). If we want less strict 
state check we can continue playing with that in net-next, IMHO.

-- 
 i.

--
[PATCH] tcp: fix ICMP-RTO war

When destination is not reachable, ICMP of that is processed
here. In some TCP state srtt and mdev are not valid, yielding
to zero rto. Since the code below then immediately forces
timeout, a segment is sent which again triggers another ICMP
causing ICMP-RTO war to happen.

Broken since f1ecd5d9e736660 (Revert Backoff [v3]: Revert RTO
on ICMP destination unreachable).

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Reported-by: Denys Fedoryshchenko <denys@visp.net.lb>
Tested-by: Denys Fedoryshchenko <denys@visp.net.lb>
---
 net/ipv4/tcp_ipv4.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c
index 65b8ebf..ebcfcf6 100644
--- a/net/ipv4/tcp_ipv4.c
+++ b/net/ipv4/tcp_ipv4.c
@@ -401,6 +401,9 @@ void tcp_v4_err(struct sk_buff *icmp_skb, u32 info)
 		 * (see draft-zimmermann-tcp-lcd) */
 		if (code != ICMP_NET_UNREACH && code != ICMP_HOST_UNREACH)
 			break;
+		/* A bit too strict, just want to be on the safe side for now */
+		if (sk->sk_state != TCP_ESTABLISHED)
+			break;
 		if (seq != tp->snd_una  || !icsk->icsk_retransmits ||
 		    !icsk->icsk_backoff)
 			break;
-- 
1.5.6.5

^ permalink raw reply related


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox