Re: [PATCH net-next] net: skb: export skb drop reaons to user by TRACE_DEFINE_ENUM
From: Jakub Kicinski
Date: Thu Sep 01 2022 - 17:13:06 EST
On Thu, 1 Sep 2022 23:23:39 +0800 menglong8.dong@xxxxxxxxx wrote:
> +#undef FN
> +#define FN(reason) [SKB_DROP_REASON_##reason] = #reason,
> +const char * const drop_reasons[] = {
> + DEFINE_DROP_REASON(FN, FN)
> +};
The undef looks a little backwards, no? We don't want to pollute all
users of skbuff.h with a FN define.
#define FN....
/* use it */
#undef FN