summaryrefslogtreecommitdiffstats
path: root/include/net/dropreason-core.h
diff options
context:
space:
mode:
authorMenglong Dong <menglong8.dong@gmail.com>2024-10-09 04:28:24 +0200
committerDavid S. Miller <davem@davemloft.net>2024-10-13 12:33:09 +0200
commit289fd4e75219a96f77c5d679166035cd5118d139 (patch)
treed76ef7e1f8d018c9d06d6e55c1c07e209db2bfb6 /include/net/dropreason-core.h
parentnet: vxlan: make vxlan_remcsum() return drop reasons (diff)
downloadlinux-289fd4e75219a96f77c5d679166035cd5118d139.tar.xz
linux-289fd4e75219a96f77c5d679166035cd5118d139.zip
net: vxlan: make vxlan_snoop() return drop reasons
Change the return type of vxlan_snoop() from bool to enum skb_drop_reason. In this commit, two drop reasons are introduced: SKB_DROP_REASON_MAC_INVALID_SOURCE SKB_DROP_REASON_VXLAN_ENTRY_EXISTS Signed-off-by: Menglong Dong <dongml2@chinatelecom.cn> Reviewed-by: Simon Horman <horms@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/dropreason-core.h')
-rw-r--r--include/net/dropreason-core.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/net/dropreason-core.h b/include/net/dropreason-core.h
index 98259d2b3e92..1cb8d7c953be 100644
--- a/include/net/dropreason-core.h
+++ b/include/net/dropreason-core.h
@@ -94,6 +94,8 @@
FN(TC_RECLASSIFY_LOOP) \
FN(VXLAN_INVALID_HDR) \
FN(VXLAN_VNI_NOT_FOUND) \
+ FN(MAC_INVALID_SOURCE) \
+ FN(VXLAN_ENTRY_EXISTS) \
FN(IP_TUNNEL_ECN) \
FNe(MAX)
@@ -429,6 +431,13 @@ enum skb_drop_reason {
SKB_DROP_REASON_VXLAN_INVALID_HDR,
/** @SKB_DROP_REASON_VXLAN_VNI_NOT_FOUND: no VXLAN device found for VNI */
SKB_DROP_REASON_VXLAN_VNI_NOT_FOUND,
+ /** @SKB_DROP_REASON_MAC_INVALID_SOURCE: source mac is invalid */
+ SKB_DROP_REASON_MAC_INVALID_SOURCE,
+ /**
+ * @SKB_DROP_REASON_VXLAN_ENTRY_EXISTS: trying to migrate a static
+ * entry or an entry pointing to a nexthop.
+ */
+ SKB_DROP_REASON_VXLAN_ENTRY_EXISTS,
/**
* @SKB_DROP_REASON_IP_TUNNEL_ECN: skb is dropped according to
* RFC 6040 4.2, see __INET_ECN_decapsulate() for detail.