netdev
[Top] [All Lists]

Re: your mail

To: A S Arun <asarun@xxxxxxxxxxxxxxxxx>, netdev@xxxxxxxxxxx
Subject: Re: your mail
From: "James R. Leu" <jleu@xxxxxxxxxxxxxx>
Date: Thu, 27 Jul 2000 12:40:48 -0500
In-reply-to: <Pine.LNX.3.96.1000727224837.367A-100000@xxxxxxxxxxxxxxxxxxxxxxx>; from A S Arun on Thu, Jul 27, 2000 at 10:49:04PM +0530
Organization: none
References: <Pine.LNX.3.96.1000727224837.367A-100000@xxxxxxxxxxxxxxxxxxxxxxx>
Reply-to: jleu@xxxxxxxxxxxxxx
Sender: owner-netdev@xxxxxxxxxxx
On Thu, Jul 27, 2000 at 10:49:04PM +0530, A S Arun wrote:
> 
>       I am trying to change the forwarding algorithm in the linux
> kernel. i am using kernel version 2.2.12. i could find the place where the
> route cache is searched, but i am unable to find where the search in the
> fib table is taking place. can you please help me out. 

If you look in ip_route_input_slow() (packet bing routed from one interface to
another) or ip_route_output_slow() (packets originating at this box)
you will see a fib_lookup() which tries to match this packet's info to a
entry in the FIB.  Once an entry is found, a route cache entry is created
and stored in to the route cache (rt_intern_hash()).  All future
ip_route_input() or ip_route_output() will try to use the info from the
route cache for packets with similar characteristics.

Laters,
Jim
-- 
James R. Leu

<Prev in Thread] Current Thread [Next in Thread>