Commit graph

234 commits

Author SHA1 Message Date
Mark Stapp e88f0a4778 isisd: clean up -Wshadow warnings
Clean up various "shadow" warnings.

Signed-off-by: Mark Stapp <mjs@cisco.com>
2025-04-08 14:41:26 -04:00
Donald Sharp 1014901021
Merge pull request #17044 from baozhen-H3C/202410091476
isisd: Lsp fragments will delete the corresponding dyn_cache entry.
2024-10-10 18:41:27 -04:00
baozhen-H3C c2b70369b6 isisd: Lsp fragments will delete the corresponding dyn_cache entry.
When LSP fragments age, isis_dynhn_remove() is also called to remove the corresponding dyhn_cache entries.

Signed-off-by: baozhen-H3C <bao.zhen@h3c.com>
2024-10-09 19:41:07 +08:00
Donatas Abraitis 17206eb818 isisd: Remove deprecated JSON fields
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2024-09-19 23:44:25 +03:00
Philippe Guibert 4e76df0547 isis, lib: add isis srv6 end sid to ls_prefix
According to draft-ietf-lsr-isis-srv6-extensions draft,
the End SID should be available in link state prefix
information.

Add the SID information in the link state prefix, by
getting the END SID from the locator TLV information.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2024-07-11 09:14:34 +02:00
Russ White 685712df44
Merge pull request #16241 from zhou-run/202406191740
isisd: The neighbor entry still displays the deleted hostname of the neighbor.
2024-07-09 11:40:26 -04:00
zhou-run f54970ff43 isisd: The neighbor entry still displays the deleted hostname of the neighbor
1. The lsp_update_data() function will check for the presence of the ISIS_TLV_DYNAMIC_HOSTNAME in the LSP, and then call isis_dynhn_insert() to add a hostname entry corresponding to the LSP ID. However, when the ISIS_TLV_DYNAMIC_HOSTNAME is not present in the LSP, the hostname entry corresponding to the LSP ID should also be deleted.
2. The command “show isis neighbor” invokes isis_adj_name() to display the System ID or hostname, but it does not check the area->dynhostname flag.
3. When the LSP expires and is removed, the corresponding hostname entry should also be deleted.
4. The TLV for LSP fragmentation will not contain the hostname and should be skipped.

Signed-off-by: zhou-run <zhou.run@h3c.com>
2024-07-08 15:53:46 +08:00
Carmine Scarpitta 9ae38eede8 isisd: Deal with SRv6 locator instead of chunk
Currently, when SRv6 is enabled in IS-IS, IS-IS requests a locator chunk
from Zebra. Zebra assigns a locator chunk to IS-IS, and then IS-IS can
allocate SIDs from the locator chunk.

Recently, the implementation of SRv6 in Zebra has been improved, and a
new API has been introduced for obtaining/releasing the SIDs.

Now, the daemons no longer need to request a chunk.

Instead, the daemons interact with Zebra to obtain information about the
locator and subsequently to allocate/release the SIDs.

This commit extends IS-IS to use the new SRv6 API. In particular, it
removes the chunk throughout the IS-IS code and modifies IS-IS to
request/save/advertise the locator instead of the chunk.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2024-06-18 18:33:29 +02:00
Russ White 64f447fb10
Merge pull request #11906 from louis-6wind/show_isis_db_json
isisd: fix show isis database [detail] json
2024-06-06 16:27:57 -04:00
zhou-run 6924749bfe isisd: fix crash when deactivating ISIS adjacency on the interface.
1. When the command "no <ip|ipv6> router isis WORD" is executed on the interface, it invokes list_delete_all_node to iterate and release the memory of all nodes in the cirtcuit->u.bc.adjdb[1] linked list. However, the nodes are not unlinked during this traversal process, leading to the call of *list->del to delete the data of the linked list nodes.

2. For ISIS, deleting the data of the linked list nodes is done by calling isis_delete_adj. Subsequently, isis_level2_adj_up will be called to iterate and query the cirtcuit->u.bc.adjdb[1] linked list. If there are many neighbors on this interface, accessing the memory of the released linked list nodes may occur.

3. Not limited to ISIS, if the linked list is not unlinked during the deletion of all nodes in process 1, *list->del should not be allowed to iterate through the list again.

The backtrace is as follows:

