summaryrefslogtreecommitdiffstats
path: root/zebra/zebra_mpls_netlink.c
diff options
context:
space:
mode:
authorMark Stapp <mjs@voltanet.io>2018-10-23 16:57:01 +0200
committerMark Stapp <mjs@voltanet.io>2019-01-22 18:02:20 +0100
commit16c628de99517efe4c9f960ca7423bc86ac7d5c4 (patch)
tree9d742eaa01d9ebc35a7f78ac93547b04cbd22be7 /zebra/zebra_mpls_netlink.c
parentzebra: add apis to add and delete NHLFEs (diff)
downloadfrr-16c628de99517efe4c9f960ca7423bc86ac7d5c4.tar.xz
frr-16c628de99517efe4c9f960ca7423bc86ac7d5c4.zip
zebra: infra for LSP updates using dplane
Adding infra to zebra dplane to support LSP updates. Add kernel api for LSP updates that uses a dataplane context; add stub apis for netlink, bsd, and 'null' kernel paths. Add version of netlink mpls update code that takes a dplane context struct instead of a zebra lsp struct. Signed-off-by: Mark Stapp <mjs@voltanet.io>
Diffstat (limited to 'zebra/zebra_mpls_netlink.c')
-rw-r--r--zebra/zebra_mpls_netlink.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/zebra/zebra_mpls_netlink.c b/zebra/zebra_mpls_netlink.c
index c4ab316d0..2a21f8686 100644
--- a/zebra/zebra_mpls_netlink.c
+++ b/zebra/zebra_mpls_netlink.c
@@ -51,12 +51,8 @@ enum zebra_dplane_result kernel_add_lsp(zebra_lsp_t *lsp)
* Update Label Forwarding entry in the kernel. This means that the Label
* forwarding entry is already installed and needs an update - either a new
* path is to be added, an installed path has changed (e.g., outgoing label)
- * or an installed path (but not all paths) has to be removed.
- * TODO: Performs a DEL followed by ADD now, need to change to REPLACE. Note
- * that REPLACE was originally implemented for IPv4 nexthops but removed as
- * it was not functioning when moving from swap to PHP as that was signaled
- * through the metric field (before kernel-MPLS). This shouldn't be an issue
- * any longer, so REPLACE can be reintroduced.
+ * or an installed path (but not all paths) has to be removed. This performs
+ * a REPLACE operation, internally.
*/
enum zebra_dplane_result kernel_upd_lsp(zebra_lsp_t *lsp)
{
@@ -102,6 +98,11 @@ enum zebra_dplane_result kernel_del_lsp(zebra_lsp_t *lsp)
return ZEBRA_DPLANE_REQUEST_SUCCESS;
}
+enum zebra_dplane_result kernel_lsp_update(struct zebra_dplane_ctx *ctx)
+{
+ return ZEBRA_DPLANE_REQUEST_FAILURE;
+}
+
int mpls_kernel_init(void)
{
struct stat st;