[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20231216201254.GV6288@kernel.org>
Date: Sat, 16 Dec 2023 20:12:54 +0000
From: Simon Horman <horms@...nel.org>
To: Victor Nogueira <victor@...atatu.com>
Cc: jhs@...atatu.com, xiyou.wangcong@...il.com, jiri@...nulli.us,
davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org,
pabeni@...hat.com, daniel@...earbox.net, dcaratti@...hat.com,
netdev@...r.kernel.org, kernel@...atatu.com
Subject: Re: [PATCH net-next v4 3/3] net: sched: Add initial TC error skb
drop reasons
On Thu, Dec 14, 2023 at 05:35:32PM -0300, Victor Nogueira wrote:
> Continue expanding Daniel's patch by adding new skb drop reasons that
> are idiosyncratic to TC.
>
> More specifically:
>
> - SKB_DROP_REASON_TC_EXT_COOKIE_ERROR: An error occurred whilst
> processing a tc ext cookie.
>
> - SKB_DROP_REASON_TC_CHAIN_NOTFOUND: tc chain lookup failed.
>
> - SKB_DROP_REASON_TC_RECLASSIFY_LOOP: tc exceeded max reclassify loop
> iterations
>
> Signed-off-by: Victor Nogueira <victor@...atatu.com>
> Reviewed-by: Simon Horman <horms@...nel.org>
> ---
> include/net/dropreason-core.h | 18 +++++++++++++++---
> net/sched/act_api.c | 3 ++-
> net/sched/cls_api.c | 22 ++++++++++++++--------
> 3 files changed, 31 insertions(+), 12 deletions(-)
>
> diff --git a/include/net/dropreason-core.h b/include/net/dropreason-core.h
> index 278e4c7d465c..dea361b3555d 100644
> --- a/include/net/dropreason-core.h
> +++ b/include/net/dropreason-core.h
> @@ -85,8 +85,10 @@
> FN(IPV6_NDISC_BAD_OPTIONS) \
> FN(IPV6_NDISC_NS_OTHERHOST) \
> FN(QUEUE_PURGE) \
> - FN(TC_ERROR) \
> + FN(TC_COOKIE_ERROR) \
> FN(PACKET_SOCK_ERROR) \
> + FN(TC_CHAIN_NOTFOUND) \
> + FN(TC_RECLASSIFY_LOOP) \
> FNe(MAX)
>
> /**
> @@ -377,13 +379,23 @@ enum skb_drop_reason {
> SKB_DROP_REASON_IPV6_NDISC_NS_OTHERHOST,
> /** @SKB_DROP_REASON_QUEUE_PURGE: bulk free. */
> SKB_DROP_REASON_QUEUE_PURGE,
> - /** @SKB_DROP_REASON_TC_ERROR: generic internal tc error. */
> - SKB_DROP_REASON_TC_ERROR,
> + /**
> + * @SKB_DROP_REASON_TC_EXT_COOKIE_ERROR: An error occurred whilst
nit: @SKB_DROP_REASON_TC_COOKIE_ERROR
> + * processing a tc ext cookie.
> + */
> + SKB_DROP_REASON_TC_COOKIE_ERROR,
> /**
> * @SKB_DROP_REASON_PACKET_SOCK_ERROR: generic packet socket errors
> * after its filter matches an incoming packet.
> */
> SKB_DROP_REASON_PACKET_SOCK_ERROR,
> + /** @SKB_DROP_REASON_TC_CHAIN_NOTFOUND: tc chain lookup failed. */
> + SKB_DROP_REASON_TC_CHAIN_NOTFOUND,
> + /**
> + * @SKB_DROP_REASON_TC_RECLASSIFY_LOOP: tc exceeded max reclassify loop
> + * iterations.
> + */
> + SKB_DROP_REASON_TC_RECLASSIFY_LOOP,
> /**
> * @SKB_DROP_REASON_MAX: the maximum of core drop reasons, which
> * shouldn't be used as a real 'reason' - only for tracing code gen
...
Powered by blists - more mailing lists