MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sctp_module_load

Function sctp_module_load

freebsd/netinet/sctp_module.c:115–146  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

113#endif
114
115static int
116sctp_module_load(void)
117{
118 int error;
119
120#ifdef INET
121 error = pf_proto_register(PF_INET, &sctp_stream_protosw);
122 if (error != 0)
123 return (error);
124 error = pf_proto_register(PF_INET, &sctp_seqpacket_protosw);
125 if (error != 0)
126 return (error);
127 error = ipproto_register(IPPROTO_SCTP);
128 if (error != 0)
129 return (error);
130#endif
131#ifdef INET6
132 error = pf_proto_register(PF_INET6, &sctp6_stream_protosw);
133 if (error != 0)
134 return (error);
135 error = pf_proto_register(PF_INET6, &sctp6_seqpacket_protosw);
136 if (error != 0)
137 return (error);
138 error = ip6proto_register(IPPROTO_SCTP);
139 if (error != 0)
140 return (error);
141#endif
142 error = sctp_syscalls_init();
143 if (error != 0)
144 return (error);
145 return (0);
146}
147
148static int __unused
149sctp_module_unload(void)

Callers 1

sctp_modloadFunction · 0.85

Calls 4

pf_proto_registerFunction · 0.85
ipproto_registerFunction · 0.85
ip6proto_registerFunction · 0.85
sctp_syscalls_initFunction · 0.85

Tested by

no test coverage detected