From: Adrian Moreno Date: Fri, 11 Aug 2023 14:12:49 +0000 (+0200) Subject: net: openvswitch: add action error drop reason X-Git-Tag: v6.6.17~4098^2~126^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ec7bfb5e5a054f1178e8bdbf4f145fdafa5bf804;p=platform%2Fkernel%2Flinux-rpi.git net: openvswitch: add action error drop reason Add a drop reason for packets that are dropped because an action returns a non-zero error code. Acked-by: Aaron Conole Signed-off-by: Adrian Moreno Signed-off-by: David S. Miller --- diff --git a/net/openvswitch/actions.c b/net/openvswitch/actions.c index 8c8a7a8..bb7aa18 100644 --- a/net/openvswitch/actions.c +++ b/net/openvswitch/actions.c @@ -1488,7 +1488,7 @@ static int do_execute_actions(struct datapath *dp, struct sk_buff *skb, } if (unlikely(err)) { - kfree_skb(skb); + ovs_kfree_skb_reason(skb, OVS_DROP_ACTION_ERROR); return err; } } diff --git a/net/openvswitch/drop.h b/net/openvswitch/drop.h index a5b2b90..b87613c 100644 --- a/net/openvswitch/drop.h +++ b/net/openvswitch/drop.h @@ -10,6 +10,7 @@ #define OVS_DROP_REASONS(R) \ R(OVS_DROP_LAST_ACTION) \ + R(OVS_DROP_ACTION_ERROR) \ /* deliberate comment for trailing \ */ enum ovs_drop_reason {