summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMenglong Dong <menglong8.dong@gmail.com>2024-10-09 05:28:25 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-09-09 19:58:11 +0300
commite89198454fb62bc8b0d8d020e8cf72c2f6bf8352 (patch)
treeac04d80bc8dcd1f79925861f36005b0b6b9c008a /include
parent4ff4f3104da6507e0f118c63c4560dfdeb59dce3 (diff)
downloadlinux-e89198454fb62bc8b0d8d020e8cf72c2f6bf8352.tar.xz
net: vxlan: make vxlan_set_mac() return drop reasons
[ Upstream commit d209706f562ee4fa81bdf24cf6b679c3222aa06c ] Change the return type of vxlan_set_mac() from bool to enum skb_drop_reason. In this commit, the drop reason "SKB_DROP_REASON_LOCAL_MAC" is introduced for the case that the source mac of the packet is a local mac. Signed-off-by: Menglong Dong <dongml2@chinatelecom.cn> Reviewed-by: Simon Horman <horms@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net> Stable-dep-of: 1f5d2fd1ca04 ("vxlan: Fix NPD in {arp,neigh}_reduce() when using nexthop objects") Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include')
-rw-r--r--include/net/dropreason-core.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/net/dropreason-core.h b/include/net/dropreason-core.h
index 1cb8d7c953be..fbf92d442c1b 100644
--- a/include/net/dropreason-core.h
+++ b/include/net/dropreason-core.h
@@ -97,6 +97,7 @@
FN(MAC_INVALID_SOURCE) \
FN(VXLAN_ENTRY_EXISTS) \
FN(IP_TUNNEL_ECN) \
+ FN(LOCAL_MAC) \
FNe(MAX)
/**
@@ -444,6 +445,11 @@ enum skb_drop_reason {
*/
SKB_DROP_REASON_IP_TUNNEL_ECN,
/**
+ * @SKB_DROP_REASON_LOCAL_MAC: the source MAC address is equal to
+ * the MAC address of the local netdev.
+ */
+ SKB_DROP_REASON_LOCAL_MAC,
+ /**
* @SKB_DROP_REASON_MAX: the maximum of core drop reasons, which
* shouldn't be used as a real 'reason' - only for tracing code gen
*/