mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-10 20:18:03 +00:00
Merge pull request #4013 from manuhalo/zebra_c++_guards
zebra: add extern C guards to headers
This commit is contained in:
commit
aa69ac38f4
@ -28,6 +28,10 @@
|
||||
#include "lib/if.h"
|
||||
#include "lib/prefix.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern struct connected *connected_check(struct interface *ifp,
|
||||
union prefixconstptr p);
|
||||
extern struct connected *connected_check_ptp(struct interface *ifp,
|
||||
@ -58,4 +62,7 @@ extern void connected_delete_ipv6(struct interface *ifp,
|
||||
|
||||
extern int connected_is_unnumbered(struct interface *);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif /*_ZEBRA_CONNECTED_H */
|
||||
|
@ -24,6 +24,10 @@
|
||||
|
||||
#include "lib/vty.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Debug flags. */
|
||||
#define ZEBRA_DEBUG_EVENT 0x01
|
||||
|
||||
@ -99,4 +103,8 @@ extern void zebra_debug_init(void);
|
||||
|
||||
DECLARE_HOOK(zebra_debug_show_debugging, (struct vty *vty), (vty));
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_DEBUG_H */
|
||||
|
@ -23,11 +23,19 @@
|
||||
|
||||
#ifdef HAVE_NETLINK
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern int netlink_interface_addr(struct nlmsghdr *h, ns_id_t ns_id,
|
||||
int startup);
|
||||
extern int netlink_link_change(struct nlmsghdr *h, ns_id_t ns_id, int startup);
|
||||
extern int interface_lookup_netlink(struct zebra_ns *zns);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* HAVE_NETLINK */
|
||||
|
||||
#endif /* _ZEBRA_IF_NETLINK_H */
|
||||
|
@ -28,6 +28,10 @@
|
||||
|
||||
#include "zebra/zebra_l2.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* For interface multicast configuration. */
|
||||
#define IF_ZEBRA_MULTICAST_UNSPEC 0
|
||||
#define IF_ZEBRA_MULTICAST_ON 1
|
||||
@ -432,4 +436,8 @@ extern int interface_list_proc(void);
|
||||
extern int ifaddr_proc_ipv6(void);
|
||||
#endif /* HAVE_PROC_NET_IF_INET6 */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_INTERFACE_H */
|
||||
|
@ -22,6 +22,10 @@
|
||||
#ifndef _ZEBRA_IOCTL_H
|
||||
#define _ZEBRA_IOCTL_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Prototypes. */
|
||||
extern void ifreq_set_name(struct ifreq *, struct interface *);
|
||||
extern int if_ioctl(unsigned long, caddr_t);
|
||||
@ -53,4 +57,8 @@ extern struct connected *if_lookup_linklocal(struct interface *);
|
||||
|
||||
#endif /* SOLARIS_IPV6 */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_IOCTL_H */
|
||||
|
@ -22,7 +22,15 @@
|
||||
#ifndef _ZEBRA_IF_IOCTL_SOLARIS_H
|
||||
#define _ZEBRA_IF_IOCTL_SOLARIS_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void lifreq_set_name(struct lifreq *, const char *);
|
||||
int if_get_flags_direct(const char *, uint64_t *, unsigned int af);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_IF_IOCTL_SOLARIS_H */
|
||||
|
@ -21,6 +21,10 @@
|
||||
#ifndef _ZEBRA_IPFORWARD_H
|
||||
#define _ZEBRA_IPFORWARD_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern int ipforward(void);
|
||||
extern int ipforward_on(void);
|
||||
extern int ipforward_off(void);
|
||||
@ -29,4 +33,8 @@ extern int ipforward_ipv6(void);
|
||||
extern int ipforward_ipv6_on(void);
|
||||
extern int ipforward_ipv6_off(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_IPFORWARD_H */
|
||||
|
@ -28,6 +28,10 @@
|
||||
|
||||
#include "lib/vty.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define TRUE 1
|
||||
#define FALSE 0
|
||||
|
||||
@ -150,5 +154,8 @@ extern int irdp_read_raw(struct thread *r);
|
||||
extern void send_packet(struct interface *ifp, struct stream *s, uint32_t dst,
|
||||
struct prefix *p, uint32_t ttl);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _IRDP_H */
|
||||
|
@ -21,6 +21,10 @@
|
||||
#ifndef _ZEBRA_KERNEL_NETLINK_H
|
||||
#define _ZEBRA_KERNEL_NETLINK_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NETLINK
|
||||
|
||||
#define NL_RCV_PKT_BUF_SIZE 32768
|
||||
@ -68,4 +72,8 @@ extern int netlink_request(struct nlsock *nl, struct nlmsghdr *n);
|
||||
|
||||
#endif /* HAVE_NETLINK */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_KERNEL_NETLINK_H */
|
||||
|
@ -22,6 +22,10 @@
|
||||
#ifndef __ZEBRA_KERNEL_SOCKET_H
|
||||
#define __ZEBRA_KERNEL_SOCKET_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Error codes of zebra. */
|
||||
#define ZEBRA_ERR_NOERROR 0
|
||||
#define ZEBRA_ERR_RTEXIST -1
|
||||
@ -38,4 +42,8 @@ extern int rtm_write(int, union sockunion *, union sockunion *,
|
||||
enum blackhole_type, int);
|
||||
extern const struct message rtm_type_str[];
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __ZEBRA_KERNEL_SOCKET_H */
|
||||
|
@ -31,6 +31,10 @@
|
||||
|
||||
#include "zebra/zserv.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define NO_PROTO 0
|
||||
|
||||
/*
|
||||
@ -74,4 +78,8 @@ int release_label_chunk(uint8_t proto, unsigned short instance, uint32_t start,
|
||||
int release_daemon_label_chunks(struct zserv *client);
|
||||
void label_manager_close(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _LABEL_MANAGER_H */
|
||||
|
@ -29,6 +29,10 @@
|
||||
#include "zebra/zserv.h"
|
||||
#include "zebra/rib.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* ZAPI command handlers */
|
||||
extern void zebra_redistribute_add(ZAPI_HANDLER_ARGS);
|
||||
extern void zebra_redistribute_delete(ZAPI_HANDLER_ARGS);
|
||||
@ -73,4 +77,9 @@ extern int is_zebra_import_table_enabled(afi_t, uint32_t table_id);
|
||||
extern int zebra_import_table_config(struct vty *);
|
||||
|
||||
extern void zebra_import_table_rm_update(const char *rmap);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_REDISTRIBUTE_H */
|
||||
|
@ -35,6 +35,10 @@
|
||||
#include "mpls.h"
|
||||
#include "srcdest_table.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define DISTANCE_INFINITY 255
|
||||
#define ZEBRA_KERNEL_TABLE_MAX 252 /* support for no more than this rt tables */
|
||||
|
||||
@ -464,4 +468,9 @@ extern void zebra_vty_init(void);
|
||||
extern pid_t pid;
|
||||
|
||||
extern bool v6_rr_semantics;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /*_ZEBRA_RIB_H */
|
||||
|
@ -30,6 +30,10 @@
|
||||
#include "zclient.h"
|
||||
#include "if.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void router_id_add_address(struct connected *);
|
||||
extern void router_id_del_address(struct connected *);
|
||||
extern void router_id_init(struct zebra_vrf *);
|
||||
@ -37,4 +41,8 @@ extern void router_id_cmd_init(void);
|
||||
extern void router_id_write(struct vty *);
|
||||
extern void router_id_get(struct prefix *, vrf_id_t);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -31,6 +31,10 @@
|
||||
#include "zebra/zebra_mpls.h"
|
||||
#include "zebra/zebra_dplane.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Update or delete a route, LSP, or pseudowire from the kernel,
|
||||
* using info from a dataplane context.
|
||||
@ -91,4 +95,8 @@ extern void neigh_read_specific_ip(struct ipaddr *ip,
|
||||
struct interface *vlan_if);
|
||||
extern void route_read(struct zebra_ns *zns);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_RT_H */
|
||||
|
@ -26,6 +26,10 @@
|
||||
#include "zebra/zebra_mpls.h"
|
||||
#include "zebra/zebra_dplane.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define NL_DEFAULT_ROUTE_METRIC 20
|
||||
|
||||
/*
|
||||
@ -79,6 +83,10 @@ extern int netlink_macfdb_read_specific_mac(struct zebra_ns *zns,
|
||||
extern int netlink_neigh_read_specific_ip(struct ipaddr *ip,
|
||||
struct interface *vlan_if);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* HAVE_NETLINK */
|
||||
|
||||
#endif /* _ZEBRA_RT_NETLINK_H */
|
||||
|
@ -25,6 +25,10 @@
|
||||
#include "vty.h"
|
||||
#include "zebra/interface.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* NB: RTADV is defined in zebra/interface.h above */
|
||||
#if defined(HAVE_RTADV)
|
||||
|
||||
@ -137,5 +141,8 @@ extern void rtadv_cmd_init(void);
|
||||
extern void zebra_interface_radv_disable(ZAPI_HANDLER_ARGS);
|
||||
extern void zebra_interface_radv_enable(ZAPI_HANDLER_ARGS);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_RTADV_H */
|
||||
|
@ -26,6 +26,10 @@
|
||||
|
||||
#ifdef HAVE_NETLINK
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Handle netlink notification informing a rule add or delete.
|
||||
*/
|
||||
@ -36,6 +40,10 @@ extern int netlink_rule_change(struct nlmsghdr *h, ns_id_t ns_id, int startup);
|
||||
*/
|
||||
extern int netlink_rules_read(struct zebra_ns *zns);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* HAVE_NETLINK */
|
||||
|
||||
#endif /* _ZEBRA_RULE_NETLINK_H */
|
||||
|
@ -27,6 +27,10 @@
|
||||
|
||||
#include "zebra/zserv.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Table chunk struct
|
||||
* Client daemon which the chunk belongs to can be identified by either
|
||||
@ -63,4 +67,8 @@ int release_table_chunk(uint8_t proto, uint16_t instance, uint32_t start,
|
||||
int release_daemon_table_chunks(struct zserv *client);
|
||||
void table_manager_disable(ns_id_t ns_id);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _TABLE_MANAGER_H */
|
||||
|
@ -30,6 +30,10 @@
|
||||
#include "zebra/zebra_pbr.h"
|
||||
#include "zebra/zebra_errors.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* This is called to process inbound ZAPI messages.
|
||||
*
|
||||
@ -86,3 +90,7 @@ extern void zserv_nexthop_num_warn(const char *caller, const struct prefix *p,
|
||||
const unsigned int nexthop_num);
|
||||
|
||||
extern void zsend_capabilities_all_clients(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -30,6 +30,10 @@
|
||||
#include "zebra/zserv.h"
|
||||
#include "zebra/zebra_mpls.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Key netlink info from zebra ns */
|
||||
struct zebra_dplane_info {
|
||||
ns_id_t ns_id;
|
||||
@ -394,4 +398,8 @@ void zebra_dplane_pre_finish(void);
|
||||
void zebra_dplane_finish(void);
|
||||
void zebra_dplane_shutdown(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_DPLANE_H */
|
||||
|
@ -23,6 +23,10 @@
|
||||
|
||||
#include "lib/ferr.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
enum zebra_log_refs {
|
||||
EC_ZEBRA_LM_RESPONSE = ZEBRA_FERR_START,
|
||||
EC_ZEBRA_LM_NO_SUCH_CLIENT,
|
||||
@ -126,4 +130,8 @@ enum zebra_log_refs {
|
||||
|
||||
void zebra_error_init(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __EC_ZEBRAORS_H__ */
|
||||
|
@ -26,6 +26,10 @@
|
||||
|
||||
#include "zebra/debug.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L
|
||||
|
||||
#define zfpm_debug(...) \
|
||||
@ -61,4 +65,9 @@ extern int zfpm_protobuf_encode_route(rib_dest_t *dest, struct route_entry *re,
|
||||
uint8_t *in_buf, size_t in_buf_len);
|
||||
|
||||
extern struct route_entry *zfpm_route_for_update(rib_dest_t *dest);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_FPM_PRIVATE_H */
|
||||
|
@ -29,6 +29,10 @@
|
||||
#include "vlan.h"
|
||||
#include "vxlan.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* zebra L2 interface information - bridge slave (linkage to bridge) */
|
||||
struct zebra_l2info_brslave {
|
||||
ifindex_t bridge_ifindex; /* Bridge Master */
|
||||
@ -96,4 +100,9 @@ extern void zebra_l2if_update_bridge_slave(struct interface *ifp,
|
||||
|
||||
extern void zebra_l2if_update_bond_slave(struct interface *ifp,
|
||||
ifindex_t bond_ifindex);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_L2_H */
|
||||
|
@ -24,6 +24,10 @@
|
||||
|
||||
#include "memory.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
DECLARE_MGROUP(ZEBRA)
|
||||
DECLARE_MTYPE(RTADV_PREFIX)
|
||||
DECLARE_MTYPE(ZEBRA_NS)
|
||||
@ -37,4 +41,8 @@ DECLARE_MTYPE(RNH)
|
||||
DECLARE_MTYPE(DP_CTX)
|
||||
DECLARE_MTYPE(DP_PROV)
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _QUAGGA_ZEBRA_MEMORY_H */
|
||||
|
@ -24,8 +24,17 @@
|
||||
|
||||
#include "mlag.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void zebra_mlag_init(void);
|
||||
void zebra_mlag_terminate(void);
|
||||
|
||||
enum mlag_role zebra_mlag_get_role(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -34,6 +34,9 @@
|
||||
#include "zebra/zserv.h"
|
||||
#include "zebra/zebra_vrf.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Definitions and macros. */
|
||||
|
||||
@ -534,4 +537,8 @@ static inline int mpls_should_lsps_be_processed(struct zebra_vrf *zvrf)
|
||||
/* Global variables. */
|
||||
extern int mpls_enabled;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /*_ZEBRA_MPLS_H */
|
||||
|
@ -24,6 +24,10 @@
|
||||
|
||||
#include "zebra/zserv.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
struct mcast_route_data {
|
||||
struct prefix_sg sg;
|
||||
unsigned int ifindex;
|
||||
@ -32,4 +36,8 @@ struct mcast_route_data {
|
||||
|
||||
void zebra_ipmr_route_stats(ZAPI_HANDLER_ARGS);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -20,7 +20,15 @@
|
||||
#include "zebra.h"
|
||||
#include "ns.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern ns_id_t zebra_ns_id_get(const char *netnspath);
|
||||
extern ns_id_t zebra_ns_id_get_default(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __ZEBRA_NS_ID_H__ */
|
||||
|
@ -20,10 +20,18 @@
|
||||
#ifndef _NETNS_NOTIFY_H
|
||||
#define _NETNS_NOTIFY_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void zebra_ns_notify_init(void);
|
||||
extern void zebra_ns_notify_parse(void);
|
||||
extern void zebra_ns_notify_close(void);
|
||||
|
||||
extern struct zebra_privs_t zserv_privs;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* NETNS_NOTIFY_H */
|
||||
|
@ -28,6 +28,10 @@
|
||||
#include "zebra/rib.h"
|
||||
#include "zebra/zebra_vrf.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NETLINK
|
||||
/* Socket interface to kernel */
|
||||
struct nlsock {
|
||||
@ -68,4 +72,8 @@ int zebra_ns_final_shutdown(struct ns *ns);
|
||||
|
||||
int zebra_ns_config_write(struct vty *vty, struct ns *ns);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -32,6 +32,10 @@
|
||||
#include "rt.h"
|
||||
#include "pbr.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
struct zebra_pbr_rule {
|
||||
int sock;
|
||||
|
||||
@ -252,4 +256,8 @@ DECLARE_HOOK(zebra_pbr_ipset_entry_update,
|
||||
DECLARE_HOOK(zebra_pbr_ipset_update,
|
||||
(int cmd, struct zebra_pbr_ipset *ipset), (cmd, ipset));
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_PBR_H */
|
||||
|
@ -31,6 +31,10 @@ extern const char ZEBRA_PTM_SOCK_NAME[];
|
||||
#include "zebra/zserv.h"
|
||||
#include "zebra/interface.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Zebra ptm context block */
|
||||
struct zebra_ptm_cb {
|
||||
int ptm_sock; /* ptm file descriptor. */
|
||||
@ -87,4 +91,9 @@ void zebra_ptm_if_init(struct zebra_if *zebra_ifp);
|
||||
void zebra_ptm_if_set_ptm_state(struct interface *ifp,
|
||||
struct zebra_if *zebra_ifp);
|
||||
void zebra_ptm_if_write(struct vty *vty, struct zebra_if *zebra_ifp);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -21,7 +21,17 @@
|
||||
|
||||
#ifndef _ZEBRA_PTM_REDISTRIBUTE_H
|
||||
#define _ZEBRA_PTM_REDISTRIBUTE_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void zebra_interface_bfd_update(struct interface *, struct prefix *,
|
||||
struct prefix *, int, vrf_id_t);
|
||||
extern void zebra_bfd_peer_replay_req(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_PTM_REDISTRIBUTE_H */
|
||||
|
@ -29,6 +29,10 @@
|
||||
|
||||
#include "zebra/zebra_vrf.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define PW_INSTALL_RETRY_INTERVAL 30
|
||||
|
||||
struct zebra_pw {
|
||||
@ -74,4 +78,8 @@ void zebra_pw_init(struct zebra_vrf *);
|
||||
void zebra_pw_exit(struct zebra_vrf *);
|
||||
void zebra_pw_vty_init(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* ZEBRA_PW_H_ */
|
||||
|
@ -25,6 +25,10 @@
|
||||
#include "prefix.h"
|
||||
#include "vty.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Nexthop structure. */
|
||||
struct rnh {
|
||||
uint8_t flags;
|
||||
@ -83,4 +87,9 @@ extern void zebra_evaluate_rnh(struct zebra_vrf *zvrf, afi_t afi, int force,
|
||||
extern void zebra_print_rnh_table(vrf_id_t vrfid, afi_t afi, struct vty *vty,
|
||||
rnh_type_t);
|
||||
extern char *rnh_str(struct rnh *rnh, char *buf, int size);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /*_ZEBRA_RNH_H */
|
||||
|
@ -24,6 +24,10 @@
|
||||
|
||||
#include "lib/routemap.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void zebra_route_map_init(void);
|
||||
extern void zebra_routemap_config_write_protocol(struct vty *vty,
|
||||
struct zebra_vrf *vrf);
|
||||
@ -48,4 +52,8 @@ zebra_nht_route_map_check(afi_t afi, int client_proto, const struct prefix *p,
|
||||
struct zebra_vrf *zvrf, struct route_entry *,
|
||||
struct nexthop *nexthop);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -26,6 +26,10 @@
|
||||
|
||||
#include "zebra/zebra_ns.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
* This header file contains the idea of a router and as such
|
||||
* owns data that is associated with a router from zebra's
|
||||
@ -129,4 +133,9 @@ extern void zebra_router_sweep_route(void);
|
||||
extern void zebra_router_show_table_summary(struct vty *vty);
|
||||
|
||||
extern uint32_t zebra_router_get_next_sequence(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -28,6 +28,10 @@
|
||||
#include <zebra/zebra_pw.h>
|
||||
#include <lib/vxlan.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* MPLS (Segment Routing) global block */
|
||||
typedef struct mpls_srgb_t_ {
|
||||
uint32_t start_label;
|
||||
@ -203,4 +207,9 @@ extern void zebra_vrf_init(void);
|
||||
|
||||
extern void zebra_rtable_node_cleanup(struct route_table *table,
|
||||
struct route_node *node);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* ZEBRA_VRF_H */
|
||||
|
@ -35,6 +35,10 @@
|
||||
#include "zebra/zebra_vrf.h"
|
||||
#include "zebra/zserv.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Is EVPN enabled? */
|
||||
#define EVPN_ENABLED(zvrf) (zvrf)->advertise_all_vni
|
||||
static inline int is_evpn_enabled(void)
|
||||
@ -206,4 +210,8 @@ extern int zebra_vxlan_clear_dup_detect_vni(struct vty *vty,
|
||||
struct zebra_vrf *zvrf,
|
||||
vni_t vni);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_VXLAN_H */
|
||||
|
@ -26,12 +26,14 @@
|
||||
|
||||
#include <zebra.h>
|
||||
|
||||
#include <zebra.h>
|
||||
|
||||
#include "if.h"
|
||||
#include "linklist.h"
|
||||
#include "zebra_vxlan.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define ERR_STR_SZ 256
|
||||
|
||||
/* definitions */
|
||||
@ -421,4 +423,8 @@ struct nh_walk_ctx {
|
||||
struct json_object *json;
|
||||
};
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_VXLAN_PRIVATE_H */
|
||||
|
@ -40,6 +40,10 @@
|
||||
#include "zebra/zebra_vrf.h" /* for zebra_vrf */
|
||||
/* clang-format on */
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/* Default port information. */
|
||||
#define ZEBRA_VTY_PORT 2601
|
||||
|
||||
@ -234,4 +238,8 @@ extern void zserv_read_file(char *input);
|
||||
/* TODO */
|
||||
int zebra_finalize(struct thread *event);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ZEBRA_ZEBRA_H */
|
||||
|
Loading…
Reference in New Issue
Block a user