diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2020-03-24 12:58:08 +0100 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2020-03-26 21:22:00 +0100 |
commit | 5f040085bad9cff365fe4bed0696ccf7494840b5 (patch) | |
tree | 45901dd8c4d9b02af6f1db55c8318a47fca1aa6e /bgpd/bgp_attr.h | |
parent | lib: make oid_copy_addr respect my constness (diff) | |
download | frr-5f040085bad9cff365fe4bed0696ccf7494840b5.tar.xz frr-5f040085bad9cff365fe4bed0696ccf7494840b5.zip |
lib, bgpd: Another round of `struct const prefix` cleanup
Cleanup another set of functions that need to respect the
const'ness of a prefix.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'bgpd/bgp_attr.h')
-rw-r--r-- | bgpd/bgp_attr.h | 26 |
1 files changed, 12 insertions, 14 deletions
diff --git a/bgpd/bgp_attr.h b/bgpd/bgp_attr.h index 04b3a20d6..98a9a620f 100644 --- a/bgpd/bgp_attr.h +++ b/bgpd/bgp_attr.h @@ -310,14 +310,11 @@ extern void bgp_attr_unintern_sub(struct attr *); extern void bgp_attr_unintern(struct attr **); extern void bgp_attr_flush(struct attr *); extern struct attr *bgp_attr_default_set(struct attr *attr, uint8_t); -extern struct attr *bgp_attr_aggregate_intern(struct bgp *bgp, uint8_t origin, - struct aspath *aspath, - struct community *community, - struct ecommunity *ecommunity, - struct lcommunity *lcommunity, - struct bgp_aggregate *aggregate, - uint8_t atomic_aggregate, - struct prefix *p); +extern struct attr *bgp_attr_aggregate_intern( + struct bgp *bgp, uint8_t origin, struct aspath *aspath, + struct community *community, struct ecommunity *ecommunity, + struct lcommunity *lcommunity, struct bgp_aggregate *aggregate, + uint8_t atomic_aggregate, const struct prefix *p); extern bgp_size_t bgp_packet_attribute(struct bgp *bgp, struct peer *, struct stream *, struct attr *, struct bpacket_attr_vec_arr *vecarr, @@ -372,20 +369,21 @@ extern size_t bgp_packet_mpattr_start(struct stream *s, struct peer *peer, struct bpacket_attr_vec_arr *vecarr, struct attr *attr); extern void bgp_packet_mpattr_prefix(struct stream *s, afi_t afi, safi_t safi, - struct prefix *p, struct prefix_rd *prd, + const struct prefix *p, + const struct prefix_rd *prd, mpls_label_t *label, uint32_t num_labels, int addpath_encode, uint32_t addpath_tx_id, struct attr *); extern size_t bgp_packet_mpattr_prefix_size(afi_t afi, safi_t safi, - struct prefix *p); + const struct prefix *p); extern void bgp_packet_mpattr_end(struct stream *s, size_t sizep); extern size_t bgp_packet_mpunreach_start(struct stream *s, afi_t afi, safi_t safi); -extern void bgp_packet_mpunreach_prefix(struct stream *s, struct prefix *p, - afi_t afi, safi_t safi, - struct prefix_rd *prd, mpls_label_t *, - uint32_t, int, uint32_t, struct attr *); +extern void bgp_packet_mpunreach_prefix( + struct stream *s, const struct prefix *p, afi_t afi, safi_t safi, + const struct prefix_rd *prd, mpls_label_t *label, uint32_t num_labels, + int addpath_encode, uint32_t addpath_tx_id, struct attr *attr); extern void bgp_packet_mpunreach_end(struct stream *s, size_t attrlen_pnt); extern bgp_attr_parse_ret_t bgp_attr_nexthop_valid(struct peer *peer, |