/* Return true if this prefix is on the per_prefix_list of prefixes to debug
* for BGP_DEBUG_TYPE
*/
-static int bgp_debug_per_prefix(struct prefix *p,
+static int bgp_debug_per_prefix(const struct prefix *p,
unsigned long term_bgp_debug_type,
unsigned int BGP_DEBUG_TYPE,
struct list *per_prefix_list)
bgp_debug_keepalive_peers);
}
-bool bgp_debug_update(struct peer *peer, struct prefix *p,
+bool bgp_debug_update(struct peer *peer, const struct prefix *p,
struct update_group *updgrp, unsigned int inbound)
{
char *host = NULL;
return false;
}
-bool bgp_debug_bestpath(struct prefix *p)
+bool bgp_debug_bestpath(struct bgp_node *rn)
{
if (BGP_DEBUG(bestpath, BESTPATH)) {
- if (bgp_debug_per_prefix(p, term_bgp_debug_bestpath,
- BGP_DEBUG_BESTPATH,
- bgp_debug_bestpath_prefixes))
+ if (bgp_debug_per_prefix(
+ bgp_node_get_prefix(rn), term_bgp_debug_bestpath,
+ BGP_DEBUG_BESTPATH, bgp_debug_bestpath_prefixes))
return true;
}
return false;
}
-bool bgp_debug_zebra(struct prefix *p)
+bool bgp_debug_zebra(const struct prefix *p)
{
if (BGP_DEBUG(zebra, ZEBRA)) {
if (bgp_debug_per_prefix(p, term_bgp_debug_zebra,
}
const char *bgp_debug_rdpfxpath2str(afi_t afi, safi_t safi,
- struct prefix_rd *prd,
+ const struct prefix_rd *prd,
union prefixconstptr pu,
mpls_label_t *label, uint32_t num_labels,
int addpath_valid, uint32_t addpath_id,