diff --git a/doc/user/isisd.rst b/doc/user/isisd.rst index 84d6e7bcfa..17e772b5f7 100644 --- a/doc/user/isisd.rst +++ b/doc/user/isisd.rst @@ -206,7 +206,7 @@ ISIS interface Add padding to IS-IS hello packets. -.. clicmd:: isis hello padding sometimes +.. clicmd:: isis hello padding during-adjacency-formation Add padding to IS-IS hello packets during adjacency formation only. diff --git a/isisd/isis_circuit.c b/isisd/isis_circuit.c index ebf9901c52..6d300236ae 100644 --- a/isisd/isis_circuit.c +++ b/isisd/isis_circuit.c @@ -1327,9 +1327,9 @@ static int isis_interface_config_write(struct vty *vty) vty_out(vty, " no " PROTO_NAME " hello padding\n"); write++; break; - case ISIS_HELLO_PADDING_SOMETIMES: + case ISIS_HELLO_PADDING_DURING_ADJACENCY_FORMATION: vty_out(vty, PROTO_NAME - " hello padding sometimes\n"); + " hello padding during-adjacency-formation\n"); write++; break; case ISIS_HELLO_PADDING_ALWAYS: diff --git a/isisd/isis_circuit.h b/isisd/isis_circuit.h index 58aa28195f..df977893ee 100644 --- a/isisd/isis_circuit.h +++ b/isisd/isis_circuit.h @@ -69,7 +69,7 @@ struct isis_circuit_arg { enum isis_hello_padding { ISIS_HELLO_PADDING_ALWAYS, ISIS_HELLO_PADDING_DISABLED, - ISIS_HELLO_PADDING_SOMETIMES + ISIS_HELLO_PADDING_DURING_ADJACENCY_FORMATION }; struct isis_circuit { diff --git a/isisd/isis_cli.c b/isisd/isis_cli.c index f430ded745..69636e6efc 100644 --- a/isisd/isis_cli.c +++ b/isisd/isis_cli.c @@ -2240,7 +2240,7 @@ void cli_show_ip_isis_threeway_shake(struct vty *vty, * XPath: /frr-interface:lib/interface/frr-isisd:isis/hello/padding */ DEFPY_YANG(isis_hello_padding, isis_hello_padding_cmd, - "[no] isis hello padding [sometimes]$padding_type", + "[no] isis hello padding [during-adjacency-formation]$padding_type", NO_STR "IS-IS routing protocol\n" "Type of padding for IS-IS hello packets\n" @@ -2266,8 +2266,8 @@ void cli_show_ip_isis_hello_padding(struct vty *vty, if (hello_padding_type == ISIS_HELLO_PADDING_DISABLED) vty_out(vty, " no"); vty_out(vty, " isis hello padding"); - if (hello_padding_type == ISIS_HELLO_PADDING_SOMETIMES) - vty_out(vty, " sometimes"); + if (hello_padding_type == ISIS_HELLO_PADDING_DURING_ADJACENCY_FORMATION) + vty_out(vty, " during-adjacency-formation"); vty_out(vty, "\n"); } diff --git a/isisd/isis_misc.c b/isisd/isis_misc.c index 7c6d600362..95d24036ec 100644 --- a/isisd/isis_misc.c +++ b/isisd/isis_misc.c @@ -299,8 +299,8 @@ const char *isis_hello_padding2string(int hello_padding_type) switch (hello_padding_type) { case ISIS_HELLO_PADDING_DISABLED: return "no"; - case ISIS_HELLO_PADDING_SOMETIMES: - return "sometimes"; + case ISIS_HELLO_PADDING_DURING_ADJACENCY_FORMATION: + return "during-adjacency-formation"; case ISIS_HELLO_PADDING_ALWAYS: return "yes"; } diff --git a/isisd/isis_pdu.c b/isisd/isis_pdu.c index 9ddc427c13..f659f3abc3 100644 --- a/isisd/isis_pdu.c +++ b/isisd/isis_pdu.c @@ -1966,7 +1966,8 @@ int send_hello(struct isis_circuit *circuit, int level) bool should_pad_hello = circuit->pad_hellos == ISIS_HELLO_PADDING_ALWAYS || - (circuit->pad_hellos == ISIS_HELLO_PADDING_SOMETIMES && + (circuit->pad_hellos == + ISIS_HELLO_PADDING_DURING_ADJACENCY_FORMATION && circuit->upadjcount[0] + circuit->upadjcount[1] == 0); if (isis_pack_tlvs(tlvs, circuit->snd_stream, len_pointer, diff --git a/isisd/isis_snmp.c b/isisd/isis_snmp.c index b4ae063639..e0bcb180b0 100644 --- a/isisd/isis_snmp.c +++ b/isisd/isis_snmp.c @@ -2162,7 +2162,8 @@ static uint8_t *isis_snmp_find_circ(struct variable *v, oid *name, * return false if lan hellos must be padded */ if (circuit->pad_hellos == ISIS_HELLO_PADDING_ALWAYS || - (circuit->pad_hellos == ISIS_HELLO_PADDING_SOMETIMES && + (circuit->pad_hellos == + ISIS_HELLO_PADDING_DURING_ADJACENCY_FORMATION && circuit->upadjcount[0] + circuit->upadjcount[1] == 0)) return SNMP_INTEGER(ISIS_SNMP_TRUTH_VALUE_FALSE); diff --git a/tests/topotests/isis_topo1/test_isis_topo1.py b/tests/topotests/isis_topo1/test_isis_topo1.py index 5e660ef9e1..48e9d5336f 100644 --- a/tests/topotests/isis_topo1/test_isis_topo1.py +++ b/tests/topotests/isis_topo1/test_isis_topo1.py @@ -572,9 +572,9 @@ def test_isis_advertise_passive_only(): assert result is True, result -def test_isis_hello_padding_sometimes(): +def test_isis_hello_padding_during_adjacency_formation(): """Check that IIH packets is only padded when adjacency is still being formed - when isis hello padding sometimes is configured + when isis hello padding during-adjacency-formation is configured """ tgen = get_topogen() net = get_topogen().net @@ -582,7 +582,7 @@ def test_isis_hello_padding_sometimes(): if tgen.routers_have_failure(): pytest.skip(tgen.errors) - logger.info("Testing isis hello padding sometimes behavior") + logger.info("Testing isis hello padding during-adjacency-formation behavior") r3 = tgen.gears["r3"] # Reduce hello-multiplier to make the adjacency go down faster. @@ -599,7 +599,7 @@ def test_isis_hello_padding_sometimes(): """ configure interface r1-eth0 - isis hello padding sometimes + isis hello padding during-adjacency-formation end debug isis adj-packets """ diff --git a/yang/frr-isisd.yang b/yang/frr-isisd.yang index f2927339ad..c072be45d9 100644 --- a/yang/frr-isisd.yang +++ b/yang/frr-isisd.yang @@ -128,7 +128,7 @@ module frr-isisd { description "Do not add any padding to hello packets."; } - enum "sometimes" { + enum "during-adjacency-formation" { value 2; description "Add padding to hello packets during adjacency formation only.";