summaryrefslogtreecommitdiff
path: root/zebra/zebra_nb_state.c
AgeCommit message (Collapse)Author
2024-04-20yang: add missing `zif-gre` zebra interface typeChristian Hopps
This was caught by the grpc_basic test which was receiving an invalid error result, which was returned b/c inside zebra the libyang code was flagging the value as invalid for a derived zebra interface type. Signed-off-by: Christian Hopps <chopps@labn.net>
2024-03-08Merge pull request #15469 from LabNConsulting/chopps/keychain-yangDonald Sharp
add ietf-key-chain YANG module support
2024-03-04lib: add keychain northbound supportChristian Hopps
Signed-off-by: Christian Hopps <chopps@labn.net>
2024-02-20zebra: implement zif-type oper state leafIgor Ryzhov
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2024-02-20zebra: add interface's bond to oper stateIgor Ryzhov
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2023-12-28zebra: fix oper-state walk bugChristian Hopps
Signed-off-by: Christian Hopps <chopps@labn.net>
2023-12-28zebra: support yielding between oper state routes queryChristian Hopps
Signed-off-by: Christian Hopps <chopps@labn.net>
2023-12-28zebra: add zebra to mgmtd oper-stateChristian Hopps
Signed-off-by: Christian Hopps <chopps@labn.net>
2023-09-20zebra: add northbound api hooks for nexthop segmentsDmytro Shytyi
Provide skeleton hooks for nexthop segments Those hooks address seg6 segs stack entries defined in the YANG model Signed-off-by: Dmytro Shytyi <dmytro.shytyi@6wind.com>
2023-02-17Merge pull request #12780 from opensourcerouting/spdx-license-idDonald Sharp
*: convert to SPDX License identifiers
2023-02-13zebra: vxlan interface refactoring changesSharath Ramamurthy
This change refactors the zebra_vxlan_if related functionality to a new zebra_vxlan_if.c file. zebra_vxlan_if_up/down, zebra_vxlan_if_add/update/del is moved zebra_vxlan_if.c Signed-off-by: Sharath Ramamurthy <sramamurthy@nvidia.com>
2023-02-13zebra: data structure changes for single vxlan deviceSharath Ramamurthy
This changeset introduces the data structure changes needed for single vxlan device functionality. A new struct zebra_vxlan_vni_info encodes the iftype and vni information for vxlan device. The change addresses related access changes of the new data structure fields from different files zebra_vty is modified to take care of the vni dump information according to the new vni data structure for vxlan devices. Signed-off-by: Sharath Ramamurthy <sramamurthy@nvidia.com>
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>
2022-05-08*: Avoid casting to the same type as on the leftDonatas Abraitis
Just not necessary. Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2021-03-16zebra: make ribs config falseIgor Ryzhov
Zebra routing tables are not controlled by the user and can not be created/deleted manually. Current NB create/destroy callbacks are incorrectly implemented because instead of creating/deleting the RIB they are only checking for it's existence. YANG model should reflect the real situation. Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2020-08-12staticd: add support for SR PoliciesSebastien Merle
Configuration example: ip route 9.9.9.9/32 6.6.6.6 color 123 The SR Policy to be chosen is uniquely identified by the policy endpoint (6.6.6.6) and the SR-TE color (123). Traffic will be augmented with an MPLS label stack according to the active candidate path of that particular policy. Co-authored-by: GalaxyGorilla <sascha@netdef.org> Signed-off-by: Sebastien Merle <sebastien@netdef.org>
2020-07-17zebra: rib operational nb add vrf keyChirag Shah
Add vrf as key in Rib operational nexthop list PR 6296 has added vrf as key in nexthop list. Rib operational model uses nexthop list, adding vrf key into northbound callback. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-07-16zebra: Moving afi-safi identity to libvdhingra
afi-safi identity handling should be in the common place. Signed-off-by: VishalDhingra <vdhingra@vmware.com>
2020-07-14*: remove PRI[udx](8|16|32)David Lamparter
These are completely pointless and break coccinelle string replacements. Scripted commit, idempotent to running: ``` python3 tools/stringmangle.py --pri8-16-32 `git ls-files | egrep '\.[ch]$'` ``` Signed-off-by: David Lamparter <equinox@diac24.net>
2020-06-10zebra: rib nb changes with redefined nexthop modelChirag Shah
RIB operational northbound changes based on redfined nexthop model. Testing Done: { "afi-safi-name": "ipv4-unicast", "table-id": 254, "route": [ { "prefix": "0.0.0.0/0", "route-entry": [ { "protocol": "kernel", "distance": 0, "metric": 100, "selected": [null], "installed": [null], "internal-flags": 8, "internal-status": 16, "uptime": "2020-06-06T00:28:26.139797Z", "nexthop-group": { "id": 15, "nexthop": [ { "nh-type": "ip4-ifindex", "vrf": "0", "gateway": "10.0.2.2", "interface": "enp0s3", "active": [null], "fib": [null] } ] } } ] }, { "prefix": "1.1.1.4/32", "route-entry": [ { "protocol": "kernel", "distance": 0, "metric": 0, "selected": [null], "installed": [null], "internal-flags": 8, "internal-status": 16, "uptime": "2020-06-06T00:28:26.139790Z", "nexthop-group": { "id": 16, "nexthop": [ { "nh-type": "ifindex", "vrf": "0", "gateway": "", "interface": "dummy4", "active": [null], "fib": [null] } ] } } ] } ] } Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-05-15zebra: optimize the RIB get_next() callbackRenato Westphal
When fetching the next route node in the RIB, skip the empty ones to avoid calling other northbound callbacks later unnecessarily. Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2020-05-15zebra: skip link-local routes when iterating over the RIB using the NBRenato Westphal
The motivation for this change is that IPv6 link-local routes don't conform to the zebra YANG module since they all have the same prefix (fe80::/64), but zebra's YANG module require each route to have an unique prefix (the key of the "rib" list). This violation can cause problems when iterating over the RIB asynchronously, so skip those routes. At the end of the day nobody cares about link-local routes anyway :) Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2020-05-15zebra: implement two missing RIB lookup_entry() callbacksRenato Westphal
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2020-05-15zebra: add missing return in one get_elem() callbackRenato Westphal
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2020-05-14zebra: fix SA warning in zebra_nb_state.cMark Stapp
Fix an SA warning in zebra_nb_state.c. Signed-off-by: Mark Stapp <mjs@voltanet.io>
2020-05-12zebra: rib northbound callback implementationChirag Shah
- add RIB's northbound list create/destory callback changes. - add RIB's northbound callbacks implementation. - add RIB's nexthop callbacks implementation. - add RIB's nexthop weight field callback changes. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-05-12zebra: add zebra container to rib modelChirag Shah
Add zebra container in rib tree. When displaying RIB under vrf, it displays zebra module name. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-05-12zebra: northbound changes for the rib modelChirag Shah
This commit implements: RIB operational list create/destroy. Walk over RIB tables using keys. The first RIB table will be IPV4/unicast (table-id 254) will be fetched. Create a new api to fetch RIB table based on afi-safi and table id as the keys. remove mandatory true statement from the leaf which is part of the list key. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-04-23*: change the signature of the northbound callbacks to be more flexibleRenato Westphal
Having a fixed set of parameters for each northbound callback isn't a good idea since it makes it difficult to add new parameters whenever that becomes necessary, as several hundreds or thousands of existing callbacks need to be updated accordingly. To remediate this issue, this commit changes the signature of all northbound callbacks to have a single parameter: a pointer to a 'nb_cb_x_args' structure (where x is different for each type of callback). These structures encapsulate all real parameters (both input and output) the callbacks need to have access to. And adding a new parameter to a given callback is as simple as adding a new field to the corresponding 'nb_cb_x_args' structure, without needing to update any instance of that callback in any daemon. This commit includes a .cocci semantic patch that can be used to update old code to the new format automatically. Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2020-04-16zebra: add weight to nb conversionChirag Shah
Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-04-16zebra: add northbound support for zebra interfaceChirag Shah
Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-04-16zebra: add nb callbacks for zebra if stateChirag Shah
This is all stub callbacks autogenrated for zebra interface state data. Signed-off-by: chirag Shah <chirag@cumulusnetworks.com>
2020-04-16zebra: stub changes to assimilate re into rib nbChirag Shah
Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2020-04-16zebra: nb callbacks supportChirag Shah
Definition of the northbound callbacks and associated YANG data paths for zebra. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>