Re: [PATCH net-next] neigh: add netlink filtering based on LLADDR for dump

2020-10-08 Thread Florent Fourcot
Hello Éric, + if (memcmp(lladdr, neigh->ha, neigh->dev->addr_len) != 0) Where do you check that lladdr contains exactly neigh->dev->addr_len bytes ? True, I do not check. I had some doubt about the best implementation, since we could do: * exact matching * prefix matching (with a

Re: [PATCH net-next] neigh: add netlink filtering based on LLADDR for dump

2020-10-08 Thread Eric Dumazet
On 10/8/20 12:59 PM, Florent Fourcot wrote: > neighbours table dump supports today two filtering: > * based on interface index > * based on master index > > This patch adds a new filtering, based on layer two address. That will > help to replace something like it: > > ip neigh show | grep a

[PATCH net-next] neigh: add netlink filtering based on LLADDR for dump

2020-10-08 Thread Florent Fourcot
neighbours table dump supports today two filtering: * based on interface index * based on master index This patch adds a new filtering, based on layer two address. That will help to replace something like it: ip neigh show | grep aa:11:22:bb:ee:ff by a better command: ip neigh show lladdr a