Linux 2.4.0-test10pre3
[davej-history.git] / net / protocols.c
blob2188df91210048c6331b5eb9d7ee2db16915c50d
1 /*
2 * Protocol initializer table. Here separately for convenience
4 */
7 #include <linux/config.h>
8 #include <linux/types.h>
9 #include <linux/kernel.h>
10 #include <linux/net.h>
11 #include <linux/fs.h>
13 #ifdef CONFIG_UNIX
14 #include <linux/un.h>
15 #include <net/af_unix.h>
16 #endif
18 #ifdef CONFIG_INET
19 #include <linux/inet.h>
20 #ifdef CONFIG_IPV6
21 extern void inet6_proto_init(struct net_proto *pro);
22 #endif
23 #endif /* INET */
25 #ifdef CONFIG_ECONET
26 extern void econet_proto_init(struct net_proto *pro);
27 #endif
29 #ifdef CONFIG_NETLINK
30 extern void netlink_proto_init(struct net_proto *pro);
31 #endif
33 #ifdef CONFIG_PACKET
34 extern void packet_proto_init(struct net_proto *pro);
35 #endif
37 #if defined(CONFIG_IPX) || defined(CONFIG_IPX_MODULE)
38 #define NEED_802
39 #include <net/ipxcall.h>
40 #endif
42 #ifdef CONFIG_X25
43 #include <net/x25call.h>
44 #endif
46 #ifdef CONFIG_LAPB
47 #include <net/lapbcall.h>
48 #endif
50 #ifdef CONFIG_AX25
51 #include <net/ax25call.h>
52 #ifdef CONFIG_NETROM
53 #include <net/nrcall.h>
54 #endif
55 #ifdef CONFIG_ROSE
56 #include <net/rosecall.h>
57 #endif
58 #endif
60 #ifdef CONFIG_IRDA
61 #include <net/irda/irdacall.h>
62 #endif
64 #if defined(CONFIG_DECNET)
65 #include <net/decnet_call.h>
66 #endif
68 #if defined(CONFIG_ATALK) || defined(CONFIG_ATALK_MODULE)
69 #define NEED_802
70 #include <net/atalkcall.h>
71 #endif
73 #if defined(CONFIG_NETBEUI)
74 #define NEED_LLC
75 #include <net/netbeuicall.h>
76 #endif
78 #if defined(CONFIG_LLC)
79 #define NEED_LLC
80 #endif
82 #include <net/psnapcall.h>
84 #ifdef CONFIG_TR
85 #include <linux/netdevice.h>
86 #include <linux/trdevice.h>
87 extern void rif_init(struct net_proto *);
88 #endif
90 #ifdef CONFIG_ATM
91 #include <linux/atm.h>
92 #endif
94 #ifdef NEED_LLC
95 #define NEED_802
96 #include <net/llccall.h>
97 #endif
99 #ifdef NEED_802
100 #include <net/p8022call.h>
101 #endif
105 * Protocol Table
108 struct net_proto protocols[] = {
109 #ifdef CONFIG_NETLINK
110 { "NETLINK", netlink_proto_init },
111 #endif
113 #ifdef CONFIG_PACKET
114 { "PACKET", packet_proto_init },
115 #endif
117 #ifdef CONFIG_UNIX
118 { "UNIX", unix_proto_init }, /* Unix domain socket family */
119 #endif
121 #ifdef NEED_802
122 { "802.2", p8022_proto_init }, /* 802.2 demultiplexor */
123 { "SNAP", snap_proto_init }, /* SNAP demultiplexor */
124 #endif
126 #ifdef CONFIG_TR
127 { "RIF", rif_init }, /* RIF for Token ring */
128 #endif
130 #ifdef CONFIG_ATM
131 { "ATMPVC", atmpvc_proto_init }, /* ATM PVCs */
132 { "ATMSVC", atmsvc_proto_init }, /* ATM SVCs */
133 #endif
135 #ifdef NEED_LLC
136 { "802.2LLC", llc_init }, /* 802.2 LLC */
137 #endif
139 #ifdef CONFIG_AX25
140 { "AX.25", ax25_proto_init }, /* Amateur Radio AX.25 */
141 #ifdef CONFIG_NETROM
142 { "NET/ROM", nr_proto_init }, /* Amateur Radio NET/ROM */
143 #endif
144 #ifdef CONFIG_ROSE
145 { "Rose", rose_proto_init }, /* Amateur Radio X.25 PLP */
146 #endif
147 #endif
148 #ifdef CONFIG_DECNET
149 { "DECnet", decnet_proto_init }, /* DECnet */
150 #endif
151 #ifdef CONFIG_INET
152 { "INET", inet_proto_init }, /* TCP/IP */
153 #ifdef CONFIG_IPV6
154 { "INET6", inet6_proto_init}, /* IPv6 */
155 #endif
156 #endif
158 #ifdef CONFIG_IPX
159 { "IPX", ipx_proto_init }, /* IPX */
160 #endif
162 #ifdef CONFIG_ATALK
163 { "DDP", atalk_proto_init }, /* Netatalk Appletalk driver */
164 #endif
166 #ifdef CONFIG_LAPB
167 { "LAPB", lapb_proto_init }, /* LAPB protocols */
168 #endif
170 #ifdef CONFIG_X25
171 { "X.25", x25_proto_init }, /* CCITT X.25 Packet Layer */
172 #endif
174 #ifdef CONFIG_ECONET
175 { "Econet", econet_proto_init }, /* Acorn Econet */
176 #endif
178 #ifdef CONFIG_IRDA
179 { "IrDA", irda_proto_init }, /* IrDA protocols */
180 #endif
181 { NULL, NULL } /* End marker */