]> arthur.barton.de Git - netatalk.git/blob - etc/atalkd/interface.h
Initial revision
[netatalk.git] / etc / atalkd / interface.h
1 /*
2  * Copyright (c) 1990,1992 Regents of The University of Michigan.
3  * All Rights Reserved. See COPYRIGHT.
4  */
5
6 #ifndef ATALKD_INTERFACE_H
7 #define ATALKD_INTERFACE_H 1
8
9 #include <sys/cdefs.h>
10
11 struct interface {
12     struct interface    *i_next;
13     char                i_name[ IFNAMSIZ ];
14     int                 i_flags;
15     int                 i_time;
16     int                 i_group; /* for isolated appletalk domains */
17     struct sockaddr_at  i_addr;
18     struct sockaddr_at  i_caddr;
19     struct ziptab       *i_czt;
20     struct rtmptab      *i_rt;
21     struct gate         *i_gate;
22     struct atport       *i_ports;
23 };
24
25 #define IFACE_PHASE1    0x001
26 #define IFACE_PHASE2    0x002
27 #define IFACE_LOOPBACK  0x004           /* is the loopback interface */
28 #define IFACE_SEED      0x008           /* act as seed */
29 #define IFACE_ADDR      0x010           /* has an address set */
30 #define IFACE_CONFIG    0x020           /* has been configured */
31 #define IFACE_NOROUTER  0x040           /* no router on interface */
32 #define IFACE_LOOP      0x080           /* has a loopback route */
33 #define IFACE_RSEED     0x100           /* almost the same as seed. RSEED
34                                            says that we should try to 
35                                            do routing. */
36 #define IFACE_DONTROUTE 0x200           /* don't route this interface */
37 #define IFACE_ISROUTER  0x400           /* act as a router. */
38
39 #define UNSTABLE        2
40 #define STABLE          0
41 #define STABLEANYWAY    -2
42
43 #define IFBASE          2       /* base number of interfaces */
44
45 #ifdef linux
46 #define LOOPIFACE       "lo"
47 #else linux
48 #define LOOPIFACE       "lo0"
49 #endif linux
50
51 extern struct interface *interfaces;
52 extern struct interface *ciface;
53 struct interface        *newiface __P((const char *));
54
55 #endif