]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
FreeBSD: Hardcode abd_chunk_size to PAGE_SIZE
authorAlexander Motin <mav@FreeBSD.org>
Wed, 7 Jul 2021 00:39:23 +0000 (20:39 -0400)
committerTony Hutter <hutter2@llnl.gov>
Tue, 14 Sep 2021 19:36:44 +0000 (12:36 -0700)
commit49bb454120d994ba87d171689f017a7b48f706e3
treee2705b961e8225b8fdb27bdd22bc43db53ce689c
parent41b33dce4438b5d810597b72fbc21ad1feb85441
FreeBSD: Hardcode abd_chunk_size to PAGE_SIZE

It makes no sense to set it below PAGE_SIZE, since it increases all
overheads and makes returning memory to OS problematic.  It makes no
sense to set it above PAGE_SIZE, since such allocations and especially
frees are too expensive and cause KVA fragmentation to benefit from
fewer chunks.  After that it makes no sense to keep more complicated
math here.

What may have sense though is just a tunable border between linear and
scatter ABDs, previously also controlled by this tunable.  Retain that
functionality by taking abd_scatter_min_size tunable from Linux, just
with different default value.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Brian Atkinson <batkinson@lanl.gov>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Signed-off-by: Alexander Motin <mav@FreeBSD.org>
Closes #12328
include/sys/abd.h
module/os/freebsd/zfs/abd_os.c