From mboxrd@z Thu Jan 1 00:00:00 1970 From: Cong Wang Subject: Re: [PATCH net] ipv6: no need to return rt->dst.error if it is not null entry. Date: Tue, 25 Jul 2017 10:49:05 -0700 Message-ID: References: <1500562286-14312-1-git-send-email-liuhangbin@gmail.com> <20170724030907.GC2938@leo.usersys.redhat.com> <20170725000849.GD2938@leo.usersys.redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Cc: network dev , Roopa Prabhu To: Hangbin Liu Return-path: Received: from mail-wm0-f43.google.com ([74.125.82.43]:37389 "EHLO mail-wm0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751325AbdGYRt1 (ORCPT ); Tue, 25 Jul 2017 13:49:27 -0400 Received: by mail-wm0-f43.google.com with SMTP id c184so62586832wmd.0 for ; Tue, 25 Jul 2017 10:49:26 -0700 (PDT) In-Reply-To: <20170725000849.GD2938@leo.usersys.redhat.com> Sender: netdev-owner@vger.kernel.org List-ID: On Mon, Jul 24, 2017 at 5:08 PM, Hangbin Liu wrote: > But what we want in inet6_rtm_getroute() and rt6_dump_route() is to > get/dump the route info. So we should get the info even it's unreachable or > prohibit. If you want to dump prohibit/blackhole entry, then you have to check for null_entry, and rt->dst.error check is still needed because we could return error on other normal entries too, IOW, your v2 is correct if dumping prohibit/blackhole is expected. I thought we don't dump them. I am not sure about the behavior either.