(gdb) bt
    at isisd/isis_csm.c:196
    context=<optimized out>) at lib/northbound.c:1131
    errmsg_len=errmsg_len@entry=8192) at lib/northbound.c:1356
    at lib/northbound.c:1473
    errmsg=errmsg@entry=0x7ffc0ced38d0 "", errmsg_len=errmsg_len@entry=8192) at lib/northbound.c:906
    comment=comment@entry=0x0, transaction_id=transaction_id@entry=0x0, errmsg=errmsg@entry=0x7ffc0ced38d0 "", errmsg_len=8192) at lib/northbound.c:938
    filter=FILTER_RELAXED) at lib/command.c:971
    at lib/command.c:1030
    vtysh=vtysh@entry=0) at lib/command.c:1198
    at isisd/isis_csm.c:196
    context=<optimized out>) at lib/northbound.c:1131
    errmsg_len=errmsg_len@entry=8192) at lib/northbound.c:1356
    at lib/northbound.c:1473
    errmsg=errmsg@entry=0x7ffc0ced38d0 "", errmsg_len=errmsg_len@entry=8192) at lib/northbound.c:906
    comment=comment@entry=0x0, transaction_id=transaction_id@entry=0x0, errmsg=errmsg@entry=0x7ffc0ced38d0 "", errmsg_len=8192) at lib/northbound.c:938
    filter=FILTER_RELAXED) at lib/command.c:971
    at lib/command.c:1030
    vtysh=vtysh@entry=0) at lib/command.c:1198
0  0x00007f7d6e541fe1 in raise () from /lib/x86_64-linux-gnu/libpthread.so.0
1  0x00007f7d6e63188c in core_handler (signo=11, siginfo=0x7ffc0ced2630, context=<optimized out>) at lib/sigevent.c:262
2  <signal handler called>
3  0x00005647f5b11568 in isis_level2_adj_up (area=area@entry=0x5647f7c89830) at isisd/isis_lsp.c:423
4  0x00005647f5b14073 in isis_reset_attach_bit (adj=0x5647f7cad690) at isisd/isis_lsp.c:474
5  lsp_handle_adj_state_change (adj=0x5647f7cad690) at isisd/isis_lsp.c:2162
6  0x00005647f5b53675 in hook_call_isis_adj_state_change_hook (adj=adj@entry=0x5647f7cad690) at isisd/isis_adjacency.c:152
7  0x00005647f5b536f3 in isis_delete_adj (arg=0x5647f7cad690) at isisd/isis_adjacency.c:167
8  0x00007f7d6e5fe003 in list_delete_all_node (list=0x5647f7c88060) at lib/linklist.c:316
9  0x00007f7d6e5fe069 in list_delete (list=list@entry=0x5647f7c84708) at lib/linklist.c:326
10 0x00005647f5b0872e in isis_circuit_down (circuit=0x5647f7c84620) at isisd/isis_circuit.c:835
11 0x00005647f5b09f81 in isis_csm_state_change (event=event@entry=IF_DOWN_FROM_Z, circuit=circuit@entry=0x5647f7c84620, arg=arg@entry=0x5647f7c7f7a0)
   at isisd/isis_csm.c:196
12 0x00005647f5b083b0 in isis_circuit_disable (circuit=0x5647f7c84620) at isisd/isis_circuit.c:100
13 isis_circuit_del (circuit=0x5647f7c84620) at isisd/isis_circuit.c:200
14 0x00005647f5b434f5 in lib_interface_isis_destroy (args=<optimized out>) at isisd/isis_nb_config.c:2612
15 0x00007f7d6e61347a in nb_callback_destroy (errmsg_len=2, errmsg=0x7ffc0ced38d0 "", dnode=0x5647f7c948f0, event=NB_EV_APPLY, nb_node=<optimized out>,
   context=<optimized out>) at lib/northbound.c:1131
16 nb_callback_configuration (context=<optimized out>, event=event@entry=NB_EV_APPLY, change=change@entry=0x5647f7cb6680, errmsg=errmsg@entry=0x7ffc0ced38d0 "",
   errmsg_len=errmsg_len@entry=8192) at lib/northbound.c:1356
17 0x00007f7d6e6138b7 in nb_transaction_process (errmsg_len=8192, errmsg=0x7ffc0ced38d0 "", transaction=0x5647f7c94080, event=NB_EV_APPLY)
   at lib/northbound.c:1473
