freebsd-dev/sys/geom
Alexander Motin 5c32e9fcb2 Optimize kern.geom.conf* sysctls.
On large systems those sysctls may generate megabytes of output.  Before
this change sbuf(9) code was resizing buffer by 4KB each time many times,
generating tons of TLB shootdowns.  Unfortunately in this case existing
sbuf_new_for_sysctl() mechanism, supposed to help with this issue, is not
applicable, since all the sbuf writes are done in different kernel thread.

This change improves situation in two ways:
 - on first sysctl call, not providing any output buffer, it sets special
sbuf drain function, just counting the data and so not needing big buffer;
 - on second sysctl call it uses as initial buffer size value saved on
previous call, so that in most cases there will be no reallocation, unless
GEOM topology changed significantly.

MFC after:	1 week
Sponsored by:	iXsystems, Inc.
2019-06-18 21:05:10 +00:00
..
bde Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
cache Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
concat Add a missing return statement to g_concat_kernel_dump(). 2019-02-26 18:30:51 +00:00
eli geli: style nits 2019-06-12 19:29:48 +00:00
gate geom_gate: enable resize 2018-07-13 07:08:06 +00:00
journal Normally when an attempt is made to mount a UFS/FFS filesystem whose 2018-12-06 00:09:39 +00:00
label Support device-independent labels for geom_flashmap slices. 2019-03-24 19:11:45 +00:00
linux_lvm Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
mirror gmirror: Relocate DEVICE_FLAGS to adjacent lines 2019-01-23 16:44:21 +00:00
mountver Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
multipath Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
nop When using the destroy option to shut down a nop GEOM module, I/O 2019-05-25 00:07:49 +00:00
part Separate kernel crc32() implementation to its own header (gsb_crc32.h) and 2019-06-17 19:49:08 +00:00
raid Separate kernel crc32() implementation to its own header (gsb_crc32.h) and 2019-06-17 19:49:08 +00:00
raid3 Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
sched sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
shsec Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
stripe Extend stripeoffset and stripesize of GEOMs from u_int to off_t 2018-10-27 16:14:42 +00:00
uzip Modularize xz. 2019-02-26 19:55:03 +00:00
vinum Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
virstor Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
zero Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom_bsd_enc.c sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_bsd.c Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom_ccd.c Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom_ctl.c Define a constant for the maximum number of GEOM_CTL arguments. 2019-02-20 17:07:08 +00:00
geom_ctl.h Define a constant for the maximum number of GEOM_CTL arguments. 2019-02-20 17:07:08 +00:00
geom_dev.c List-ify kernel dump device configuration 2019-05-06 18:24:07 +00:00
geom_disk.c geom_disk / scsi_da: deny opening write-protected disks for writing 2018-01-15 11:20:00 +00:00
geom_disk.h Extend stripeoffset and stripesize of GEOMs from u_int to off_t 2018-10-27 16:14:42 +00:00
geom_dump.c Extend stripeoffset and stripesize of GEOMs from u_int to off_t 2018-10-27 16:14:42 +00:00
geom_event.c Instrument "boot holds" for the benefit of the TSLOG framework. These 2017-12-31 09:23:52 +00:00
geom_flashmap.c Support device-independent labels for geom_flashmap slices. 2019-03-24 19:11:45 +00:00
geom_flashmap.h Support device-independent labels for geom_flashmap slices. 2019-03-24 19:11:45 +00:00
geom_fox.c Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom_int.h sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_io.c stack(9): Drop unused API mode and comment that referenced it 2019-03-15 22:39:55 +00:00
geom_kern.c Optimize kern.geom.conf* sysctls. 2019-06-18 21:05:10 +00:00
geom_map.c Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom_mbr_enc.c sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_mbr.c Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom_redboot.c Extend stripeoffset and stripesize of GEOMs from u_int to off_t 2018-10-27 16:14:42 +00:00
geom_slice.c sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_slice.h sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_subr.c Extend stripeoffset and stripesize of GEOMs from u_int to off_t 2018-10-27 16:14:42 +00:00
geom_sunlabel_enc.c sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_sunlabel.c Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom_vfs.c sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_vfs.h sys/geom: adoption of SPDX licensing ID tags. 2017-11-27 15:17:37 +00:00
geom_vol_ffs.c Annotate geom modules with MODULE_VERSION 2018-04-10 19:18:16 +00:00
geom.h geom: fix initialization order 2019-05-06 09:48:34 +00:00
notes