summaryrefslogtreecommitdiffstats
path: root/yang/frr-zebra.yang
diff options
context:
space:
mode:
authorChirag Shah <chirag@cumulusnetworks.com>2020-03-06 06:43:41 +0100
committerSantosh P K <sapk@vmware.com>2020-04-16 17:17:59 +0200
commit303cfba62642e0f895dd178ba5faf0c0dc3c4eab (patch)
tree115f6b23ecb3864660622de85b3e1558678b38b1 /yang/frr-zebra.yang
parentyang: zebra rib model remove grouping for ip route (diff)
downloadfrr-303cfba62642e0f895dd178ba5faf0c0dc3c4eab.tar.xz
frr-303cfba62642e0f895dd178ba5faf0c0dc3c4eab.zip
yang: zebra rib model add route entry
FRR rib model need to accomodate route entries for a given destination prefix. Add a list of route entry under the list of prefix. +--rw ribs +--rw rib* [afi-safi-name table-id] +--rw table-id uint32 +--rw afi-safi-name identityref +--ro route* [prefix] +--ro prefix ietf-inet-types:ip-prefix +--ro route-entry* [protocol] +--ro protocol frr-route-types:frr-route-types-v4 +--ro instance? uint16 +--ro distance? uint8 +--ro metric? uint32 +--ro tag? uint32 +--ro selected? empty +--ro installed? empty +--ro failed? empty +--ro queued? empty +--ro internal-flags? int32 +--ro internal-status? int32 +--ro uptime? ietf-yang-types:date-and-time +--ro nexthop-group* [name] +--ro name string +--ro frr-nexthops +--ro nexthop* [nh-type gateway interface] +--ro nh-type frr-nexthop:nexthop-type +--ro vrf? frr-vrf:vrf-ref +--ro gateway frr-nexthop:optional-ip-address +--ro interface frr-interface:interface-ref +--ro bh-type? frr-nexthop:blackhole-type +--ro onlink? boolean <false> +--ro mpls-label-stack | +--ro entry* [id] | +--ro id uint8 | +--ro label? ietf-routing-types:mpls-label | +--ro ttl? uint8 | +--ro traffic-class? uint8 +--ro duplicate? empty +--ro recursive? empty +--ro active? empty +--ro fib? empty Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
Diffstat (limited to 'yang/frr-zebra.yang')
-rw-r--r--yang/frr-zebra.yang37
1 files changed, 17 insertions, 20 deletions
diff --git a/yang/frr-zebra.yang b/yang/frr-zebra.yang
index 205109d8a..518cef401 100644
--- a/yang/frr-zebra.yang
+++ b/yang/frr-zebra.yang
@@ -165,11 +165,6 @@ module frr-zebra {
grouping route-common {
description
"Common information about a route.";
- leaf vrf {
- type frr-vrf:vrf-ref;
- description
- "The route's vrf name.";
- }
leaf distance {
type uint8;
@@ -572,22 +567,24 @@ module frr-zebra {
description
"The route's prefix.";
}
+ list route-entry {
+ key "protocol";
+ leaf protocol {
+ type frr-route-types:frr-route-types-v4;
+ //TODO: Use unified route types done in PR 5183 when it is merged.
+ //type frr-route-types:frr-route-types;
+ description
+ "The protocol owning the route.";
+ }
- leaf protocol {
- when "'../../afi-safi-name' = 'ipv4-unicast'";
- type frr-route-types:frr-route-types-v4;
- description
- "The protocol owning the route.";
- }
-
- leaf protocol-v6 {
- when "'../../afi-safi-name' = 'ipv6-unicast'";
- type frr-route-types:frr-route-types-v6;
- description
- "The protocol owning the route.";
+ leaf instance {
+ type uint16;
+ must "../protocol = \"ospf\"";
+ description
+ "Retrieve routes from a specific OSPF instance.";
+ }
+ uses route-common;
}
-
- uses route-common;
}
}
}
@@ -1937,7 +1934,7 @@ module frr-zebra {
uses ribs;
}
- augment "/frr-vrf:lib/frr-vrf:vrf/ribs/rib/route/nexthop-group/frr-nexthops/nexthop" {
+ augment "/frr-vrf:lib/frr-vrf:vrf/ribs/rib/route/route-entry/nexthop-group/frr-nexthops/nexthop" {
uses frr-nh:frr-nexthop-operational;
}