diff options
| author | Donatas Abraitis <donatas@opensourcerouting.org> | 2023-06-07 22:15:43 +0300 | 
|---|---|---|
| committer | Donatas Abraitis <donatas@opensourcerouting.org> | 2023-06-07 22:27:29 +0300 | 
| commit | 78981a80c7457b96e73c108280577d4cbb8aee03 (patch) | |
| tree | 309c6632f4550a8b43c3a827d68f77d4db01a16f /bgpd/bgp_route.h | |
| parent | 0ec8b2d86983fce00875b3d8f8c966955ee11346 (diff) | |
bgpd: Implement `neighbor X addpath-tx-best-selected` command
When using `addpath-tx-all` BGP announces all known paths instead of announcing
only an arbitrary number of best paths.
With this new command we can send N best paths to the neighbor. That means, we
send the best path, then send the second best path excluding the previous one,
and so on. In other words, we run best path selection algorithm N times before
we finish.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
Diffstat (limited to 'bgpd/bgp_route.h')
| -rw-r--r-- | bgpd/bgp_route.h | 5 | 
1 files changed, 5 insertions, 0 deletions
diff --git a/bgpd/bgp_route.h b/bgpd/bgp_route.h index 9bd9e48e22..311d181f90 100644 --- a/bgpd/bgp_route.h +++ b/bgpd/bgp_route.h @@ -886,6 +886,11 @@ extern void bgp_path_info_add_with_caller(const char *caller,  					  struct bgp_dest *dest,  					  struct bgp_path_info *pi);  extern void bgp_aggregate_free(struct bgp_aggregate *aggregate); +extern int bgp_path_info_cmp(struct bgp *bgp, struct bgp_path_info *new, +			     struct bgp_path_info *exist, int *paths_eq, +			     struct bgp_maxpaths_cfg *mpath_cfg, int debug, +			     char *pfx_buf, afi_t afi, safi_t safi, +			     enum bgp_path_selection_reason *reason);  #define bgp_path_info_add(A, B)                                                \  	bgp_path_info_add_with_caller(__func__, (A), (B))  #define bgp_path_info_free(B) bgp_path_info_free_with_caller(__func__, (B))  | 
