mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-04 20:18:54 +00:00
Merge pull request #4529 from donaldsharp/vrf_conversions
Vrf conversions
This commit is contained in:
commit
60aecb43e8
@ -243,7 +243,7 @@ int main(int argc, char **argv, char **envp)
|
||||
mt_init();
|
||||
|
||||
/* create the global 'isis' instance */
|
||||
isis_new(1);
|
||||
isis_new(1, VRF_DEFAULT);
|
||||
|
||||
isis_zebra_init(master);
|
||||
isis_bfd_init();
|
||||
|
@ -75,12 +75,13 @@ int clear_isis_neighbor_common(struct vty *, const char *id);
|
||||
int isis_config_write(struct vty *);
|
||||
|
||||
|
||||
void isis_new(unsigned long process_id)
|
||||
void isis_new(unsigned long process_id, vrf_id_t vrf_id)
|
||||
{
|
||||
isis = XCALLOC(MTYPE_ISIS, sizeof(struct isis));
|
||||
/*
|
||||
* Default values
|
||||
*/
|
||||
isis->vrf_id = vrf_id;
|
||||
isis->max_area_addrs = 3;
|
||||
isis->process_id = process_id;
|
||||
isis->router_id = 0;
|
||||
|
@ -62,6 +62,7 @@ extern struct zebra_privs_t isisd_privs;
|
||||
struct fabricd;
|
||||
|
||||
struct isis {
|
||||
vrf_id_t vrf_id;
|
||||
unsigned long process_id;
|
||||
int sysid_set;
|
||||
uint8_t sysid[ISIS_SYS_ID_LEN]; /* SystemID for this IS */
|
||||
@ -189,7 +190,7 @@ struct isis_area {
|
||||
DECLARE_QOBJ_TYPE(isis_area)
|
||||
|
||||
void isis_init(void);
|
||||
void isis_new(unsigned long);
|
||||
void isis_new(unsigned long process_id, vrf_id_t vrf_id);
|
||||
struct isis_area *isis_area_create(const char *);
|
||||
struct isis_area *isis_area_lookup(const char *);
|
||||
int isis_area_get(struct vty *vty, const char *area_tag);
|
||||
|
@ -136,7 +136,7 @@ static void ospf6_top_brouter_hook_remove(struct ospf6_route *route)
|
||||
ospf6_abr_originate_summary(route);
|
||||
}
|
||||
|
||||
static struct ospf6 *ospf6_create(void)
|
||||
static struct ospf6 *ospf6_create(vrf_id_t vrf_id)
|
||||
{
|
||||
struct ospf6 *o;
|
||||
|
||||
@ -144,6 +144,7 @@ static struct ospf6 *ospf6_create(void)
|
||||
|
||||
/* initialize */
|
||||
monotime(&o->starttime);
|
||||
o->vrf_id = vrf_id;
|
||||
o->area_list = list_new();
|
||||
o->area_list->cmp = ospf6_area_cmp;
|
||||
o->lsdb = ospf6_lsdb_create(o);
|
||||
@ -325,7 +326,7 @@ DEFUN_NOSH (router_ospf6,
|
||||
OSPF6_STR)
|
||||
{
|
||||
if (ospf6 == NULL) {
|
||||
ospf6 = ospf6_create();
|
||||
ospf6 = ospf6_create(VRF_DEFAULT);
|
||||
if (ospf6->router_id == 0)
|
||||
ospf6_router_id_update();
|
||||
}
|
||||
|
@ -31,6 +31,9 @@ struct ospf6_master {
|
||||
|
||||
/* OSPFv3 top level data structure */
|
||||
struct ospf6 {
|
||||
/* The relevant vrf_id */
|
||||
vrf_id_t vrf_id;
|
||||
|
||||
/* my router id */
|
||||
uint32_t router_id;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user