diff options
| author | Renato Westphal <renato@opensourcerouting.org> | 2020-11-13 23:28:07 -0300 | 
|---|---|---|
| committer | Renato Westphal <renato@opensourcerouting.org> | 2020-11-24 20:15:51 -0300 | 
| commit | 35f70ed3f9f1379e7a0b5ff339562e97e7c24a5e (patch) | |
| tree | c570b932af01f3a5cc51a0d534f3ed5a4bcee58e /isisd/isis_ldp_sync.c | |
| parent | 6dfb7f5961d8a502b92718172c2e87dcf5db4046 (diff) | |
isisd: move and rename the infinity metric constants
Those constants are also useful in contexts other than LDP-IGP
Synchronization (e.g. the upcoming LFA work will need them). Move
them to a more general header to reflect that.
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'isisd/isis_ldp_sync.c')
| -rw-r--r-- | isisd/isis_ldp_sync.c | 12 | 
1 files changed, 8 insertions, 4 deletions
diff --git a/isisd/isis_ldp_sync.c b/isisd/isis_ldp_sync.c index 988af64c48..3b1faffe53 100644 --- a/isisd/isis_ldp_sync.c +++ b/isisd/isis_ldp_sync.c @@ -429,20 +429,24 @@ void isis_ldp_sync_set_if_metric(struct isis_circuit *circuit, bool run_regen)  			if (circuit->area->newmetric) {  				ldp_sync_info->metric[0] =  					circuit->te_metric[0]; -				circuit->te_metric[0] = LDP_ISIS_LSINFINITY; +				circuit->te_metric[0] = +					ISIS_WIDE_METRIC_INFINITY;  			} else {  				ldp_sync_info->metric[0] = circuit->metric[0]; -				circuit->metric[0] = LDP_ISIS_LSINFINITY_NL; +				circuit->metric[0] = +					ISIS_NARROW_METRIC_INFINITY;  			}  		}  		if (circuit->is_type & IS_LEVEL_2) {  			if (circuit->area->newmetric) {  				ldp_sync_info->metric[1] =  					circuit->te_metric[1]; -				circuit->te_metric[1] = LDP_ISIS_LSINFINITY; +				circuit->te_metric[1] = +					ISIS_WIDE_METRIC_INFINITY;  			} else {  				ldp_sync_info->metric[1] = circuit->metric[1]; -				circuit->metric[1] = LDP_ISIS_LSINFINITY_NL; +				circuit->metric[1] = +					ISIS_NARROW_METRIC_INFINITY;  			}  		}  	} else {  | 
