Skip to content

Commit

Permalink
ospf: update to ietf-ospf-sr-mpls@2024-01-18.yang
Browse files Browse the repository at this point in the history
This update contains mostly editorial changes, along with new TLV
"length" leafs.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
  • Loading branch information
rwestphal committed Jan 25, 2024
1 parent 5343f80 commit 099c571
Show file tree
Hide file tree
Showing 8 changed files with 1,699 additions and 1,473 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ Holo supports the following IETF RFCs and Internet drafts:
| ietf-key-chain@2017-04-18 | 100.00% | 100.00% | - | - | [100.00%](http://westphal.com.br/holo/ietf-key-chain.html) |
| ietf-mpls-ldp@2022-03-14 | 86.96% | 92.31% | 100.00% | 100.00% | [92.38%](http://westphal.com.br/holo/ietf-mpls-ldp.html) |
| ietf-mpls@2020-12-18 | 0.00% | 57.14% | - | - | [35.29%](http://westphal.com.br/holo/ietf-mpls.html) |
| ietf-ospf-sr@2023-07-09 | 25.00% | 53.95% | - | - | [52.81%](http://westphal.com.br/holo/ietf-ospf-sr.html) |
| ietf-ospf-sr-mpls@2024-01-18 | 25.00% | 53.95% | - | - | [52.81%](http://westphal.com.br/holo/ietf-ospf-sr-mpls.html) |
| ietf-ospf@2022-10-19 | 75.00% | 59.64% | 100.00% | 41.94% | [59.57%](http://westphal.com.br/holo/ietf-ospf.html) |
| ietf-ospfv3-extended-lsa@2024-01-16 | 50.00% | 85.28% | - | - | [84.85%](http://westphal.com.br/holo/ietf-ospfv3-extended-lsa.html) |
| ietf-rip@2020-02-20 | 27.91% | 93.33% | 100.00% | - | [55.41%](http://westphal.com.br/holo/ietf-rip.html) |
Expand Down
2 changes: 1 addition & 1 deletion holo-ospf/src/northbound/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ where
fn yang_modules() -> &'static [&'static str] {
&[
"ietf-ospf",
"ietf-ospf-sr",
"ietf-ospf-sr-mpls",
"ietf-ospfv3-extended-lsa",
"holo-ospf",
"holo-ospf-dev",
Expand Down
22 changes: 11 additions & 11 deletions holo-ospf/src/northbound/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1314,7 +1314,7 @@ fn load_callbacks_ospfv2() -> Callbacks<Instance<Ospfv2>> {
// TODO: implement me!
None
})
.path(ospf::database::as_scope_lsa_type::as_scope_lsas::as_scope_lsa::ospfv2::body::opaque::extended_prefix_opaque::extended_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::prefix_sid_flags::bits::PATH)
.path(ospf::database::as_scope_lsa_type::as_scope_lsas::as_scope_lsa::ospfv2::body::opaque::extended_prefix_opaque::extended_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::prefix_sid_flags::flags::PATH)
.get_iterate(|_instance, _args| {
// TODO: implement me!
None
Expand Down Expand Up @@ -1885,7 +1885,7 @@ fn load_callbacks_ospfv2() -> Callbacks<Instance<Ospfv2>> {
.map(ListEntry::Ospfv2PrefixSid);
Some(Box::new(iter))
})
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv2::body::opaque::extended_prefix_opaque::extended_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::prefix_sid_flags::bits::PATH)
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv2::body::opaque::extended_prefix_opaque::extended_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::prefix_sid_flags::flags::PATH)
.get_iterate(|_instance, args| {
let prefix_sid = args.parent_list_entry.as_ospfv2_prefix_sid().unwrap();
let flags = prefix_sid.flags.to_yang_bits();
Expand Down Expand Up @@ -2029,7 +2029,7 @@ fn load_callbacks_ospfv2() -> Callbacks<Instance<Ospfv2>> {
None
}
})
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv2::body::opaque::extended_link_opaque::extended_link_tlv::adj_sid_sub_tlvs::adj_sid_sub_tlv::adj_sid_flags::bits::PATH)
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv2::body::opaque::extended_link_opaque::extended_link_tlv::adj_sid_sub_tlvs::adj_sid_sub_tlv::adj_sid_flags::flags::PATH)
.get_iterate(|_instance, args| {
let adj_sid = args.parent_list_entry.as_ospfv2_adj_sid().unwrap();
let flags = adj_sid.flags.to_yang_bits();
Expand Down Expand Up @@ -2072,7 +2072,7 @@ fn load_callbacks_ospfv2() -> Callbacks<Instance<Ospfv2>> {
None
}
})
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv2::body::opaque::extended_link_opaque::extended_link_tlv::lan_adj_sid_sub_tlvs::lan_adj_sid_sub_tlv::lan_adj_sid_flags::bits::PATH)
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv2::body::opaque::extended_link_opaque::extended_link_tlv::lan_adj_sid_sub_tlvs::lan_adj_sid_sub_tlv::lan_adj_sid_flags::flags::PATH)
.get_iterate(|_instance, args| {
let adj_sid = args.parent_list_entry.as_ospfv2_adj_sid().unwrap();
let flags = adj_sid.flags.to_yang_bits();
Expand Down Expand Up @@ -2490,7 +2490,7 @@ fn load_callbacks_ospfv2() -> Callbacks<Instance<Ospfv2>> {
.get_iterate(|_instance, _args| {
None
})
.path(ospf::areas::area::interfaces::interface::database::link_scope_lsa_type::link_scope_lsas::link_scope_lsa::ospfv2::body::opaque::extended_prefix_opaque::extended_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::prefix_sid_flags::bits::PATH)
.path(ospf::areas::area::interfaces::interface::database::link_scope_lsa_type::link_scope_lsas::link_scope_lsa::ospfv2::body::opaque::extended_prefix_opaque::extended_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::prefix_sid_flags::flags::PATH)
.get_iterate(|_instance, _args| {
None
})
Expand Down Expand Up @@ -3049,7 +3049,7 @@ fn load_callbacks_ospfv3() -> Callbacks<Instance<Ospfv3>> {
// TODO: implement me!
None
})
.path(ospf::database::as_scope_lsa_type::as_scope_lsas::as_scope_lsa::ospfv3::body::e_as_external::e_external_tlvs::external_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::bits::PATH)
.path(ospf::database::as_scope_lsa_type::as_scope_lsas::as_scope_lsa::ospfv3::body::e_as_external::e_external_tlvs::external_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::flags::PATH)
.get_iterate(|_instance, _args| {
// TODO: implement me!
None
Expand Down Expand Up @@ -3677,7 +3677,7 @@ fn load_callbacks_ospfv3() -> Callbacks<Instance<Ospfv3>> {
.map(ListEntry::Ospfv3AdjSid);
Some(Box::new(iter))
})
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_router::e_router_tlvs::link_tlv::adj_sid_sub_tlvs::adj_sid_sub_tlv::adj_sid_flags::bits::PATH)
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_router::e_router_tlvs::link_tlv::adj_sid_sub_tlvs::adj_sid_sub_tlv::adj_sid_flags::flags::PATH)
.get_iterate(|_instance, args| {
let adj_sid = args.parent_list_entry.as_ospfv3_adj_sid().unwrap();
let flags = adj_sid.flags.to_yang_bits();
Expand Down Expand Up @@ -3708,7 +3708,7 @@ fn load_callbacks_ospfv3() -> Callbacks<Instance<Ospfv3>> {
.map(ListEntry::Ospfv3AdjSid);
Some(Box::new(iter))
})
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_router::e_router_tlvs::link_tlv::lan_adj_sid_sub_tlvs::lan_adj_sid_sub_tlv::lan_adj_sid_flags::bits::PATH)
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_router::e_router_tlvs::link_tlv::lan_adj_sid_sub_tlvs::lan_adj_sid_sub_tlv::lan_adj_sid_flags::flags::PATH)
.get_iterate(|_instance, args| {
let adj_sid = args.parent_list_entry.as_ospfv3_adj_sid().unwrap();
let flags = adj_sid.flags.to_yang_bits();
Expand Down Expand Up @@ -3897,7 +3897,7 @@ fn load_callbacks_ospfv3() -> Callbacks<Instance<Ospfv3>> {
None
}
})
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_inter_area_prefix::e_inter_prefix_tlvs::inter_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::bits::PATH)
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_inter_area_prefix::e_inter_prefix_tlvs::inter_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::flags::PATH)
.get_iterate(|_instance, args| {
let prefix_sid = args.parent_list_entry.as_ospfv3_prefix_sid().unwrap();
let flags = prefix_sid.flags.to_yang_bits();
Expand Down Expand Up @@ -4127,7 +4127,7 @@ fn load_callbacks_ospfv3() -> Callbacks<Instance<Ospfv3>> {
.map(ListEntry::Ospfv3PrefixSid);
Some(Box::new(iter))
})
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_intra_area_prefix::e_intra_prefix_tlvs::intra_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::bits::PATH)
.path(ospf::areas::area::database::area_scope_lsa_type::area_scope_lsas::area_scope_lsa::ospfv3::body::e_intra_area_prefix::e_intra_prefix_tlvs::intra_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::flags::PATH)
.get_iterate(|_instance, args| {
let prefix_sid = args.parent_list_entry.as_ospfv3_prefix_sid().unwrap();
let flags = prefix_sid.flags.to_yang_bits();
Expand Down Expand Up @@ -4624,7 +4624,7 @@ fn load_callbacks_ospfv3() -> Callbacks<Instance<Ospfv3>> {
// TODO: implement me!
None
})
.path(ospf::areas::area::interfaces::interface::database::link_scope_lsa_type::link_scope_lsas::link_scope_lsa::ospfv3::body::e_link::e_link_tlvs::intra_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::bits::PATH)
.path(ospf::areas::area::interfaces::interface::database::link_scope_lsa_type::link_scope_lsas::link_scope_lsa::ospfv3::body::e_link::e_link_tlvs::intra_prefix_tlv::prefix_sid_sub_tlvs::prefix_sid_sub_tlv::ospfv3_prefix_sid_flags::flags::PATH)
.get_iterate(|_instance, _args| {
// TODO: implement me!
None
Expand Down
20 changes: 10 additions & 10 deletions holo-ospf/src/northbound/yang.rs
Original file line number Diff line number Diff line change
Expand Up @@ -166,19 +166,19 @@ impl ToYangBits for PrefixSidFlags {
let mut flags = vec![];

if self.contains(PrefixSidFlags::NP) {
flags.push("ietf-ospf-sr:np-bit");
flags.push("ietf-ospf-sr-mpls:np-bit");
}
if self.contains(PrefixSidFlags::M) {
flags.push("ietf-ospf-sr:m-bit");
flags.push("ietf-ospf-sr-mpls:m-bit");
}
if self.contains(PrefixSidFlags::E) {
flags.push("ietf-ospf-sr:e-bit");
flags.push("ietf-ospf-sr-mpls:e-bit");
}
if self.contains(PrefixSidFlags::V) {
flags.push("ietf-ospf-sr:v-bit");
flags.push("ietf-ospf-sr-mpls:v-bit");
}
if self.contains(PrefixSidFlags::L) {
flags.push("ietf-ospf-sr:l-bit");
flags.push("ietf-ospf-sr-mpls:l-bit");
}

flags
Expand All @@ -190,19 +190,19 @@ impl ToYangBits for AdjSidFlags {
let mut flags = vec![];

if self.contains(AdjSidFlags::B) {
flags.push("ietf-ospf-sr:b-bit");
flags.push("ietf-ospf-sr-mpls:b-bit");
}
if self.contains(AdjSidFlags::V) {
flags.push("ietf-ospf-sr:vi-bit");
flags.push("ietf-ospf-sr-mpls:vi-bit");
}
if self.contains(AdjSidFlags::L) {
flags.push("ietf-ospf-sr:lo-bit");
flags.push("ietf-ospf-sr-mpls:lo-bit");
}
if self.contains(AdjSidFlags::G) {
flags.push("ietf-ospf-sr:g-bit");
flags.push("ietf-ospf-sr-mpls:g-bit");
}
if self.contains(AdjSidFlags::P) {
flags.push("ietf-ospf-sr:p-bit");
flags.push("ietf-ospf-sr-mpls:p-bit");
}

flags
Expand Down
Loading

0 comments on commit 099c571

Please sign in to comment.