18 nb_candidate_commit_apply (transaction=0x5647f7c94080, save_transaction=save_transaction@entry=true, transaction_id=transaction_id@entry=0x0,
   errmsg=errmsg@entry=0x7ffc0ced38d0 "", errmsg_len=errmsg_len@entry=8192) at lib/northbound.c:906
19 0x00007f7d6e61403d in nb_candidate_commit (context=context@entry=0x7ffc0ced38c0, candidate=<optimized out>, save_transaction=save_transaction@entry=true,
   comment=comment@entry=0x0, transaction_id=transaction_id@entry=0x0, errmsg=errmsg@entry=0x7ffc0ced38d0 "", errmsg_len=8192) at lib/northbound.c:938
20 0x00007f7d6e616ec9 in nb_cli_classic_commit (vty=0x5647f7cae160) at lib/northbound_cli.c:64
21 0x00007f7d6e6176a8 in nb_cli_apply_changes (vty=0x5647f7cae160, xpath_base_fmt=<optimized out>) at lib/northbound_cli.c:268
22 0x00007f7d6e5d918e in cmd_execute_command_real (vline=vline@entry=0x5647f7cae140, vty=vty@entry=0x5647f7cae160, cmd=cmd@entry=0x0, up_level=up_level@entry=0,
   filter=FILTER_RELAXED) at lib/command.c:971
23 0x00007f7d6e5d951d in cmd_execute_command (vline=vline@entry=0x5647f7cae140, vty=vty@entry=0x5647f7cae160, cmd=cmd@entry=0x0, vtysh=vtysh@entry=0)
   at lib/command.c:1030
24 0x00007f7d6e5d9770 in cmd_execute (vty=vty@entry=0x5647f7cae160, cmd=cmd@entry=0x5647f7cb48a0 "no ip router isis 10", matched=matched@entry=0x0,
   vtysh=vtysh@entry=0) at lib/command.c:1198
25 0x00007f7d6e6485e6 in vty_command (vty=vty@entry=0x5647f7cae160, buf=0x5647f7cb48a0 "no ip router isis 10") at lib/vty.c:483
26 0x00007f7d6e648d01 in vty_execute (vty=vty@entry=0x5647f7cae160) at lib/vty.c:1246
27 0x00007f7d6e64ba40 in vtysh_read (thread=<optimized out>) at lib/vty.c:2090
28 0x00007f7d6e64348d in thread_call (thread=thread@entry=0x7ffc0ced8310) at lib/thread.c:1958
29 0x00007f7d6e5fd4a8 in frr_run (master=0x5647f79a43d0) at lib/libfrr.c:1184
30 0x00005647f5b050f3 in main (argc=5, argv=<optimized out>, envp=<optimized out>) at isisd/isis_main.c:273
(gdb) f 3
423     isisd/isis_lsp.c: No such file or directory.
(gdb) p node
$1 = (struct listnode *) 0x110
(gdb) f 8
316     lib/linklist.c: No such file or directory.
(gdb) p list->head->data
$2 = (void *) 0x5647f7cabf20
(gdb) p list->head->next->data
$3 = (void *) 0x5647f7c9bb60
(gdb) p list->head->next->next->data
Cannot access memory at address 0x120
(gdb) p list->head->next->next
$4 = (struct listnode *) 0x110

The backtrace provided above pertains to version 8.2.2, but it seems that the same issue exists in the code of the master branch as well.

isis_reset_attach_bit() is useless because lsp_handle_adj_state_change() unconditionally calls lsp_regenerate_schedule.

Signed-off-by: zhou-run <166502045+zhou-run@users.noreply.github.com>
2024-05-28 17:55:58 +08:00
Louis Scalbert d5879267aa isisd: fix show database json format
"show isis database [detail] json" returns invalid or incorrect JSON
that is difficult to parse.

Fix key with '-' characters, add booleans and null data when possible.
Deprecate the old format.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2024-05-23 14:43:21 +02:00
anlan_cs 639d8027f1 isisd: fix json display for database command
The current json display lost a lot of LSPs, added them.

Fixed the json format for two commands:
"show isis database detail json"
"show isis database json"

Signed-off-by: anlan_cs <anlan_cs@tom.com>
2024-05-07 14:23:06 +08:00
lynnemorrison 1f201c6f03 isisd: Fix dislaying LSP ID
If "no hostname dynamic" command is used this fix correctly
displays the LSP ID.

