On 5/20/20 3:15 AM, Sabrina Dubroca wrote:
> In case we can't find a ->dumpit callback for the requested
> (family,type) pair, we fall back to (PF_UNSPEC,type). In effect, we're
> in the same situation as if userspace had requested a PF_UNSPEC
> dump. For RTM_GETROUTE, that handler is rtnl_dump_all, which calls all
> the registered RTM_GETROUTE handlers.

...

> Instead, this patch removes dump_all_families and updates the
> RTM_GETROUTE handlers to check if the family that is being dumped is
> their own. When it's not, which covers both the intentional PF_UNSPEC
> dumps (as dump_all_families did) and the fallback case, ignore the
> missing table id error.
> 
> Fixes: cb167893f41e ("net: Plumb support for filtering ipv4 and ipv6 
> multicast route dumps")
> Signed-off-by: Sabrina Dubroca <s...@queasysnail.net>
> ---
>  include/net/ip_fib.h    | 1 -
>  net/ipv4/fib_frontend.c | 3 +--
>  net/ipv4/ipmr.c         | 2 +-
>  net/ipv6/ip6_fib.c      | 2 +-
>  net/ipv6/ip6mr.c        | 2 +-
>  5 files changed, 4 insertions(+), 6 deletions(-)
> 

Thanks for the detailed analysis and commit message.

Reviewed-by: David Ahern <dsah...@gmail.com>


Reply via email to