opnsense-src/sys/kern
Ryan Moeller 92e17803cd Enable iterating all sysctls, even ones with CTLFLAG_SKIP
Add an "nextnoskip" sysctl that allows for listing of sysctls intended to be
normally skipped for cost reasons.

This makes it so the names/descriptions of those sysctls can be discovered with
sysctl -aN/sysctl -ad/sysctl -at.

It also makes it so children are visited when a node flagged with CTLFLAG_SKIP
is explicitly requested.

The intended use case is to mark the root "kstat" node with CTLFLAG_SKIP so that
the extensive and expensive stats are skipped by default but may still be easily
obtained without having to know them all (which may not even be possible) and
request each one-by-one.

Reviewed by:	jhb
MFC after:	2 weeks
Relnotes:	yes
Sponsored by:	iXsystems, Inc.
Differential Revision:	https://reviews.freebsd.org/D26560
2020-10-05 20:13:22 +00:00
..
bus_if.m Remove trailing white space. 2020-02-26 16:22:28 +00:00
capabilities.conf Permit cpuset_(get|set)domain() in capability mode. 2020-07-06 16:34:29 +00:00
clock_if.m
cpufreq_if.m
device_if.m
genassym.sh
genoffset.c Merge td_epochnest with td_no_sleeping. 2019-10-29 17:28:25 +00:00
genoffset.sh
imgact_aout.c Get rid of sv_errtbl and SV_ABI_ERRNO(). 2020-09-17 11:39:33 +00:00
imgact_binmisc.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
imgact_elf.c Fix the INVARIANTS build for 32-bit platforms 2020-10-02 18:54:37 +00:00
imgact_elf32.c
imgact_elf64.c
imgact_shell.c Add helper functions to copy strings into struct image_args. 2018-11-29 21:00:56 +00:00
init_main.c For mulitcons boot, report it and which console is primary 2020-09-28 16:19:29 +00:00
init_sysent.c Regen after r366145. 2020-09-25 10:05:38 +00:00
kern_acct.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_alq.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_clock.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_clocksource.c Rename hardclock_cnt() to hardclock() and remove the old implementation. 2018-09-06 02:10:59 +00:00
kern_condvar.c
kern_conf.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_cons.c Remove sysctl_kern_consmute() 2020-10-05 15:54:19 +00:00
kern_context.c Remove superfluous bzero in getcontext/swapcontext/sendsig 2018-11-26 20:56:05 +00:00
kern_cpu.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_cpuset.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_ctf.c vfs: drop the mostly unused flags argument from VOP_UNLOCK 2020-01-03 22:29:58 +00:00
kern_descrip.c cache: fix pwd use-after-free in setting up fallback 2020-10-05 19:38:51 +00:00
kern_dtrace.c
kern_dump.c - Cleanups related to sparc64 removal. 2020-07-28 10:58:37 +00:00
kern_environment.c Use getenv_is_true() in init_static_kenv() 2020-09-21 15:44:23 +00:00
kern_et.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_event.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_exec.c Remove pointless local variable. 2020-09-24 12:14:25 +00:00
kern_exit.c proc_realparent: if p_oppid does not match pid of the current parent 2020-09-16 21:38:24 +00:00
kern_fail.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_ffclock.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
kern_fork.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_hhook.c Remove duplicated empty lines from kern/*.c 2020-01-30 20:05:05 +00:00
kern_idle.c
kern_intr.c Allow swi_sched() to be called from NMI context. 2020-07-25 15:19:38 +00:00
kern_jail.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_kcov.c Mark COVERAGE and KCOV as part of KCSAN 2020-08-19 14:11:25 +00:00
kern_khelp.c
kern_kthread.c Do a lockless check in kthread_suspend_check 2020-07-25 07:14:33 +00:00
kern_ktr.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_ktrace.c Move KTRUSERRET() from userret() to ast(). It's a really long 2020-10-03 12:03:08 +00:00
kern_linker.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_lock.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_lockf.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_lockstat.c Add lockmgr(9) probes to the lockstat DTrace provider. 2019-08-21 23:43:58 +00:00
kern_loginclass.c Replace hand-rolled unrefs if > 1 with refcount_release_if_not_last 2018-12-07 16:11:45 +00:00
kern_malloc.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_mbuf.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_mib.c Add sysctl(8) formatting for hw.pagesizes. 2020-09-02 18:17:08 +00:00
kern_module.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_mtxpool.c Remove duplicated empty lines from kern/*.c 2020-01-30 20:05:05 +00:00
kern_mutex.c mtx: add mtx_wait_unlocked 2020-08-04 23:00:00 +00:00
kern_ntptime.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_osd.c
kern_physio.c Allocate pager bufs from UMA instead of 80-ish mutex protected linked list. 2019-01-15 01:02:16 +00:00
kern_pmc.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_poll.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
kern_priv.c vfs: respect PRIV_VFS_LOOKUP in vaccess_smr 2020-08-25 14:18:50 +00:00
kern_proc.c Put calls to check_pgrp_jobc() in fixjobc_kill() under INVARIANTS. 2020-09-17 00:07:15 +00:00
kern_procctl.c correct procctl(PROC_PROTMAX_STATUS _NOFORCE return 2020-05-01 14:30:59 +00:00
kern_prot.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_racct.c Move racct/rctl throttling from userret() to ast(). There's no reason 2020-09-14 09:44:24 +00:00
kern_rangelock.c rangelock: add rangelock_cookie_assert 2019-09-15 02:59:53 +00:00
kern_rctl.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_resource.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_rmlock.c rms: fix typo: bitmamp -> bitmap 2020-08-04 20:31:03 +00:00
kern_rwlock.c locks: fix a long standing bug for primitives with kdtrace but without spinning 2020-07-23 17:26:53 +00:00
kern_sdt.c
kern_sema.c
kern_sendfile.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_sharedpage.c kern_sharedpage.c: Add exec_sysvec_init_secondary() helper. 2020-08-23 19:43:47 +00:00
kern_shutdown.c Fix writing of the final block of encrypted, compressed kernel dumps. 2020-08-27 17:36:06 +00:00
kern_sig.c Add sig_intr(9). 2020-10-04 16:33:42 +00:00
kern_switch.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
kern_sx.c locks: fix a long standing bug for primitives with kdtrace but without spinning 2020-07-23 17:26:53 +00:00
kern_synch.c Handle PCATCH in blockcount_sleep() so it can be interrupted. 2020-04-21 17:13:06 +00:00
kern_syscalls.c add a sanity check to the system call registration code 2019-12-11 15:52:29 +00:00
kern_sysctl.c Enable iterating all sysctls, even ones with CTLFLAG_SKIP 2020-10-05 20:13:22 +00:00
kern_tc.c Remove double-calls to tc_get_timecount() to warm timecounters. 2020-06-10 22:30:32 +00:00
kern_thr.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
kern_thread.c Get rid of sa->narg. It serves no purpose; use sa->callp->sy_narg instead. 2020-09-27 18:47:06 +00:00
kern_time.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
kern_timeout.c Assert that cc_exec_drain(cc, direct) is NULL before assigning a new value. 2020-09-02 10:00:30 +00:00
kern_tslog.c
kern_ubsan.c Remove duplicated empty lines from kern/*.c 2020-01-30 20:05:05 +00:00
kern_umtx.c Support for userspace non-transparent superpages (largepages). 2020-09-09 22:12:51 +00:00
kern_uuid.c validate_uuid: absorb the rest of parse_uuid with a flags arg 2020-04-15 18:39:12 +00:00
kern_xxx.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
ksched.c
link_elf.c Convert allocations of the phys pager to vm_pager_allocate(). 2020-09-08 23:38:49 +00:00
link_elf_obj.c Convert allocations of the phys pager to vm_pager_allocate(). 2020-09-08 23:38:49 +00:00
linker_if.m
Make.tags.inc Remove a couple of harmless stray references to nandfs. 2019-06-25 16:39:25 +00:00
Makefile sys/kern sysent: re-add dependency on capabilities.conf 2020-02-12 19:06:34 +00:00
makesyscalls.sh makesyscalls.sh: improve the 'this is going away' message 2020-07-28 01:05:40 +00:00
md4c.c
md5c.c
msi_if.m
p1003_1b.c
pic_if.m
posix4_mib.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
sched_4bsd.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
sched_ule.c sys/: Document few more sysctls. 2020-03-02 15:30:52 +00:00
serdev_if.m
stack_protector.c Revert r346292 (permit_nonrandom_stackcookies) 2019-05-13 23:37:44 +00:00
subr_acl_nfs4.c Fix some signed/unsigned comparison warnings in NFS 2020-09-24 15:38:01 +00:00
subr_acl_posix1e.c vfs: remove the obsolete privused argument from vaccess 2020-08-05 09:27:03 +00:00
subr_atomic64.c emulated atomic64: disable interrupts as the lock mechanism on !SMP 2020-01-03 18:29:20 +00:00
subr_autoconf.c
subr_blist.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_boot.c When parsing command line stuff, treat tabs and spaces the same. 2019-04-18 22:52:12 +00:00
subr_bufring.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_bus.c Move to a more robust and conservative alloation scheme for devctl messages 2020-09-17 17:29:33 +00:00
subr_bus_dma.c Refine the busdma template interface. Provide tools for filling in fields 2020-09-14 05:58:12 +00:00
subr_busdma_bufalloc.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_capability.c Remove unused SYSINIT macros for capability rights. 2020-03-26 15:02:37 +00:00
subr_clock.c Remove duplicated empty lines from kern/*.c 2020-01-30 20:05:05 +00:00
subr_compressor.c clamp kernel dump compression level when using gzip 2020-02-20 23:53:48 +00:00
subr_counter.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_coverage.c Mark COVERAGE and KCOV as part of KCSAN 2020-08-19 14:11:25 +00:00
subr_csan.c Add NetBSD compatible bus_space_peek_N() and bus_space_poke_N() functions. 2020-09-19 11:06:41 +00:00
subr_devmap.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_devstat.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
subr_disk.c Fix botched merge with 355066 2019-03-12 05:10:41 +00:00
subr_dummy_vdso_tc.c
subr_early.c Add a file missed in r339321 2018-10-12 00:32:45 +00:00
subr_epoch.c Add full support support for dynamic allocation and freeing of epoch's. 2020-08-07 15:32:42 +00:00
subr_eventhandler.c Include ktr.h in more compilation units 2019-05-21 20:38:48 +00:00
subr_fattime.c Remove duplicated empty lines from kern/*.c 2020-01-30 20:05:05 +00:00
subr_filter.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_firmware.c Fix a panic when unloading firmware 2020-06-29 21:35:50 +00:00
subr_gtaskqueue.c Remove the "config" taskqgroup and its KPIs. 2020-03-30 14:24:03 +00:00
subr_hash.c
subr_hints.c Remove duplicated empty lines from kern/*.c 2020-01-30 20:05:05 +00:00
subr_intr.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_kdb.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
subr_kobj.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_lock.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_log.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_mchain.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_module.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_msgbuf.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_param.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
subr_pcpu.c Add COUNTER_U64_SYSINIT() and COUNTER_U64_DEFINE_EARLY(). 2020-03-06 19:09:01 +00:00
subr_pctrie.c Use SMR to provide safe unlocked lookup for pctries from SMR zones 2020-07-24 17:32:10 +00:00
subr_physmem.c Convert arm's physmem interface to MI code 2020-04-19 00:12:30 +00:00
subr_pidctrl.c
subr_power.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_prf.c remove %n support from printf(9) 2020-05-09 15:56:02 +00:00
subr_prng.c Add prng(9) API 2020-08-13 20:48:14 +00:00
subr_prof.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
subr_rangeset.c Implement rangesets. 2019-02-20 09:38:19 +00:00
subr_rman.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
subr_rtc.c Address whitespace nits in subr_rtc.c 2020-09-28 17:19:57 +00:00
subr_sbuf.c Remove duplicated empty lines from kern/*.c 2020-01-30 20:05:05 +00:00
subr_scanf.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_sfbuf.c
subr_sglist.c Step 4.2: start divorce of M_EXT and M_EXTPG 2020-05-03 00:37:16 +00:00
subr_sleepqueue.c Refactor sleepq_catch_signals(). 2020-10-04 16:30:05 +00:00
subr_smp.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_smr.c Use COUNTER_U64_DEFINE_EARLY() in places where it simplifies things. 2020-03-06 19:10:00 +00:00
subr_stack.c kern.tty_info_kstacks: add a compact format 2020-07-06 16:33:28 +00:00
subr_stats.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
subr_syscall.c Only clear TDP_NERRNO when needed, ie when it's previously been set. 2020-10-01 18:45:31 +00:00
subr_taskqueue.c Add flag to struct task to mark the task as requiring network epoch. 2020-02-11 18:48:07 +00:00
subr_terminal.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_trap.c Move KTRUSERRET() from userret() to ast(). It's a really long 2020-10-03 12:03:08 +00:00
subr_turnstile.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_uio.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_unit.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
subr_vmem.c vmem: Avoid allocating span tags when segments are never released. 2020-08-26 14:31:35 +00:00
subr_witness.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
sys_capability.c Enter a write sequence when updating rights. 2020-03-19 15:39:45 +00:00
sys_generic.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
sys_getrandom.c Fix a typo in r356667 comment 2020-01-12 23:52:16 +00:00
sys_pipe.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
sys_procdesc.c procdesc: allow to collect status through wait(1) if process is traced 2019-11-25 18:33:21 +00:00
sys_process.c Get rid of sa->narg. It serves no purpose; use sa->callp->sy_narg instead. 2020-09-27 18:47:06 +00:00
sys_socket.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
syscalls.c Update the files created from the new syscalls.master from r361599. 2020-05-28 21:23:02 +00:00
syscalls.master Add a syscall for the nfs-over-tls daemons to use. 2020-05-28 21:06:10 +00:00
systrace_args.c Update the files created from the new syscalls.master from r361599. 2020-05-28 21:23:02 +00:00
sysv_ipc.c sysv: get rid of fork/exit hooks if the code is compiled in 2019-05-04 19:05:30 +00:00
sysv_msg.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
sysv_sem.c Apply the logic from r363051 to semctl(2) and __sem_base field. 2020-07-09 18:34:54 +00:00
sysv_shm.c Centralize compatability translation macros. 2020-04-14 20:30:48 +00:00
tty.c Implement FLUSHO 2020-08-27 05:11:15 +00:00
tty_compat.c
tty_info.c kern.tty_info_kstacks: set compact format as default 2020-07-06 16:34:15 +00:00
tty_inq.c
tty_outq.c
tty_pts.c tty_pts: don't rely on tty header pollution for sys/mutex.h 2019-11-29 03:56:01 +00:00
tty_tty.c Extract eventfilter declarations to sys/_eventfilter.h 2019-05-20 00:38:23 +00:00
tty_ttydisc.c Implement FLUSHO 2020-08-27 05:11:15 +00:00
uipc_accf.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
uipc_debug.c
uipc_domain.c - Move global network epoch definition to epoch.h, as more different 2020-01-15 03:34:21 +00:00
uipc_ktls.c uipc_ktls: remove unused static function 2020-09-05 00:19:40 +00:00
uipc_mbuf.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
uipc_mbuf2.c m_pulldown(): Change an if () panic() into a KASSERT(). 2019-11-06 22:40:19 +00:00
uipc_mbufhash.c
uipc_mqueue.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
uipc_sem.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
uipc_shm.c Add a vmparam.h constant indicating pmap support for large pages. 2020-09-23 19:34:21 +00:00
uipc_sockbuf.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
uipc_socket.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
uipc_syscalls.c Only enable COMPAT_43 changes for syscalls ABI for a.out processes. 2019-08-11 19:16:07 +00:00
uipc_usrreq.c Fix locking in uipc_accept(). 2020-09-15 23:03:56 +00:00
vfs_acl.c vfs: fix trivial whitespace issues which don't interefere with blame 2020-07-10 09:01:36 +00:00
vfs_aio.c Avoid a dubious assignment to bio_data in aio_qbio(). 2020-09-30 17:49:06 +00:00
vfs_bio.c Revert r366340. 2020-10-01 20:08:27 +00:00
vfs_cache.c cache: fix pwd use-after-free in setting up fallback 2020-10-05 19:38:51 +00:00
vfs_cluster.c vfs: fix trivial whitespace issues which don't interefere with blame 2020-07-10 09:01:36 +00:00
vfs_default.c Convert page cache read to VOP. 2020-09-15 22:06:36 +00:00
vfs_export.c kern: clean up empty lines in .c and .h files 2020-09-01 22:12:32 +00:00
vfs_extattr.c vfs_extattr: Allow extattr names up to the full max 2020-05-14 03:01:23 +00:00
vfs_hash.c vfs: avoid exposing partially constructed vnodes 2020-09-05 00:26:03 +00:00
vfs_init.c vfs: fix trivial whitespace issues which don't interefere with blame 2020-07-10 09:01:36 +00:00
vfs_lookup.c Add O_RESOLVE_BENEATH and AT_RESOLVE_BENEATH to mimic Linux' RESOLVE_BENEATH. 2020-09-22 22:48:12 +00:00
vfs_mount.c cache: drop the force flag from purgevfs 2020-09-23 10:46:07 +00:00
vfs_mountroot.c cache: drop the force flag from purgevfs 2020-09-23 10:46:07 +00:00
vfs_subr.c Convert page cache read to VOP. 2020-09-15 22:06:36 +00:00
vfs_syscalls.c Add O_RESOLVE_BENEATH and AT_RESOLVE_BENEATH to mimic Linux' RESOLVE_BENEATH. 2020-09-22 22:48:12 +00:00
vfs_vnops.c Clip the "len" argument to vn_generic_copy_file_range() at a 2020-10-01 00:33:44 +00:00
vnode_if.src Convert page cache read to VOP. 2020-09-15 22:06:36 +00:00