summaryrefslogtreecommitdiffstats
path: root/lib/if.h
diff options
context:
space:
mode:
authorEmanuele Di Pascale <emanuele@voltanet.io>2020-05-19 15:53:02 +0200
committerEmanuele Di Pascale <emanuele@voltanet.io>2020-05-19 17:08:04 +0200
commit5eb567edc8980ef8a9a70e12bdfce2d5b3b09374 (patch)
treef2ad762932013a97aa1fa2dfdf3f16ab54a43ac4 /lib/if.h
parentMerge pull request #6351 from opensourcerouting/fpm-nh (diff)
downloadfrr-5eb567edc8980ef8a9a70e12bdfce2d5b3b09374.tar.xz
frr-5eb567edc8980ef8a9a70e12bdfce2d5b3b09374.zip
lib: fix bandwidth multiplier for link param
in the CLI we state that the bandwidth of a link is in Megabits per second, but when converting it to Bytes per second for TE purposes we were treating it as Kilobits. Fix the conversion error. Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
Diffstat (limited to 'lib/if.h')
-rw-r--r--lib/if.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/if.h b/lib/if.h
index 6a3680656..8dc418f20 100644
--- a/lib/if.h
+++ b/lib/if.h
@@ -143,7 +143,7 @@ struct if_stats {
#define TE_EXT_MASK 0x0FFFFFFF
#define TE_EXT_ANORMAL 0x80000000
#define LOSS_PRECISION 0.000003
-#define TE_KILO_BIT 1000
+#define TE_MEGA_BIT 1000000
#define TE_BYTE 8
#define DEFAULT_BANDWIDTH 10000
#define MAX_CLASS_TYPE 8