HomeFreeBSD

Use boot_ncpus in place of max_ncpus in taskq_create

Description

Use boot_ncpus in place of max_ncpus in taskq_create

Due to hotplug support or BIOS bugs sometimes max_ncpus can be
an absurdly high value. I have a system with 32 cores/threads
but reports max_ncpus == 440. This many threads potentially
cripples the system during arc_prune floods for example.

boot_ncpus is the number of working CPUs when called so use
that instead.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: DHE <git@dehacked.net>
Closes #10282

Details

Provenance
DeHackEd <DeHackEd@users.noreply.github.com>Authored on May 20 2020, 5:07 PM
GitHub <noreply@github.com>Committed on May 20 2020, 5:07 PM
Parents
rGde4f06c27543: Small program that converts a dataset id and an object id to a path
Branches
Unknown
Tags
Unknown

Event Timeline

GitHub <noreply@github.com> committed rG57434abae6af: Use boot_ncpus in place of max_ncpus in taskq_create (authored by DeHackEd <DeHackEd@users.noreply.github.com>).May 20 2020, 5:07 PM