-
Notifications
You must be signed in to change notification settings - Fork 10
/
bisect_iv.h
85 lines (72 loc) · 1.62 KB
/
bisect_iv.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/* SPDX-License-Identifier: GPL-2.0 */
/* Copyright (C) B.A.T.M.A.N. contributors:
*
* Marek Lindner <mareklindner@neomailbox.ch>
*
* License-Filename: LICENSES/preferred/GPL-2.0
*/
#ifndef _BATCTL_BISECT_IV_H
#define _BATCTL_BISECT_IV_H
#include "list.h"
#define NAME_LEN 18
#define MAX_LINE 256
#define LOOP_MAGIC_LEN ((2 * NAME_LEN) + (2 * sizeof(int)) - 2)
#define RT_FLAG_ADD 1
#define RT_FLAG_UPDATE 2
#define RT_FLAG_DELETE 3
struct bat_node {
char name[NAME_LEN];
struct list_head orig_event_list;
struct list_head rt_table_list;
char loop_magic[LOOP_MAGIC_LEN];
char loop_magic2[LOOP_MAGIC_LEN];
};
struct orig_event {
struct list_head list;
struct bat_node *orig_node;
struct list_head event_list;
struct list_head rt_hist_list;
};
struct rt_table {
struct list_head list;
int num_entries;
struct rt_entry *entries;
struct rt_hist *rt_hist;
};
struct rt_hist {
struct list_head list;
struct rt_table *rt_table;
struct rt_hist *prev_rt_hist;
struct seqno_event *seqno_event;
struct bat_node *next_hop;
char flags;
char loop_magic[LOOP_MAGIC_LEN];
};
struct rt_entry {
char orig[NAME_LEN];
struct bat_node *next_hop;
char flags;
};
struct seqno_event {
struct list_head list;
struct bat_node *orig;
struct bat_node *neigh;
struct bat_node *prev_sender;
long long seqno;
int tq;
int ttl;
struct rt_hist *rt_hist;
};
struct seqno_trace_neigh {
struct bat_node *bat_node;
struct seqno_event *seqno_event;
int num_neighbors;
struct seqno_trace_neigh **seqno_trace_neigh;
};
struct seqno_trace {
struct list_head list;
long long seqno;
char print;
struct seqno_trace_neigh seqno_trace_neigh;
};
#endif