ospf_db.h

来自「TCP-IP红宝书源代码」· C头文件 代码 · 共 20 行

H
20
字号
/* ospf_db.h */

#define	LSABUFS		100	/* Number of LSA Buffers for Top. DBs	*/
#define	DBHTMOD		63	/* Database Hash Table Modulus		*/

#define	DBHASH(lsid)	((lsid) % DBHTMOD)

/* An Entry in the Topological Database */

struct ospf_db {
	struct ospf_lsa	 db_lsa;
	struct ospf_db	*db_hnext;	/* Next Entry in Hash Table	*/
	struct ospf_db	*db_lnext;	/* Next Entry in a Full Scan	*/
};

struct ospf_db *db_lookup(struct ospf_ar *, u_long, u_long);
struct ospf_db *db_new(struct ospf_ar *, struct ospf_lsa *);
int db_update(struct ospf_ar *, struct ospf_lsa *);
void db_nlink(struct ospf_if *), db_rlink(struct ospf_if *);

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?