summaryrefslogtreecommitdiffstats
path: root/isisd/isisd.h
diff options
context:
space:
mode:
authorIgor Ryzhov <iryzhov@nfware.com>2021-10-05 16:38:21 +0200
committerIgor Ryzhov <iryzhov@nfware.com>2021-10-05 16:38:21 +0200
commit1bfee9368adcd91337b4b4b5ad22330678ed0e78 (patch)
tree8c38a5231a85cf1a5c178531eac8ecc41bf2a350 /isisd/isisd.h
parentMerge pull request #9714 from idryzhov/bgp-ext-comm-doc (diff)
downloadfrr-1bfee9368adcd91337b4b4b5ad22330678ed0e78.tar.xz
frr-1bfee9368adcd91337b4b4b5ad22330678ed0e78.zip
isisd: fix redistribute CLI
Currently, it is possible to configure IPv6 protocols for IPv4 redistribution and vice versa in CLI. The YANG model doesn't allow this so the user receives the following error: ``` nfware(config-router)# redistribute ipv4 ospf6 level-1 % Failed to edit configuration. YANG error(s): Invalid enumeration value "ospf6". Invalid enumeration value "ospf6". Invalid enumeration value "ospf6". YANG path: Schema location /frr-isisd:isis/instance/redistribute/ipv4/protocol. ``` Let's make CLI more user-friendly and allow only supported protocols in redistribution commands. Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
Diffstat (limited to 'isisd/isisd.h')
-rw-r--r--isisd/isisd.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/isisd/isisd.h b/isisd/isisd.h
index 64fbf78a0..13f3475b7 100644
--- a/isisd/isisd.h
+++ b/isisd/isisd.h
@@ -46,7 +46,11 @@ static const bool fabricd = true;
#define PROTO_NAME "openfabric"
#define PROTO_HELP "OpenFabric routing protocol\n"
#define PROTO_REDIST_STR FRR_REDIST_STR_FABRICD
+#define PROTO_IP_REDIST_STR FRR_IP_REDIST_STR_FABRICD
+#define PROTO_IP6_REDIST_STR FRR_IP6_REDIST_STR_FABRICD
#define PROTO_REDIST_HELP FRR_REDIST_HELP_STR_FABRICD
+#define PROTO_IP_REDIST_HELP FRR_IP_REDIST_HELP_STR_FABRICD
+#define PROTO_IP6_REDIST_HELP FRR_IP6_REDIST_HELP_STR_FABRICD
#define ROUTER_NODE OPENFABRIC_NODE
#else
static const bool fabricd = false;
@@ -54,7 +58,11 @@ static const bool fabricd = false;
#define PROTO_NAME "isis"
#define PROTO_HELP "IS-IS routing protocol\n"
#define PROTO_REDIST_STR FRR_REDIST_STR_ISISD
+#define PROTO_IP_REDIST_STR FRR_IP_REDIST_STR_ISISD
+#define PROTO_IP6_REDIST_STR FRR_IP6_REDIST_STR_ISISD
#define PROTO_REDIST_HELP FRR_REDIST_HELP_STR_ISISD
+#define PROTO_IP_REDIST_HELP FRR_IP_REDIST_HELP_STR_ISISD
+#define PROTO_IP6_REDIST_HELP FRR_IP6_REDIST_HELP_STR_ISISD
#define ROUTER_NODE ISIS_NODE
extern void isis_cli_init(void);
#endif