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>
This commit is contained in:
committed by
David S. Miller
parent
3cfa856d6d
commit
aa2ea0586d
@ -133,6 +133,8 @@ struct linux_xfrm_mib {
|
||||
__this_cpu_add(mib[0]->mibs[field], addend)
|
||||
#define SNMP_ADD_STATS_USER(mib, field, addend) \
|
||||
this_cpu_add(mib[1]->mibs[field], addend)
|
||||
#define SNMP_ADD_STATS(mib, field, addend) \
|
||||
this_cpu_add(mib[0]->mibs[field], addend)
|
||||
/*
|
||||
* Use "__typeof__(*mib[0]) *ptr" instead of "__typeof__(mib[0]) ptr"
|
||||
* to make @ptr a non-percpu pointer.
|
||||
|
Reference in New Issue
Block a user