mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-11-17 01:51:00 +03:00
eb51a9d747
If sufficient memory (<2K, realistically) is available, libzfs_init() can be significantly shorted by iterating over the correct sysfs directory before registrations, we can turn 168 stats into 15/18 syscalls (3 opens (6 if built in), 3 fstats, 6 getdentses, and 3 closes), a tenfoldish reduction; this is probably a bit faster, too. The list is always optional, and registration functions (and one-off users) can simply pass NULL, which will fall back to the previous mechanism Also, don't allocate in zfs_mod_supported_impl, and use use access() instead of stat(), since existence is really what we care about Also, fix pre-prop-checking compat in fallback for built-in ZFS Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Tony Nguyen <tony.nguyen@delphix.com> Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Closes #12089 |
||
---|---|---|
.. | ||
os | ||
.gitignore | ||
libzfs_changelist.c | ||
libzfs_config.c | ||
libzfs_crypto.c | ||
libzfs_dataset.c | ||
libzfs_diff.c | ||
libzfs_impl.h | ||
libzfs_import.c | ||
libzfs_iter.c | ||
libzfs_mount.c | ||
libzfs_pool.c | ||
libzfs_sendrecv.c | ||
libzfs_status.c | ||
libzfs_util.c | ||
libzfs.abi | ||
libzfs.pc.in | ||
libzfs.suppr | ||
Makefile.am | ||
THIRDPARTYLICENSE.openssl | ||
THIRDPARTYLICENSE.openssl.descrip |