[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20181011183016.GH5708@lunn.ch>
Date: Thu, 11 Oct 2018 20:30:16 +0200
From: Andrew Lunn <andrew@...n.ch>
To: David Ahern <dsahern@...il.com>
Cc: David Ahern <dsahern@...nel.org>, netdev@...r.kernel.org,
davem@...emloft.net
Subject: Re: [PATCH net-next 2/9] net/ipv4: Plumb support for filtering route
dumps
On Thu, Oct 11, 2018 at 10:44:04AM -0600, David Ahern wrote:
> On 10/11/18 9:56 AM, Andrew Lunn wrote:
> >> @@ -866,10 +866,13 @@ static int inet_dump_fib(struct sk_buff *skb, struct netlink_callback *cb)
> >> hlist_for_each_entry_rcu(tb, head, tb_hlist) {
> >> if (e < s_e)
> >> goto next;
> >> + if (filter.table_id && filter.table_id != tb->tb_id)
> >> + goto next;
> >> +
> >
> > Hi David
> >
> > Should there be a test here that filter->filter_set is set, before
> > looking at filter.table_id.
>
> filter_set is meant for places that would need to look at multiple flags.
Hi David
It would be good to add some comments to struct fib_dump_filter. Maybe
also move table_id before filter_set, to try to indicate it is not
relevant for the table_id.
Andrew
Powered by blists - more mailing lists