Signed-off-by: Lynne Morrison <lynne.morrison@ibm.com>
2023-12-04 19:41:28 -05:00
Carmine Scarpitta 604fcd30db isisd: Advertise SRv6 Locator in Prefix Reach TLV
According to RFC 9352 section #5, the SRv6 Locators associated with
algorithms 0 and 1 should be also advertised in a Prefix Reachability
TLV (236 or 237) to allow legacy routers (i.e., routers that do not
support SRv6) installing a forwarding entry for algorithms 0 and 1 SRv6
traffic.

This commits extend IS-IS to advertise SRv6 Locators in IPv6
Reachability TLV.

Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11 22:11:41 +02:00
Carmine Scarpitta 48d1cd1748 isisd: Add SRv6 Locator TLV to the LSP
Add the SRv6 Locator TLV and its Sub-TLV and Sub-Sub-TLVs to the LSP.

Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11 22:11:40 +02:00
Carmine Scarpitta 00a05b79b6 isisd: Add Node MSD Sub-TLV (SRv6) to the LSPs
Add Node MSD Sub-TLV containing the SRv6 MSDs to the Router Capabilities
TLV in the LSPs generated with the `lsp_build()` function.

Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-09-11 17:34:51 +02:00
Carmine Scarpitta b85ecd30a9 isisd: Add SRv6 Capabilities Sub-TLV to the LSPs
Add SRv6 Capabilities Sub-TLV to the Router Capabilities TLV in the LSPs
generated with the `lsp_build()` function.

Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
2023-08-04 09:29:16 +02:00
Louis Scalbert 3f55b8c621 isisd: fix disabled flex-algo on race condition
A particular flex-algo algorithm may remain in disabled state after
configuring it if its flex-algo definition is being spread in the area.

It happens sometimes that, in isis_sr_flex_algo_topo1 topotest, r3
flex-algo 203 is disabled on test8. It depends on the following
sequence on r3:
 1. a LSP containing the flex-algo 203 definition is received from
    either r1 or r2 (or both).
 2. the local LSP is rebuilt by lsp_build() because of the flex-algo 203
    configuration
 3. isis_run_spf() recomputes the algo 203 SPF tree

A 1. 2. 3. sequence results in a working test whereas 2. 1. 3. is not
working. The second case issue is because of an inconsistent flex-algo
definition state between the following:
 - in lsp_build(), isis_flex_algo_elected_supported_local_fad() returns
   false because no flex-algo definition is known.
 - in isis_run_spf(), isis_flex_algo_elected_supported() returns true
   because a flex-algo definition is found.

Set a flex-algo state lsp_build() depending on flex-algo definition
existence that is used later in isis_run_spf().

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2023-04-28 11:53:18 +02:00
Hiroki Shirokura 78774bbcd5 isisd: add isis flex-algo lsp advertisement
Deal with the packing and unpacking of following Flex-Algo
Sub-Sub-TLVs:

- Router Capability (already defined TLV 242)
	- List of the Flex-Algo Definitions (Sub-TLV 26)
		- Exclude admin group (Sub-Sub-TLV 1)
                - Include-any admin group (Sub-Sub-TLV 2)
                - Include-all admin group (Sub-Sub-TLV 3)
                - Flags (for prefix-metric) (Sub-Sub-TLV 4)

This commit splits data into multiple router capability TLVs if needed
because a TLV cannot contains more than 255 bytes.

Note that the list of SR Algorithm (Sub-TLV 19) within Router Capability
(TLV 242) is already set in a previous commit.

Signed-off-by: Hiroki Shirokura <hiroki.shirokura@linecorp.com>
Signed-off-by: Eric Kinzie <ekinzie@labn.net>
Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2023-04-18 11:33:15 +02:00
Louis Scalbert 484ab40511 isisd: refactor IP reachability lsp build
Refactor IP reachability lsp build to comply with checkpatch:

> WARNING: Too many leading tabs - consider code refactoring

No code logic change.

Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2023-04-18 10:11:52 +02:00
Hiroki Shirokura 0de7b43308 isisd: update isis_tlvs_add_*_reach() with multi algorithm
isis_tlvs_add_extended_ip_reach adds IS-IS Extended
IP reachability to the LSP. In this case, if the
pcfg argument is not NULL, you can add IGP
Prefix-SID as its sub tlv.

