Statistics
| Branch: | Revision:

iof-bird-daemon / sysdep / unix / krt.h @ 10d807d0

History | View | Annotate | Download (1.39 KB)

1
/*
2
 *        BIRD -- Unix Kernel Route Syncer
3
 *
4
 *        (c) 1998 Martin Mares <mj@ucw.cz>
5
 *
6
 *        Can be freely distributed and used under the terms of the GNU GPL.
7
 */
8

    
9
#ifndef _BIRD_KRT_H_
10
#define _BIRD_KRT_H_
11

    
12
#include "lib/krt-scan.h"
13
#include "lib/krt-set.h"
14
#include "lib/krt-iface.h"
15

    
16
/* Flags stored in net->n.flags */
17

    
18
#define KRF_CREATE 0                        /* Not seen in kernel table */
19
#define KRF_SEEN 1                        /* Seen in kernel table during last scan */
20
#define KRF_UPDATE 2                        /* Need to update this entry */
21
#define KRF_DELETE 3                        /* Should be deleted */
22
#define KRF_LEARN 4                        /* We should learn this route */
23

    
24
/* sync-rt.c */
25

    
26
extern struct protocol proto_unix_kernel;
27

    
28
struct krt_config {
29
  struct proto_config c;
30
  struct krt_set_params setopt;
31
  struct krt_scan_params scanopt;
32
  struct krt_if_params ifopt;
33
};
34

    
35
struct krt_proto {
36
  struct proto p;
37
  struct krt_set_status setstat;
38
  struct krt_scan_status scanstat;
39
  struct krt_if_status ifstat;
40
};
41

    
42
extern struct proto_config *cf_krt;
43

    
44
/* krt-scan.c */
45

    
46
void krt_scan_preconfig(struct krt_config *);
47
void krt_scan_start(struct krt_proto *);
48
void krt_scan_shutdown(struct krt_proto *);
49
void krt_scan_ifaces_done(struct krt_proto *);
50

    
51
/* krt-set.c */
52

    
53
void krt_set_preconfig(struct krt_config *);
54
void krt_set_start(struct krt_proto *);
55

    
56
/* sync-if.c */
57

    
58
void krt_if_preconfig(struct krt_config *);
59
void krt_if_start(struct krt_proto *);
60
void krt_if_shutdown(struct krt_proto *);
61

    
62
#endif