From ce17d4c165cadb09d391e34cda1b796a125ef012 Mon Sep 17 00:00:00 2001 From: Ondrej Filip Date: Thu, 9 Mar 2000 22:38:05 +0000 Subject: LSA DB is completely redesigned. Now it should be faster and it needs less memory. --- proto/ospf/topology.h | 36 ++---------------------------------- 1 file changed, 2 insertions(+), 34 deletions(-) (limited to 'proto/ospf/topology.h') diff --git a/proto/ospf/topology.h b/proto/ospf/topology.h index 6a1aad5..9ebd0ed 100644 --- a/proto/ospf/topology.h +++ b/proto/ospf/topology.h @@ -12,23 +12,8 @@ struct top_hash_entry { /* Index for fast mapping (type,rtrid,LSid)->vertex */ snode n; struct top_hash_entry *next; /* Next in hash chain */ - struct top_vertex *vertex; - u32 lsa_id, rtr_id; - u8 lsa_type; -#define LSA_T_RT 1 -#define LSA_T_NET 2 -#define LSA_T_SUM_NET 3 -#define LSA_T_SUM_RT 4 -#define LSA_T_EXT 5 - u8 options; - u16 lsage; -#define LSA_MAXAGE 3600 /* 1 hour */ -#define LSA_CHECKAGE 300 /* 5 minutes */ -#define LSA_MAXAGEDIFF 900 /* 15 minutes */ - u32 lsseqno; - u16 length, checksum; -#define LSA_INITSEQNO 0x80000001 -#define LSA_MAXSEQNO 0x7fffffff + struct ospf_lsa_header lsa; + void *lsa_body; }; struct top_graph { @@ -50,21 +35,4 @@ struct top_hash_entry *ospf_hash_get(struct top_graph *, u32 lsa, u32 rtr, u32 t void ospf_hash_delete(struct top_graph *, struct top_hash_entry *); void addifa_rtlsa(struct ospf_iface *ifa); -struct top_graph_rtlsa { - u8 Vbit; - u8 Ebit; - u8 Bbit; - int links; /* Number of links */ - struct top_graph_rtlsa_link *flink; -}; - -struct top_graph_rtlsa_link { /* FIXME Completely ignoring TOS */ - u32 id; - u32 data; - u8 type; - u16 metric; - struct top_graph_rtlsa_link *next; -}; - - #endif /* _BIRD_OSPF_TOPOLOGY_H_ */ -- cgit v1.2.3