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

Function xform_attach

freebsd/netipsec/subr_ipsec.c:173–191  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

171#define XFORMS_UNLOCK() mtx_unlock(&xforms_lock)
172
173void
174xform_attach(void *data)
175{
176 struct xformsw *xsp, *entry;
177
178 xsp = (struct xformsw *)data;
179 XFORMS_LOCK();
180 LIST_FOREACH(entry, &xforms, chain) {
181 if (entry->xf_type == xsp->xf_type) {
182 XFORMS_UNLOCK();
183 printf("%s: failed to register %s xform\n",
184 __func__, xsp->xf_name);
185 return;
186 }
187 }
188 LIST_INSERT_HEAD(&xforms, xsp, chain);
189 xsp->xf_cntr = IPSEC_MODULE_ENABLED;
190 XFORMS_UNLOCK();
191}
192
193void
194xform_detach(void *data)

Callers 2

ipcomp_attachFunction · 0.85
tcpmd5_modeventFunction · 0.85

Calls 1

printfFunction · 0.50

Tested by

no test coverage detected