aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi/linux/snmp.h
diff options
context:
space:
mode:
authorMenglong Dong <dong.menglong@zte.com.cn>2020-11-05 20:49:14 -0500
committerJakub Kicinski <kuba@kernel.org>2020-11-09 15:34:44 -0800
commita3ce2b109a59ee9670706ae8126dcc04cfe261cd (patch)
treef048c762ceb333a0d435005cc856704802b58f52 /include/uapi/linux/snmp.h
parentstmmac: intel: change all EHL/TGL to auto detect phy addr (diff)
downloadlinux-dev-a3ce2b109a59ee9670706ae8126dcc04cfe261cd.tar.xz
linux-dev-a3ce2b109a59ee9670706ae8126dcc04cfe261cd.zip
net: udp: introduce UDP_MIB_MEMERRORS for udp_mem
When udp_memory_allocated is at the limit, __udp_enqueue_schedule_skb will return a -ENOBUFS, and skb will be dropped in __udp_queue_rcv_skb without any counters being done. It's hard to find out what happened once this happen. So we introduce a UDP_MIB_MEMERRORS to do this job. Well, this change looks friendly to the existing users, such as netstat: $ netstat -u -s Udp: 0 packets received 639 packets to unknown port received. 158689 packet receive errors 180022 packets sent RcvbufErrors: 20930 MemErrors: 137759 UdpLite: IpExt: InOctets: 257426235 OutOctets: 257460598 InNoECTPkts: 181177 v2: - Fix some alignment problems Signed-off-by: Menglong Dong <dong.menglong@zte.com.cn> Link: https://lore.kernel.org/r/1604627354-43207-1-git-send-email-dong.menglong@zte.com.cn Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'include/uapi/linux/snmp.h')
-rw-r--r--include/uapi/linux/snmp.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/uapi/linux/snmp.h b/include/uapi/linux/snmp.h
index f84e7bcad6de..26fc60ce9298 100644
--- a/include/uapi/linux/snmp.h
+++ b/include/uapi/linux/snmp.h
@@ -159,6 +159,7 @@ enum
UDP_MIB_SNDBUFERRORS, /* SndbufErrors */
UDP_MIB_CSUMERRORS, /* InCsumErrors */
UDP_MIB_IGNOREDMULTI, /* IgnoredMulti */
+ UDP_MIB_MEMERRORS, /* MemErrors */
__UDP_MIB_MAX
};