Before this commit, only one Prefix-SID can be added.
After this commit, the argument is not a single
pointer but an array of pointers, and multiple
Prefix-SIDs can be added.

This feature is necessary because Flex-Algo
requires multiple Prefix-SIDs for each Algorithm.

Signed-off-by: Hiroki Shirokura <hiroki.shirokura@linecorp.com>
Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2023-04-18 10:11:52 +02:00
Hiroki Shirokura e7948f8ce6 isisd: update SR_ALGORITHM_COUNT to 256
Before this commit, SR_ALGORITHM_COUNT was set to 2,
and each was hardcoded with router capability tlv.
When Flex-Algo is supported, SR-Algorithm may be
variably supported up to 256.

Signed-off-by: Hiroki Shirokura <hiroki.shirokura@linecorp.com>
Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2023-04-18 10:11:52 +02:00
Hiroki Shirokura 1f0d13e922 isisd: update struct sr_prefix_cfg with algorithm id
The information in prefix-sid has a new property
called algorithm id.  This is used to identify
the algorithm that separates it in the same IGP
network. This is used in Flex-Algo.In all other
cases, the algorithm id is basically 0.

Signed-off-by: Hiroki Shirokura <hiroki.shirokura@linecorp.com>
Signed-off-by: Louis Scalbert <louis.scalbert@6wind.com>
2023-04-17 11:06:08 +02:00
Russ White f26a87cd24
Merge pull request #12698 from Orange-OpenSource/isisd
Isisd/Lib: Add new printfrr format facility for Intermediate System ID
2023-04-11 09:49:01 -04:00
Donald Sharp 24a58196dd *: Convert event.h to frrevent.h
We should probably prevent any type of namespace collision
with something else.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-03-24 08:32:17 -04:00
Donald Sharp e16d030c65 *: Convert THREAD_XXX macros to EVENT_XXX macros
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-03-24 08:32:17 -04:00
Donald Sharp 5f6eaa9b96 *: Convert a bunch of thread_XX to event_XX
Convert these functions:

thread_getrusage
thread_cmd_init
thread_consumed_time
thread_timer_to_hhmmss
thread_is_scheduled
thread_ignore_late_timer

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-03-24 08:32:17 -04:00
Donald Sharp 4f830a0799 *: Convert thread_timer_remain_XXX to event_timer_remain_XXX
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-03-24 08:32:17 -04:00
Donald Sharp 907a2395f4 *: Convert thread_add_XXX functions to event_add_XXX
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-03-24 08:32:17 -04:00
Donald Sharp e6685141aa *: Rename struct thread to struct event
Effectively a massive search and replace of
`struct thread` to `struct event`.  Using the
term `thread` gives people the thought that
this event system is a pthread when it is not

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-03-24 08:32:17 -04:00
Donald Sharp cb37cb336a *: Rename thread.[ch] to event.[ch]
This is a first in a series of commits, whose goal is to rename
the thread system in FRR to an event system.  There is a continual
problem where people are confusing `struct thread` with a true
pthread.  In reality, our entire thread.c is an event system.

In this commit rename the thread.[ch] files to event.[ch].

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2023-03-24 08:32:16 -04:00
Olivier Dugeon 5d39a81907 isisd: Update to the new printfrr ISO format
This path replaces isisd_format_id, sysid_print, snpa_print, rawlspid_print and
isonet_print functions by the new printfrr ISO System ID & Network Address
format facilities. It also updates the isisd code to the new iso_address
structure defined in lib/iso.h

Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
2023-03-21 15:21:47 +01:00
Russ White 617d2b71c0
Merge pull request #12840 from dorDiogo/isis_advertise_passive_only
isisd: Add support for IS-IS advertise-passive-only
2023-02-28 09:22:32 -05:00
Russ White 4fa0162568
Merge pull request #12819 from isabelladeleon12/isis_load_config_before_lsp_gen
isisd: Delay lsp generation to after config processing is complete
2023-02-28 08:38:44 -05:00
Diogo Oliveira 3f3608d8d7 isisd,doc: Add support for isis advertise-passive-only
Signed-off-by: Diogo Oliveira <14191454+dorDiogo@users.noreply.github.com>
2023-02-22 13:44:48 -08:00
Isabella de Leon 3b0e97e150 isisd: Fix isisd to generate lsps after config processing is complete
Before:
isisd generates its initial lsp before fully processing the written config. Ex: lsp_generate() is called in isis_instance_area_address_create(), before other configs that may affect the lsp are loaded in, like set-overload-bit.

