aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/snmp.h
diff options
context:
space:
mode:
authorTom Herbert <therbert@google.com>2010-04-22 03:00:24 -0400
committerDavid S. Miller <davem@davemloft.net>2010-04-22 19:00:00 -0400
commitaa2ea0586d9dbe56a334d835a43b45e8c2104e77 (patch)
tree1f218166bff8513858ac253e84264a4a8fe9ff0d /include/net/snmp.h
parent3cfa856d6d43894ebffdc28d2f0587595280893b (diff)
tcp: fix outsegs stat for TSO segments
Account for TSO segments of an skb in TCP_MIB_OUTSEGS counter. Without doing this, the counter can be off by orders of magnitude from the actual number of segments sent. Signed-off-by: Tom Herbert <therbert@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/snmp.h')
-rw-r--r--include/net/snmp.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/net/snmp.h b/include/net/snmp.h
index 884fdbb74b23..92456f1035f5 100644
--- a/include/net/snmp.h
+++ b/include/net/snmp.h
@@ -133,6 +133,8 @@ struct linux_xfrm_mib {
133 __this_cpu_add(mib[0]->mibs[field], addend) 133 __this_cpu_add(mib[0]->mibs[field], addend)
134#define SNMP_ADD_STATS_USER(mib, field, addend) \ 134#define SNMP_ADD_STATS_USER(mib, field, addend) \
135 this_cpu_add(mib[1]->mibs[field], addend) 135 this_cpu_add(mib[1]->mibs[field], addend)
136#define SNMP_ADD_STATS(mib, field, addend) \
137 this_cpu_add(mib[0]->mibs[field], addend)
136/* 138/*
137 * Use "__typeof__(*mib[0]) *ptr" instead of "__typeof__(mib[0]) ptr" 139 * Use "__typeof__(*mib[0]) *ptr" instead of "__typeof__(mib[0]) ptr"
138 * to make @ptr a non-percpu pointer. 140 * to make @ptr a non-percpu pointer.