Re: [PATCH net-next v2 2/3] net: neigh: use kfree_skb_reason() for __neigh_event_send()

From: David Ahern
Date: Fri Feb 25 2022 - 10:39:33 EST


On 2/25/22 12:17 AM, menglong8.dong@xxxxxxxxx wrote:
> From: Menglong Dong <imagedong@xxxxxxxxxxx>
>
> Replace kfree_skb() used in __neigh_event_send() with
> kfree_skb_reason(). Following drop reasons are added:
>
> SKB_DROP_REASON_NEIGH_FAILED
> SKB_DROP_REASON_NEIGH_QUEUEFULL
> SKB_DROP_REASON_NEIGH_DEAD
>
> The first two reasons above should be the hot path that skb drops
> in neighbour subsystem.
>
> Reviewed-by: Mengen Sun <mengensun@xxxxxxxxxxx>
> Reviewed-by: Hao Peng <flyingpeng@xxxxxxxxxxx>
> Signed-off-by: Menglong Dong <imagedong@xxxxxxxxxxx>
> ---
> v2:
> - introduce the new drop reason 'SKB_DROP_REASON_NEIGH_DEAD'
> - simplify the document for the new drop reasons
> ---
> include/linux/skbuff.h | 5 +++++
> include/trace/events/skb.h | 3 +++
> net/core/neighbour.c | 6 +++---
> 3 files changed, 11 insertions(+), 3 deletions(-)
>

Reviewed-by: David Ahern <dsahern@xxxxxxxxxx>