]> git.proxmox.com Git - mirror_frr.git/blobdiff - zebra/kernel_netlink.h
zebra: print unknown rule family as number
[mirror_frr.git] / zebra / kernel_netlink.h
index af0cc83f4ab99bc68dc34198bcbfd49c4c371a47..076ca5c5c7579253eb07859d42ee15046cc99568 100644 (file)
 #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
@@ -52,14 +56,24 @@ extern bool netlink_read;
 extern void netlink_read_init(const char *fname);
 #endif /* HANDLE_NETLINK_FUZZING */
 extern int netlink_parse_info(int (*filter)(struct nlmsghdr *, ns_id_t, int),
-                             struct nlsock *nl, struct zebra_ns *zns,
+                             const struct nlsock *nl,
+                             const struct zebra_dplane_info *dp_info,
                              int count, int startup);
 extern int netlink_talk_filter(struct nlmsghdr *h, ns_id_t ns, int startup);
 extern int netlink_talk(int (*filter)(struct nlmsghdr *, ns_id_t, int startup),
                        struct nlmsghdr *n, struct nlsock *nl,
                        struct zebra_ns *zns, int startup);
+/* Version with 'info' struct only */
+int netlink_talk_info(int (*filter)(struct nlmsghdr *, ns_id_t, int startup),
+                     struct nlmsghdr *n,
+                     const struct zebra_dplane_info *dp_info, int startup);
+
 extern int netlink_request(struct nlsock *nl, struct nlmsghdr *n);
 
 #endif /* HAVE_NETLINK */
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _ZEBRA_KERNEL_NETLINK_H */