The Netsukuku Project
0.0.9
An Alternative routing method
|
#include "gmap.h"
Go to the source code of this file.
Data Structures | |
struct | _PACKED_ |
struct | _PACKED_ |
struct | bnode_maps_hdr |
Macros | |
#define | BMAP_UPDATE |
#define | MAP_BNODE_PACK_SZ MAP_NODE_PACK_SZ |
#define | MAXGROUPBNODE |
#define | MAXBNODE_LINKS |
#define | MAXBNODE_RNODEBLOCK (MAXBNODE_LINKS*MAXGROUPBNODE*MAP_RNODE_PACK_SZ) |
#define | bnode_ptr brdcast /*Don't kill me*/ |
#define | bnode_map_hdr int_map_hdr |
#define | bnode_map_sz int_map_sz |
#define | BMAP_LEVELS(levels) (levels-1) |
#define | BMAP_MAX_LEVELS (BMAP_LEVELS(MAX_LEVELS)) |
#define | GET_BMAP_LEVELS(family) (BMAP_LEVELS(GET_LEVELS((family)))) |
#define | BNODE_HDR_SZ(levels) (sizeof(bnode_hdr)+sizeof(u_char)*(levels)) |
#define | BNODEBLOCK_SZ(levels, links) |
Typedefs | |
typedef map_node | map_bnode |
Functions | |
void | bmap_levels_init (u_char levels, map_bnode ***bmap, u_int **bmap_nodes) |
void | bmap_levels_free (map_bnode **bmap, u_int *bmap_nodes) |
void | bmap_counter_init (u_char levels, u_int **bnodes_closed, u_int **bnodes_opened) |
void | bmap_counter_free (u_int *bnodes_closed, u_int *bnodes_opened) |
void | bmap_counter_reset (u_char levels, u_int *counter) |
int | map_add_bnode (map_bnode **bmap, u_int *bmap_nodes, u_int bnode, u_int links) |
map_bnode * | map_bnode_del (map_bnode *bmap, u_int *bmap_nodes, map_bnode *bnode) |
int | bmap_del_rnode_by_level (map_bnode *, int, map_gnode **, int) |
int | map_find_bnode (map_bnode *bmap, int bmap_nodes, int node) |
int | map_find_bnode_rnode (map_bnode *bmap, int bmap_nodes, void *n) |
int | map_count_bnode_rnode (map_bnode *bmap, int bmap_nodes, void *n) |
int | bmaps_count_bnode_rnode (map_bnode **bmap, int *bmap_nodes, int levels, void *n) |
int | map_del_bnode_rnode (map_bnode **bmap, int *bmap_nodes, void *n) |
int | bmaps_del_bnode_rnode (map_bnode **bmap, int *bmap_nodes, int levels, void *n) |
void | map_set_bnode_flag (map_bnode *bmap, int bmap_nodes, int flags) |
void | bmaps_set_bnode_flag (map_bnode **bmap, int *bmap_nodes, int levels, int flags) |
char * | pack_all_bmaps (map_bnode **, u_int *, map_gnode **, quadro_group, size_t *) |
map_bnode ** | unpack_all_bmaps (char *, u_char, map_gnode **, u_int **, int, int) |
int | save_bmap (map_bnode **, u_int *, map_gnode **, quadro_group, char *) |
map_bnode ** | load_bmap (char *, map_gnode **, u_char, u_int **) |
Variables | |
static const int_info | bnode_hdr_iinfo = { 1, { (1<<1) }, { sizeof(char) }, { 1 } } |
static const int_info | bnode_chunk_iinfo = { 1, { 1 }, { sizeof(char)*2 }, { 1 } } |
struct bnode_maps_hdr | _PACKED_ |
static const int_info | bnode_maps_hdr_iinfo = { 1, { 1 }, { sizeof(char) }, { 1 } } |
#define BMAP_LEVELS | ( | levels | ) | (levels-1) |
#define BMAP_MAX_LEVELS (BMAP_LEVELS(MAX_LEVELS)) |
#define BMAP_UPDATE |
#define BNODE_HDR_SZ | ( | levels | ) | (sizeof(bnode_hdr)+sizeof(u_char)*(levels)) |
#define bnode_map_hdr int_map_hdr |
#define bnode_map_sz int_map_sz |
#define bnode_ptr brdcast /*Don't kill me*/ |
#define BNODEBLOCK_SZ | ( | levels, | |
links | |||
) |
#define GET_BMAP_LEVELS | ( | family | ) | (BMAP_LEVELS(GET_LEVELS((family)))) |
#define MAP_BNODE_PACK_SZ MAP_NODE_PACK_SZ |
#define MAXBNODE_LINKS |
#define MAXBNODE_RNODEBLOCK (MAXBNODE_LINKS*MAXGROUPBNODE*MAP_RNODE_PACK_SZ) |
#define MAXGROUPBNODE |
void bmap_counter_free | ( | u_int * | bnodes_closed, |
u_int * | bnodes_opened | ||
) |
void bmap_counter_init | ( | u_char | levels, |
u_int ** | bnodes_closed, | ||
u_int ** | bnodes_opened | ||
) |
void bmap_counter_reset | ( | u_char | levels, |
u_int * | counter | ||
) |
void bmap_levels_free | ( | map_bnode ** | bmap, |
u_int * | bmap_nodes | ||
) |
void bmap_levels_init | ( | u_char | levels, |
map_bnode *** | bmap, | ||
u_int ** | bmap_nodes | ||
) |
int bmaps_count_bnode_rnode | ( | map_bnode ** | bmap, |
int * | bmap_nodes, | ||
int | levels, | ||
void * | n | ||
) |
int bmaps_del_bnode_rnode | ( | map_bnode ** | bmap, |
int * | bmap_nodes, | ||
int | levels, | ||
void * | n | ||
) |
void bmaps_set_bnode_flag | ( | map_bnode ** | bmap, |
int * | bmap_nodes, | ||
int | levels, | ||
int | flags | ||
) |
int map_add_bnode | ( | map_bnode ** | bmap, |
u_int * | bmap_nodes, | ||
u_int | bnode, | ||
u_int | links | ||
) |
int map_count_bnode_rnode | ( | map_bnode * | bmap, |
int | bmap_nodes, | ||
void * | n | ||
) |
int map_del_bnode_rnode | ( | map_bnode ** | bmap, |
int * | bmap_nodes, | ||
void * | n | ||
) |
int map_find_bnode | ( | map_bnode * | bmap, |
int | bmap_nodes, | ||
int | node | ||
) |
int map_find_bnode_rnode | ( | map_bnode * | bmap, |
int | bmap_nodes, | ||
void * | n | ||
) |
void map_set_bnode_flag | ( | map_bnode * | bmap, |
int | bmap_nodes, | ||
int | flags | ||
) |
char* pack_all_bmaps | ( | map_bnode ** | , |
u_int * | , | ||
map_gnode ** | , | ||
quadro_group | , | ||
size_t * | |||
) |
int save_bmap | ( | map_bnode ** | , |
u_int * | , | ||
map_gnode ** | , | ||
quadro_group | , | ||
char * | |||
) |
struct bnode_maps_hdr _PACKED_ |
|
static |
|
static |
|
static |