/home/aaron/olsrd-current/olsrd/src/core/process_package.c File Reference

#include "process_package.h"
#include "link_set.h"
#include "hna_set.h"
#include "neighbor_table.h"
#include "mid_set.h"
#include "olsr.h"
#include "parser.h"
#include "olsr_logging.h"
Include dependency graph for process_package.c:

Go to the source code of this file.

Functions

static void olsr_input_hello (struct olsr_message *msg, struct interface *, union olsr_ip_addr *, enum duplicate_status)
static void process_message_neighbors (struct nbr_entry *, const struct lq_hello_message *)
static bool lookup_mpr_status (const struct lq_hello_message *, const struct interface *)
static void hello_tap (struct lq_hello_message *, struct interface *, const union olsr_ip_addr *)
void olsr_init_package_process (void)
void olsr_deinit_package_process (void)
static bool deserialize_hello (struct lq_hello_message *hello, struct olsr_message *msg)
static void olsr_update_mprs_set (struct lq_hello_message *message, struct link_entry *link)
static void olsr_input_hello (struct olsr_message *msg, struct interface *inif, union olsr_ip_addr *from, enum duplicate_status status __attribute__((unused)))

Function Documentation

static bool deserialize_hello ( struct lq_hello_message hello,
struct olsr_message msg 
) [static]
static void hello_tap ( struct lq_hello_message message,
struct interface in_if,
const union olsr_ip_addr from_addr 
) [static]
static bool lookup_mpr_status ( const struct lq_hello_message message,
const struct interface in_if 
) [static]

Check if a hello message states this node as a MPR.

Parameters:
message the message to check
n_link the buffer to put the link status in
Returns:
1 if we are selected as MPR 0 if not

Definition at line 125 of file process_package.c.

References lq_hello_neighbor::addr, interface::ip_addr, lq_hello_neighbor::link_type, MPR_NEIGH, lq_hello_message::neigh, lq_hello_neighbor::neigh_type, lq_hello_neighbor::next, olsr_ipcmp(), SYM_LINK, and UNSPEC_LINK.

Referenced by olsr_update_mprs_set().

Here is the call graph for this function:

void olsr_deinit_package_process ( void   ) 

Definition at line 153 of file process_package.c.

References olsr_input_hello(), olsr_input_hna(), olsr_input_mid(), olsr_input_tc(), and olsr_parser_remove_function().

Referenced by olsr_deinit_parser().

Here is the call graph for this function:

void olsr_init_package_process ( void   ) 

Initializing the parser functions we are using For downwards compatibility reasons we also understand the non-LQ messages.

Definition at line 144 of file process_package.c.

References HNA_MESSAGE, MID_MESSAGE, olsr_get_Hello_MessageId(), olsr_get_TC_MessageId(), olsr_input_hello(), olsr_input_hna(), olsr_input_mid(), olsr_input_tc(), and olsr_parser_add_function().

Referenced by olsr_init_parser().

Here is the call graph for this function:

static void olsr_input_hello ( struct olsr_message msg,
struct interface inif,
union olsr_ip_addr from,
enum duplicate_status status   __attribute__(unused) 
) [static]

Definition at line 280 of file process_package.c.

References deserialize_hello(), and hello_tap().

Here is the call graph for this function:

static void olsr_input_hello ( struct olsr_message msg,
struct interface ,
union olsr_ip_addr ,
enum  duplicate_status 
) [static]
static void olsr_update_mprs_set ( struct lq_hello_message message,
struct link_entry link 
) [static]

Definition at line 206 of file process_package.c.

References link_entry::inter, link_entry::is_mprs, lookup_mpr_status(), nbr_entry::mprs_count, and link_entry::neighbor.

Referenced by hello_tap().

Here is the call graph for this function:

static void process_message_neighbors ( struct nbr_entry neighbor,
const struct lq_hello_message message 
) [static]

Processes an list of neighbors from an incoming HELLO message.

Parameters:
neighbor the neighbor who sent the message.
message the HELLO message
Returns:
nada

Definition at line 68 of file process_package.c.

References lq_hello_neighbor::addr, changes_neighborhood, lq_hello_message::comm, lq_hello_neighbor::cost, get_best_link_to_neighbor(), if_ifwithaddr(), link_entry::linkcost, MPR_NEIGH, lq_hello_message::neigh, lq_hello_neighbor::neigh_type, lq_hello_neighbor::next, olsr_link_nbr_nbr2(), olsr_lookup_main_addr_by_alias(), olsr_lookup_nbr_con_entry(), nbr_con::path_linkcost, nbr_con::second_hop_linkcost, SYM_NEIGH, and olsr_message::vtime.

Referenced by hello_tap().

Here is the call graph for this function:

Generated on Wed May 22 06:01:07 2013 for olsrd by  doxygen 1.6.3