diff options
author | Neale Ranns <nranns@cisco.com> | 2017-07-15 07:37:25 -0700 |
---|---|---|
committer | Damjan Marion <dmarion.lists@gmail.com> | 2017-07-18 20:46:29 +0000 |
commit | 57b5860f013953ce161d05302e05370db9cd6ee2 (patch) | |
tree | 2d4cdbbc631848be4c43c599698019b2121e000b /src/vnet/fib/fib_types.h | |
parent | 51822bf07a3f0fe72834ea94659faf6e262475ba (diff) |
FIB path preference
Paths are given a preference, lowest value is 'best'. Only paths that are up are up contribute to fprwarding - that's unchanged. What's new is that of the path's that re up only those that have the best preference contribute. A poor man's primary and backup. It's not true primary/backup function because the FIB must converge before the lower preference paths are used.
Change-Id: Ie4453c4a7b1094c6c2b51fe1594b8302103bb68e
Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'src/vnet/fib/fib_types.h')
-rw-r--r-- | src/vnet/fib/fib_types.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/vnet/fib/fib_types.h b/src/vnet/fib/fib_types.h index 60873c4a9db..a7a23d74add 100644 --- a/src/vnet/fib/fib_types.h +++ b/src/vnet/fib/fib_types.h @@ -380,7 +380,13 @@ typedef struct fib_route_path_t_ { /** * [un]equal cost path weight */ - u32 frp_weight; + u16 frp_weight; + /** + * A path preference. 0 is the best. + * Only paths of the best preference, that are 'up', are considered + * for forwarding. + */ + u16 frp_preference; /** * flags on the path */ |