Skip to content

Commit 46e0ccf

Browse files
rrendeckuba-moo
authored andcommitted
net: vxlan: rename SKB_DROP_REASON_VXLAN_NO_REMOTE
The SKB_DROP_REASON_VXLAN_NO_REMOTE skb drop reason was introduced in the specific context of vxlan. As it turns out, there are similar cases when a packet needs to be dropped in other parts of the network stack, such as the bridge module. Rename SKB_DROP_REASON_VXLAN_NO_REMOTE and give it a more generic name, so that it can be used in other parts of the network stack. This is not a functional change, and the numeric value of the drop reason even remains unchanged. Signed-off-by: Radu Rendec <[email protected]> Reviewed-by: Ido Schimmel <[email protected]> Acked-by: Nikolay Aleksandrov <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 6ad7f71 commit 46e0ccf

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

drivers/net/vxlan/vxlan_core.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2798,7 +2798,7 @@ static netdev_tx_t vxlan_xmit(struct sk_buff *skb, struct net_device *dev)
27982798
dev_dstats_tx_dropped(dev);
27992799
vxlan_vnifilter_count(vxlan, vni, NULL,
28002800
VXLAN_VNI_STATS_TX_DROPS, 0);
2801-
kfree_skb_reason(skb, SKB_DROP_REASON_VXLAN_NO_REMOTE);
2801+
kfree_skb_reason(skb, SKB_DROP_REASON_NO_TX_TARGET);
28022802
return NETDEV_TX_OK;
28032803
}
28042804
}
@@ -2821,7 +2821,7 @@ static netdev_tx_t vxlan_xmit(struct sk_buff *skb, struct net_device *dev)
28212821
if (fdst)
28222822
vxlan_xmit_one(skb, dev, vni, fdst, did_rsc);
28232823
else
2824-
kfree_skb_reason(skb, SKB_DROP_REASON_VXLAN_NO_REMOTE);
2824+
kfree_skb_reason(skb, SKB_DROP_REASON_NO_TX_TARGET);
28252825
}
28262826

28272827
return NETDEV_TX_OK;

drivers/net/vxlan/vxlan_mdb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1712,7 +1712,7 @@ netdev_tx_t vxlan_mdb_xmit(struct vxlan_dev *vxlan,
17121712
vxlan_xmit_one(skb, vxlan->dev, src_vni,
17131713
rcu_dereference(fremote->rd), false);
17141714
else
1715-
kfree_skb_reason(skb, SKB_DROP_REASON_VXLAN_NO_REMOTE);
1715+
kfree_skb_reason(skb, SKB_DROP_REASON_NO_TX_TARGET);
17161716

17171717
return NETDEV_TX_OK;
17181718
}

include/net/dropreason-core.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@
106106
FN(VXLAN_VNI_NOT_FOUND) \
107107
FN(MAC_INVALID_SOURCE) \
108108
FN(VXLAN_ENTRY_EXISTS) \
109-
FN(VXLAN_NO_REMOTE) \
109+
FN(NO_TX_TARGET) \
110110
FN(IP_TUNNEL_ECN) \
111111
FN(TUNNEL_TXINFO) \
112112
FN(LOCAL_MAC) \
@@ -497,8 +497,8 @@ enum skb_drop_reason {
497497
* entry or an entry pointing to a nexthop.
498498
*/
499499
SKB_DROP_REASON_VXLAN_ENTRY_EXISTS,
500-
/** @SKB_DROP_REASON_VXLAN_NO_REMOTE: no remote found for xmit */
501-
SKB_DROP_REASON_VXLAN_NO_REMOTE,
500+
/** @SKB_DROP_REASON_NO_TX_TARGET: no target found for xmit */
501+
SKB_DROP_REASON_NO_TX_TARGET,
502502
/**
503503
* @SKB_DROP_REASON_IP_TUNNEL_ECN: skb is dropped according to
504504
* RFC 6040 4.2, see __INET_ECN_decapsulate() for detail.

0 commit comments

Comments
 (0)