[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <53746589-33fa-e5bd-037e-952f9c2d9cc3@gmail.com>
Date: Thu, 25 Mar 2021 08:36:59 -0600
From: David Ahern <dsahern@...il.com>
To: Yejune Deng <yejune.deng@...il.com>, davem@...emloft.net,
yoshfuji@...ux-ipv6.org, dsahern@...nel.org, kuba@...nel.org
Cc: netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
yejune@...il.com
Subject: Re: [PATCH 2/2] net: ipv4: route.c: Remove unnecessary if()
On 3/23/21 9:10 PM, Yejune Deng wrote:
> negative_advice handler is only called when dst is non-NULL hence the
> 'if (rt)' check can be removed. 'if' and 'else if' can be merged together.
> And use container_of() instead of (struct rtable *).
>
> Signed-off-by: Yejune Deng <yejune.deng@...il.com>
> ---
> net/ipv4/route.c | 16 ++++++----------
> 1 file changed, 6 insertions(+), 10 deletions(-)
>
Reviewed-by: David Ahern <dsahern@...nel.org>
Powered by blists - more mailing lists