After:
isisd generates its initial lsp as soon as the config is fully processed. This was done by utilizing the initialization config callbacks, similar to bgp's implementation.

Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
2023-02-21 08:49:34 -08:00
David Lamparter acddc0ed3c *: auto-convert to SPDX License IDs
Done with a combination of regex'ing and banging my head against a wall.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2023-02-09 14:09:11 +01:00
Isabella de Leon 450841fe05 isisd: Add JSON object functions to save overload status between restarts.
Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
2022-10-12 16:57:32 -07:00
Isabella de Leon 4afc783610 isisd: Add expected behavior with set-overload-bit
Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
2022-10-12 10:52:27 -07:00
Isabella de Leon 49b27ea24d isisd: Add overload timer and overload on startup functionality
Signed-off-by: Isabella de Leon <ideleon@microsoft.com>
2022-09-30 10:39:18 -07:00
Donald Sharp fa935aa7e8 isisd: Convert thread_cancel to THREAD_OFF
Just convert all uses of thread_cancel to THREAD_OFF

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-07-21 08:30:50 -04:00
Donald Sharp 91a5bbc4de isisd: Fix crash with xfrm interface type
When creating a xfrm interface FRR is crashing when configured
with isis.  This is because the weird pattern of not allocating
list's until needed and then allowing the crash when we have
a usage pattern that was not expected.  Just always allocate
the different lists that a circuit needs.

(gdb) bt
(gdb)

Fixes #11432
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-06-23 14:06:49 -04:00
Russ White 82934a6a32
Merge pull request #10701 from rampxxxx/feat_isis_json_show_cmds
Feat isis json show cmds
2022-03-08 11:15:25 -05:00
Javier Garcia a2cac12a63 isisd: Add json to show isis database command.
Signed-off-by: Javier Garcia <javier.martin.garcia@ibm.com>
2022-03-02 16:20:44 +01:00
Donald Sharp cc9f21da22 *: Change thread->func to return void instead of int
The int return value is never used.  Modify the code
base to just return a void instead.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-02-23 19:56:04 -05:00
Olivier Dugeon d9884a758c isisd: Prepare IS-IS for Link State support
In order to provide Link State Traffic Engineering features to IS-IS, this
patch adds some modifications to base IS-IS:

- Solve bug in lsp iterate function to avoid infinite loop in isis_lsp.c by
  adding condition to recurse call
- Add new trigger event to parse LSP in isis_lsp.c
- Add new TE debug flag to track Traffic Engineering events in isisd.[c,h]
- Correct small bug in isis_tlvs.c where delay and min/max delay are not
  correctly handle
- Handle Opaque LSA Traffic Engineering Zebra API in isis_zebra.[c,h]

Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
2021-11-30 15:22:28 +01:00
Olivier Dugeon 173f8887cc isisd: Add support for RFC6119 (IPv6 TE in IS-IS)
- Add advertisement of Global IPv6 address in IIH pdu
 - Add new CLI to set IPv6 Router ID
 - Add advertisement of IPv6 Router ID
 - Correctly advertise IPv6 local and neighbor addresses in Extended IS and MT
   Reachability TLVs
 - Correct output of Neighbor IPv6 address in 'show isis database detail'
 - Manage IPv6 addresses advertisement and corresponiding Adjacency SID when
   IS-IS is not using Multi-Topology by introducing a new ISIS_MT_DISABLE
   value for mtid (== 4096 i.e. first reserved flag set to 1)

Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
2021-11-30 15:22:28 +01:00
Guillaume Solignac 9482949688 isisd: Fix sending of LSP with null seqno
Check sequence number when building LSP missing in received CSNP

Signed-off-by: Guillaume Solignac <gsoligna@protonmail.com>
2021-08-26 12:06:29 +02:00
Igor Ryzhov d0f1492145 isisd: fix setting IS type in LSPs
IS type in an LSP is a type of the router, not a type of the circuit.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2021-07-13 14:49:49 +03:00
Igor Ryzhov a4777e465a isisd: fix processing of the attached bit
There are two problems with the current code for processing the attached
bit:
- we should process it when acting both a level-1-only and level-1-2
- we should add the default route when we don't have L2 adjacensies, not
  when we don't have other routers configured on the device

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2021-07-13 14:49:49 +03:00