summaryrefslogtreecommitdiff
path: root/zebra/zebra_fpm_protobuf.c
AgeCommit message (Collapse)Author
2023-02-09*: auto-convert to SPDX License IDsDavid Lamparter
Done with a combination of regex'ing and banging my head against a wall. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2023-01-31zebra: Add missing enums to switch statementsDonald Sharp
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2020-04-08*: Do not cast to the same typeDonatas Abraitis
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-02-28zebra: fix nexthop_group conversion in fpm codeMark Stapp
Recent commit that embedded the nhg_hash_entry's group missed a couple of fpm modules. Signed-off-by: Mark Stapp <mjs@voltanet.io>
2020-02-06*: Replace s_addr 0 => INADDR_ANYDonatas Abraitis
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-12-04lib,zebra: use nhg_hash_entry pointer in route_entryMark Stapp
Replace the existing list of nexthops (via a nexthop_group struct) in the route_entry with a direct pointer to zebra's new shared group (from zebra_nhg.h). This allows more direct access to that shared group and the info it carries. Signed-off-by: Mark Stapp <mjs@voltanet.io>
2019-10-25zebra: Replace nexthop_group with pointer in route entryDonald Sharp
In the route_entry we are keeping a non pointer based nexthop group, switch the code to use a pointer for all operations here and ensure we create and delete the memory. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-05-16zebra: fix missed multipath_num changeDonald Sharp
The multipath_num global variable was moved into zrouter.multipath_num but this particular usage of it was not updated. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-04-18lib: ZEBRA_NUM_OF -> array_sizeDavid Lamparter
The latter is widely used, e.g. in the Linux kernel. Signed-off-by: David Lamparter <equinox@diac24.net>
2018-09-08*: fix clang-6 SA warningsDavid Lamparter
I don't see these in CI, but my local clang-6 does emit warnings for these. Signed-off-by: David Lamparter <equinox@diac24.net>
2018-03-29zebra: Set "has" flags on optional scalar fields of FPM protobuf messagesSergey Fionov
Otherwise, these fields are not serialized. Signed-off-by: Sergey Fionov <fionov@gmail.com>
2018-03-09lib: Isolate nexthop_group functions to nexthop_group.cDonald Sharp
Also modify `struct route_entry` to use nexthop_groups. Move ALL_NEXTHOPS loop to nexthop_group.h Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-08-28zebra: cleanup blackhole supportDavid Lamparter
blackhole support was horribly broken. cleanup by removing blackhole stuff from ZEBRA_FLAG_* introduces support for "prohibit" routes (Linux/netlink only) also clean up blackhole options on "ip route" vty commands. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-17*: reindentreindent-master-afterwhitespace / reindent
indent.py `git ls-files | pcregrep '\.[ch]$' | pcregrep -v '^(ldpd|babeld|nhrpd)/'` Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-07-10Rename ALL_NEXTHOPS_RO to ALL_NEXTHOPSßingen
2017-07-10Fix bug with NH macro in zebra_fpm_protobufßingen
One occurrence was missing to be adpated the new macro definition for multiple NH recursion levels.
2017-06-01zebra: Refactor 'struct rib' to be 'struct route_entry'Donald Sharp
The 'struct rib' data structure is missnamed. It really is a 'struct route_entry' as part of the 'struct route_node'. We have 1 'struct route_entry' per route src. As such 1 route node can have multiple route entries if multiple protocols attempt to install the same route. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2017-05-15*: make consistent & update GPLv2 file headersDavid Lamparter
The FSF's address changed, and we had a mixture of comment styles for the GPL file header. (The style with * at the beginning won out with 580 to 141 in existing files.) Note: I've intentionally left intact other "variations" of the copyright header, e.g. whether it says "Zebra", "Quagga", "FRR", or nothing. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-03-24zebra: fpm: fix protobuf compileDavid Lamparter
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2017-03-01bgpd, zebra: Allow setting ecmp from daemon cliDonald Sharp
When starting up bgp and zebra now, you can specify -e <number> or --ecmp <number> and that number will be used as the maximum ecmp that can be used. The <number specified must be >= 1 and <= MULTIPATH_NUM that Quagga is compiled with. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2016-09-23fpm/protobuf: fix compile errors & warningsDavid Lamparter
BABEL was removed, ifname nexthops were removed, additional includes were needed, and lastly the protobuf enum-handling triggers a warning. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2016-09-23zebra: optionally use protobuf with FPMAvneesh Sachdev
Change zebra so that it can optionally use protobuf serialization when communicating with a Forwarding Plane Manager component. * zebra/main.c Add the --fpm-format/-F command line option. This allows the user to control the format (protbuf|netlink) that is used to communicate with the FPM. * zebra/zebra_fpm.c - zebra_init_msg_format(), This new function is invoked on process startup to determine the FPM format that should be used. - zfpm_init() Change to accept any 'FPM message format' specified by the user (via the new command line flag). - zebra_encode_route() Tweak to use the selected FPM format. * zebra_fpm_protobuf.c New code to build protobuf messages to be sent to the FPM. * zebra/Makefile.am - Include common.am - Build new file zebra_fpm_protobuf.c when protobuf is available. - Link with the fpm_pb library. Signed-off-by: Avneesh Sachdev <avneesh@sproute.com>