summaryrefslogtreecommitdiff
path: root/eigrpd/eigrp_interface.h
blob: 0c57f0cbd61020a7caa92286e0ef7e4818de9ed9 (plain)
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
/*
 * EIGRP Interface Functions.
 * Copyright (C) 2013-2016
 * Authors:
 *   Donnie Savage
 *   Jan Janovic
 *   Matej Perina
 *   Peter Orsag
 *   Peter Paluch
 *   Frantisek Gazo
 *   Tomas Hvorkovy
 *   Martin Kontsek
 *   Lukas Koribsky
 *
 * This file is part of GNU Zebra.
 *
 * GNU Zebra 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, or (at your option) any
 * later version.
 *
 * GNU Zebra 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 _ZEBRA_EIGRP_INTERFACE_H_
#define _ZEBRA_EIGRP_INTERFACE_H_

/*Prototypes*/
extern void eigrp_if_init (void);
extern int eigrp_if_new_hook (struct interface *);
extern int eigrp_if_delete_hook (struct interface *);

extern void eigrp_del_if_params (struct eigrp_if_params *);
extern struct eigrp_if_params *eigrp_new_if_params (void);
extern struct eigrp_interface * eigrp_if_new (struct eigrp *, struct interface *,
                                              struct prefix *);
extern struct eigrp_interface * eigrp_if_table_lookup (struct interface *,
                                                       struct prefix *);
extern struct eigrp_if_params *eigrp_lookup_if_params (struct interface *,
                                                struct in_addr);
extern int eigrp_if_up (struct eigrp_interface *);
extern void eigrp_if_stream_set (struct eigrp_interface *);
extern void eigrp_if_set_multicast (struct eigrp_interface *);
extern u_char eigrp_default_iftype (struct interface *);
extern void eigrp_if_free (struct eigrp_interface *, int);
extern int eigrp_if_down (struct eigrp_interface *);
extern void eigrp_if_stream_unset (struct eigrp_interface *);

extern struct eigrp_interface *eigrp_if_lookup_by_local_addr (struct eigrp *,
                                                              struct interface *,
                                                              struct in_addr);
extern struct eigrp_interface *eigrp_if_lookup_by_name (struct eigrp *, const char *);
struct eigrp_interface * eigrp_if_lookup_recv_if (struct eigrp *, struct in_addr,
                                                  struct interface *);

/* Simulate down/up on the interface. */
extern void eigrp_if_reset (struct interface *);

extern u_int32_t eigrp_bandwidth_to_scaled (u_int32_t);
extern u_int32_t eigrp_scaled_to_bandwidth (u_int32_t);
extern u_int32_t eigrp_delay_to_scaled (u_int32_t);
extern u_int32_t eigrp_scaled_to_delay (u_int32_t);


#endif /* ZEBRA_EIGRP_INTERFACE_H_ */