[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20120718.123015.476222169838022819.davem@davemloft.net>
Date: Wed, 18 Jul 2012 12:30:15 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: joe@...ches.com
Cc: netdev@...r.kernel.org
Subject: Re: [PATCH 08/15] ipv4: Kill routes during PMTU/redirect updates.
From: Joe Perches <joe@...ches.com>
Date: Wed, 18 Jul 2012 12:15:44 -0700
> On Wed, 2012-07-18 at 11:23 -0700, David Miller wrote:
>> Mark them obsolete so there will be a re-lookup to fetch the
>> FIB nexthop exception info.
> []
>> diff --git a/net/ipv4/route.c b/net/ipv4/route.c
> []
>> @@ -716,8 +717,8 @@ static void __ip_do_redirect(struct rtable *rt, struct sk_buff *skb, struct flow
>> fnhe->fnhe_gw = new_gw;
>> spin_unlock_bh(&fnhe_lock);
>> }
>> - rt->rt_gateway = new_gw;
>> - rt->rt_flags |= RTCF_REDIRECTED;
>> + if (kill_route)
>> + rt->dst.obsolete = -2;
>
> Perhaps -2 should be a #define?
>
> Perhaps struct dst_entry.obsolete could be a char instead of
> a short and a pad byte could added for some future use.
First thing, char is not signed by default on all systems :-)
But yes, this should be cleaned up. Also with a big fat comment above
the struct member detailing it's usage.
I'll put this on my TODO list, thanks a lot Joe.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists