summaryrefslogtreecommitdiffstats
path: root/zebra/rtread_netlink.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* zebra: evpn remote delete fetch local entryChirag Shah2018-12-311-0/+11
| | | | | | | | | | | | | | | | | | | | | | An EVPN type-2 entry is in freeze state during remote update, remote VTEP can send typ-2 withdraw update, upon receiving an entry delete (withdraw), first check kernel has in local reachable state. Upon unfreeze use the local entry to advertise to peers. Fetch is for both MAC and IP, delete can come for only MAC or MAC-IP combined route. The specific entry fetch only required request flag to be set, dump flag is not required. Testing Done: Simulate two VTEPs to do M1, IP1 mobility sequence, freeze MAC during remote MAC update, subsequently send withdraw type-2 route from origintating VTEP. This results in read apis to invoke for local reachable entry. Zebra updates its cache and upon unfreeze originates type-2. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* *: PBR - netlink interaction and basic definitionsvivek2018-03-091-0/+7
| | | | | | | | | | Implement netlink interactions for Policy Based Routing. This includes APIs to install and uninstall rules and handle notifications from the kernel related to rule addition or deletion. Various definitions are added to facilitate this. Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com> Reviewed-by: Donald Sharp <sharpd@cumulusnetworks.com>
* zebra: Make zserv.h the true api for zapi northboundDonald Sharp2017-12-131-1/+1
| | | | | | | | zserv.c had a grab bag of function declarations that did not belong in it. Move those to where they better belong. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* build: zebra: remove *_method Makefile hacksDavid Lamparter2017-07-311-0/+4
| | | | | | replace with preprocessor checks in source files. Much simpler... Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* *: reindentreindent-master-afterwhitespace / reindent2017-07-171-11/+11
| | | | | | indent.py `git ls-files | pcregrep '\.[ch]$' | pcregrep -v '^(ldpd|babeld|nhrpd)/'` Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* zebra: MAC and Neighbor (ARP/ND) handlingvivek2017-07-121-0/+21
| | | | | | | | | | | | | | | | | | | Implement handling of MACs and Neighbors (ARP/ND entries) in zebra: - MAC and Neighbor database handlers - Read MACs and Neighbors from the kernel, when needed and create entries in zebra's MAC and Neighbor databases. - Handle add/update/delete notifications from the kernel for MACs and Neighbors and update zebra's database appropriately - Inform locally learnt MACs and Neighbors to client - Handle MACIP add/delete from client and install appriporiate entries into the kernel - Since Neighbor entries will be installed on an SVI, implement the needed mappings NOTE: kernel interface is only implemented for Linux/netlink Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com> Reviewed-by: Donald Sharp <sharpd@cumulusnetworks.com>
* *: make consistent & update GPLv2 file headersDavid Lamparter2017-05-151-4/+3
| | | | | | | | | | | 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>
* all: removed all DEFUN command stomps (fix build errors)Daniel Walton2016-10-061-0/+1
| | | | Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
* lib, zebra: The Bulk of the conversion over to NS and VRFDonald Sharp2016-02-011-2/+2
| | | | | | | Convert the rest of zebra over to use a Namespae and VRF. Signed-off-by: Vipin Kumar <vipin@cumulusnetworks.com> Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* zebra, lib/memtypes.c: the netlink sockets work per VRFFeng Lu2015-10-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch lets the netlink sockets work per VRF. * The definition of "struct nlsock" is moved into zebra/rib.h. * The previous global variables "netlink" and "netlink_cmd" now become the members of "struct zebra_vrf", and are initialized in zebra_vrf_alloc(). * All relative functions now work for a specific VRF, by adding a new parameter which specifies the working VRF, except those functions in which the VRF ID can be obtained from the interface. * kernel_init(), interface_list() and route_read() are now also working per VRF, and moved from main() to zebra_vrf_enable(). * A new function kernel_terminate() is added to release the netlink sockets. It is called from zebra_vrf_disable(). * Correct VRF ID, instead of the previous VRF_DEFAULT, are now passed to the functions of processing interfaces or route entries. Signed-off-by: Feng Lu <lu.feng@6wind.com> Reviewed-by: Alain Ritoux <alain.ritoux@6wind.com> Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com> Conflicts: lib/memtypes.c zebra/rib.h zebra/rt_netlink.c Conflicts: zebra/if_netlink.c zebra/if_sysctl.c zebra/kernel_null.c zebra/rib.h zebra/rt_netlink.c zebra/rt_netlink.h
* zebra: zebra-warnings.patchDonald Sharp2015-05-201-2/+1
| | | | | | Remove compiled warnings for the zebra directory Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com> Reviewed-by:
* zebra: add missing includesDenis Ovsienko2011-09-271-0/+3
|
* [zebra] netlink interface minor cleanupStephen Hemminger2009-06-181-4/+2
| | | | Add more prototypes and make some functions static
* Initial revisionpaul2002-12-131-0/+31