version 1.1.1.1, 2012/02/21 17:26:11
|
version 1.1.1.2, 2016/11/02 10:09:10
|
Line 25 Software Foundation, Inc., 59 Temple Place - Suite 330
|
Line 25 Software Foundation, Inc., 59 Temple Place - Suite 330
|
#include "prefix.h" |
#include "prefix.h" |
#include "hash.h" |
#include "hash.h" |
#include "thread.h" |
#include "thread.h" |
|
#include "filter.h" |
|
|
#include "bgpd/bgpd.h" |
#include "bgpd/bgpd.h" |
#include "bgpd/bgp_table.h" |
#include "bgpd/bgp_table.h" |
Line 35 Software Foundation, Inc., 59 Temple Place - Suite 330
|
Line 36 Software Foundation, Inc., 59 Temple Place - Suite 330
|
#include "bgpd/bgp_packet.h" |
#include "bgpd/bgp_packet.h" |
#include "bgpd/bgp_fsm.h" |
#include "bgpd/bgp_fsm.h" |
#include "bgpd/bgp_mplsvpn.h" |
#include "bgpd/bgp_mplsvpn.h" |
| |
/* BGP advertise attribute is used for pack same attribute update into |
/* BGP advertise attribute is used for pack same attribute update into |
one packet. To do that we maintain attribute hash in struct |
one packet. To do that we maintain attribute hash in struct |
peer. */ |
peer. */ |
Line 79 baa_hash_cmp (const void *p1, const void *p2)
|
Line 80 baa_hash_cmp (const void *p1, const void *p2)
|
|
|
return attrhash_cmp (baa1->attr, baa2->attr); |
return attrhash_cmp (baa1->attr, baa2->attr); |
} |
} |
| |
/* BGP update and withdraw information is stored in BGP advertise |
/* BGP update and withdraw information is stored in BGP advertise |
structure. This structure is referred from BGP adjacency |
structure. This structure is referred from BGP adjacency |
information. */ |
information. */ |
Line 151 bgp_advertise_unintern (struct hash *hash, struct bgp_
|
Line 152 bgp_advertise_unintern (struct hash *hash, struct bgp_
|
baa_free (baa); |
baa_free (baa); |
} |
} |
} |
} |
| |
/* BGP adjacency keeps minimal advertisement information. */ |
/* BGP adjacency keeps minimal advertisement information. */ |
static void |
static void |
bgp_adj_out_free (struct bgp_adj_out *adj) |
bgp_adj_out_free (struct bgp_adj_out *adj) |
Line 327 bgp_adj_out_remove (struct bgp_node *rn, struct bgp_ad
|
Line 328 bgp_adj_out_remove (struct bgp_node *rn, struct bgp_ad
|
BGP_ADJ_OUT_DEL (rn, adj); |
BGP_ADJ_OUT_DEL (rn, adj); |
bgp_adj_out_free (adj); |
bgp_adj_out_free (adj); |
} |
} |
| |
void |
void |
bgp_adj_in_set (struct bgp_node *rn, struct peer *peer, struct attr *attr) |
bgp_adj_in_set (struct bgp_node *rn, struct peer *peer, struct attr *attr) |
{ |
{ |
Line 361 bgp_adj_in_remove (struct bgp_node *rn, struct bgp_adj
|
Line 362 bgp_adj_in_remove (struct bgp_node *rn, struct bgp_adj
|
XFREE (MTYPE_BGP_ADJ_IN, bai); |
XFREE (MTYPE_BGP_ADJ_IN, bai); |
} |
} |
|
|
void | int |
bgp_adj_in_unset (struct bgp_node *rn, struct peer *peer) |
bgp_adj_in_unset (struct bgp_node *rn, struct peer *peer) |
{ |
{ |
struct bgp_adj_in *adj; |
struct bgp_adj_in *adj; |
Line 371 bgp_adj_in_unset (struct bgp_node *rn, struct peer *pe
|
Line 372 bgp_adj_in_unset (struct bgp_node *rn, struct peer *pe
|
break; |
break; |
|
|
if (! adj) |
if (! adj) |
return; | return 0; |
|
|
bgp_adj_in_remove (rn, adj); |
bgp_adj_in_remove (rn, adj); |
bgp_unlock_node (rn); |
bgp_unlock_node (rn); |
|
return 1; |
} |
} |
| |
void |
void |
bgp_sync_init (struct peer *peer) |
bgp_sync_init (struct peer *peer) |
{ |
{ |