summaryrefslogtreecommitdiff
path: root/pimd/pim_msdp_packet.h
diff options
context:
space:
mode:
authoranuradhak <anuradhak@cumulusnetworks.com>2016-10-25 10:59:48 -0700
committerDonald Sharp <sharpd@cumulusnetworks.com>2016-12-21 20:26:12 -0500
commit2a333e0f220fb727406459d60815a1cc9000183a (patch)
treec82e9f2fb5be1253e62215703b5ea02ca92b6b9d /pimd/pim_msdp_packet.h
parent06afa136e98ce4de5bd1161914a7418f5e19098d (diff)
pim-msdp: part-1 - initial protocol infra.
This commit includes the following changes - 1. Support for MSDP peer DB (hash and sorted list). 2. Support for the following timers - keepalive, connect-retry, hold. 3. TCP session management (lower-ip is active, higher-ip is passive). 4. MSDP KA packet rx/tx. 5. Limited temporary config (will be replaced with the more automation friendly RP-set). Testing done - Peer bringup/deletion (including interop with another vendor) Sample out - root@dell-s6000-04:~# sudo vtysh -c "show ip msdp peer" Peer Local Mesh-group State Uptime 100.1.1.1 100.1.2.1 default established 00:07:27 100.1.3.1 100.1.2.1 default established 00:31:50 root@dell-s6000-04:~# Coming soon - 1. part-2: SA cache management. 2. part-3: SPT setup using source in SA cache. 3. part-4: CLI cleanup. Ticket: CM-13306 Signed-off-by: Anuradha Karuppiah <anuradhak@cumulusnetworks.com> Acked-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'pimd/pim_msdp_packet.h')
-rw-r--r--pimd/pim_msdp_packet.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/pimd/pim_msdp_packet.h b/pimd/pim_msdp_packet.h
new file mode 100644
index 0000000000..7f9ed9f68f
--- /dev/null
+++ b/pimd/pim_msdp_packet.h
@@ -0,0 +1,34 @@
+/*
+ * IP MSDP packet helpers
+ * Copyright (C) 2016 Cumulus Networks, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; see the file COPYING; if not, write to the
+ * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
+ * MA 02110-1301 USA
+ */
+#ifndef PIM_MSDP_PACKET_H
+#define PIM_MSDP_PACKET_H
+
+/* type and length of a single tlv can be consider packet header */
+#define PIM_MSDP_HEADER_SIZE 3
+#define PIM_MSDP_SA_TLV_MAX_SIZE 9192
+#define PIM_MSDP_KA_TLV_MAX_SIZE PIM_MSDP_HEADER_SIZE
+/* XXX: this is just a guesstimate - need to revist */
+#define PIM_MSDP_MAX_PACKET_SIZE (PIM_MSDP_SA_TLV_MAX_SIZE + PIM_MSDP_KA_TLV_MAX_SIZE)
+
+#define PIM_MSDP_PKT_TYPE_STRLEN 16
+
+void pim_msdp_pkt_ka_tx(struct pim_msdp_peer *mp);
+int pim_msdp_read(struct thread *thread);
+#endif