Thursday, October 15, 2009

Section 36.6.  Functions and Variables Featured in This Part of the Book










36.6. Functions and Variables Featured in This Part of the Book






































































Table 36-13 summarizes the main functions, variables, and data structures introduced or referenced in the chapters of this book covering the routing subsystem. You can find more in the section "Generic Helper Routines and Macros" and "Helper Routines" in Chapter 32, and the two "Helper Routines", in Chapter 35.


Table 36-13. Functions, variables, and data structures in the routing subsystem

Functions

 

for_ifa, endfor_ifa

for_primary_ifa, endfor_ifa

Macros used to browse the IPv4 addresses configured on a network device. See the section "Primary and Secondary IP Addresses" in Chapter 32.

FIB_RES_XXX

Set of macros used to access the fields of the fib_result structure. See the section "Generic Helper Routines and Macros" in Chapter 32.

LOOPBACK

ZERONET

MULTICAST

LOCAL_MCAST/BADCLASS

Macros used to recognize special IP addresses. See the section "Generic Helper Routines and Macros" in Chapter 32.

fib_hash_lock

fib_info_lock

fib_rules_lock

rt_flush_lock

fib_multipath_lock

alg_table_lock

Locks used to protect various pieces of data. See the section "Global Locks" in Chapter 32.

ip_rt_init

ip_fib_init

devinet_init

fib_rules_init

fib_hash_init

dst_init

Initialization routines. See the section "Routing Subsystem Initialization" in Chapter 32.

dst_alloc

Allocate an entry for the routing cache. See the section "Cache Entry Allocation and Reference Counts" in Chapter 33.

rt_periodic_timer

rt_secret_timer

Timers. See the sections "Garbage Collection" and "Flushing the Routing Cache" in Chapter 33.

fib_netdev_event

fib_inetaddr_event

Handlers for the netdev_chain and inetaddr_chain notification chains. See the section "External Events" in Chapter 32.

fib_add_ifaddr

fib_del_ifaddr

Used to update the routing table upon the addition or removal of an IP address from the configuration of a local network device. See the sections "Adding an IP address" and "Removing an IP address" in Chapter 32.

fib_magic

Used by the kernel to insert routes under specific conditions. See the section "Routes Inserted by the Kernel: The fib_magic Function."

fib_rules_detach

fib_rules_attach

Enables and disables routing policies when network devices are registered and unregistered, respectively. See the section "Impacts on the policy database" in Chapter 32.

rtmsg_fib

Used to send notification on a specific Netlink multicast group when routes are added or removed. See the section "Netlink Notifications" in Chapter 32.

ip_route_input

_ _ip_route_output_key ip_route_output_flow

ip_route_output_key

ip_route_connect

ip_route_newports

The first two functions are routing cache lookup routines, and the others are wrappers around them. See the section "Cache Lookup" in Chapter 33.

ip_route_input_slow

ip_route_output_slow

Routing table lookup routines. See Chapter 35.

ip_route_input_mc

Lookup routines used for multicast destinations.

ip_mkroute_input

ip_mkroute_input_def

ip_mkroute_output

ip_mkroute_output_def

fib_select_default

fib_select_multipath

Various support routines used by ip_route_input_slow and ip_route_output_slow. See Chapter 35.

fib_lookup

fn_hash_lookup

fib_semantic_match

Routines called at different stages during a routing table lookup. See the section "High-Level View of Lookup Functions" in Chapter 35.

fn_hash_insert

Add a new route to a routing table. See the section "Adding a Route" in Chapter 34.

fn_hash_delete

Remove a route from a routing table. See the section "Deleting a Route" in Chapter 34.

rt_intern_hash

Add an entry to the routing cache. See the section "Adding Elements to the Cache" in Chapter 33.

multipath_alg_register

multipath_alg_unregister

Register and unregister a multipath caching algorithm. See the section "Registering a Caching Algorithm" in Chapter 33.

multipath_select_route

multipath_flush

multipath_set_nhinfo

multipath_remove

Various routines used to manage cache entries associated with multipath routes. See the section "Interface Between the Routing Cache and Multipath" in Chapter 33. More routines are listed in the section "Helper Routines" in the same chapter.

rt_free

dst_free

Free an rtable and a dst_entry structure, respectively.

rt_garbage_collect

rt_may_expire

Garbage collection routines used for the routing cache. See the section "rt_garbage_collect Function" in Chapter 33.

dst_input

dst_output

Complete the reception and transmission of a packet, respectively. See the section "Cache Lookup" in Chapter 33. See also the section "Setting Functions for Reception and Transmission" in Chapter 35.

rt_garbage_collect

dst_destroy

dst_ifdown

dst_negative_advice

dst_link_failure

dst_set_expires

Routines used for the initialization of the dst_ops instance associated with the IPv4 protocol. See the section "Interface Between the DST and Calling Protocols" in Chapter 33.

dst_dev_event

Handler used by the DST subsystem to process notifications from the neTDev_chain notification chain. See the section "External Events" in Chapter 32.

RT_CACHE_STAT_INC

Update per-CPU statistics. See the section "Statistics."

Variables

 

ip_fib_local_table

ip_fib_main_table

Routing tables. See the section "The Two Default Routing Tables: ip_fib_main_table and ip_fib_local_table" in Chapter 34.

rt_hash_table

Routing cache. See Chapter 33.

rt_hash_mask

Size of the routing cache (i.e., number of buckets of the hash table).

dst_garbage_list

List of dst_entry instances that cannot be removed because they are still referenced. See Chapter 33.

fib_tables

List of fib_table instances. See Figure 34-1 in Chapter 34.

fib_rules

List of routing policies. See the section "fib_lookup with Policy Routing" in Chapter 35.

fib_info_cnt

Number of outstanding fib_info instances. See the section "Dynamic resizing of global hash tables" in Chapter 34.

fib_info_hash

fib_info_laddrhash

Hash tables used to search fib_info instances. See the section "Organization of fib_info Structures" in Chapter 34.

fib_info_devhash

Hash table used to search fib_nh instances. See the section "Organization of Next-Hop Router Structures" in Chapter 34.

fib_props

Vector whose elements are used by the lookup routine fib_semantic_match to map route types to return values. See the section "Return value from fib_semantic_match" in Chapter 35.

Data structures

 

fib_table structure

fn_zone structure

fib_node structure

fib_alias structure

fib_info structure

fib_nh structure

fib_rule structure

rtable structure

dst_entry structure

dst_ops structure

flowi structure

rt_cache_stat structure

ip_mp_alg_ops structure

Key data structures used by the routing code. They are described in detail in the section "Data Structures Featured in This Part of the Book."













No comments:

Post a Comment