[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070504132008.GB2291@2ka.mipt.ru>
Date: Fri, 4 May 2007 17:20:09 +0400
From: Evgeniy Polyakov <johnpol@....mipt.ru>
To: David Howells <dhowells@...hat.com>
Cc: netdev@...r.kernel.org, Patrick McHardy <kaber@...sh.net>
Subject: Re: How to find I/F to destination
On Fri, May 04, 2007 at 02:08:15PM +0100, David Howells (dhowells@...hat.com) wrote:
>
> Should route_get_raw() release the rtable if gets back?
You can also cache returned entry and then just clone it and check
->obsolete() callback.
Something like this:
struct dst_entry *route_get(struct dst_entry *dst)
{
if (dst && dst->obsolete && dst->ops->check(dst, 0) == NULL) {
dst_release(dst);
return NULL;
}
return dst_clone(dst);
}
Copied from route code too.
> David
--
Evgeniy Polyakov
-
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