summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2017-09-12 20:24:00 -0400
committerDamjan Marion <dmarion.lists@gmail.com>2017-09-13 17:39:19 +0000
commita4393be1a03f6a8f8da5d53c22b8dca52fed6f51 (patch)
tree48d8aa7e66a88c81c7a06278d2831c4f17119600 /src
parent2297af016d4c1ecdd0c695dc736e8f5a988e89bd (diff)
gpe: initialize fib index for native forward entries
Change-Id: I972e6e645c3ae9cba4bb2b4e32c0272dfd67e87b Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src')
-rw-r--r--src/vnet/lisp-gpe/lisp_gpe_fwd_entry.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/vnet/lisp-gpe/lisp_gpe_fwd_entry.c b/src/vnet/lisp-gpe/lisp_gpe_fwd_entry.c
index 0a8dc039909..dbbea418fa6 100644
--- a/src/vnet/lisp-gpe/lisp_gpe_fwd_entry.c
+++ b/src/vnet/lisp-gpe/lisp_gpe_fwd_entry.c
@@ -354,11 +354,12 @@ create_fib_entries (lisp_gpe_fwd_entry_t * lfe)
if (vec_len (lgm->native_fwd_rpath[ip_version]))
{
ip_prefix_to_fib_prefix (&lfe->key->rmt.ippref, &fib_prefix);
- fib_table_entry_update (lfe->eid_fib_index, &fib_prefix,
- FIB_SOURCE_LISP, FIB_ENTRY_FLAG_NONE,
- lgm->native_fwd_rpath[ip_version]);
+ fi = fib_table_entry_update (lfe->eid_fib_index, &fib_prefix,
+ FIB_SOURCE_LISP,
+ FIB_ENTRY_FLAG_NONE,
+ lgm->native_fwd_rpath[ip_version]);
gpe_native_fwd_add_del_lfe (lfe, 1);
- break;
+ goto done;
}
case LISP_NO_ACTION:
/* TODO update timers? */
@@ -378,6 +379,7 @@ create_fib_entries (lisp_gpe_fwd_entry_t * lfe)
{
fi = ip_src_fib_add_route (lfe->src_fib_index, &ippref, lfe->paths);
}
+done:
fe = fib_entry_get (fi);
return fe->fe_lb.dpoi_index;
}