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

Function linker_file_enable_sysctls

freebsd/kern/kern_linker.c:317–337  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

315}
316
317static void
318linker_file_enable_sysctls(linker_file_t lf)
319{
320 struct sysctl_oid **start, **stop, **oidp;
321
322 KLD_DPF(FILE,
323 ("linker_file_enable_sysctls: enable SYSCTLs for %s\n",
324 lf->filename));
325
326 sx_assert(&kld_sx, SA_XLOCKED);
327
328 if (linker_file_lookup_set(lf, "sysctl_set", &start, &stop, NULL) != 0)
329 return;
330
331 sx_xunlock(&kld_sx);
332 sysctl_wlock();
333 for (oidp = start; oidp < stop; oidp++)
334 sysctl_enable_oid(*oidp);
335 sysctl_wunlock();
336 sx_xlock(&kld_sx);
337}
338
339static void
340linker_file_unregister_sysctls(linker_file_t lf)

Callers 1

linker_load_fileFunction · 0.85

Calls 4

linker_file_lookup_setFunction · 0.85
sysctl_wlockFunction · 0.85
sysctl_enable_oidFunction · 0.85
sysctl_wunlockFunction · 0.85

Tested by

no test coverage detected