HomeFreeBSD

MFC r344903: Improve entropy for ZFS taskqueue selection.

Description

MFC r344903: Improve entropy for ZFS taskqueue selection.

I just found that at least on Skylake CPUs cpu_ticks() never returns odd
values, only even, and possibly has even bigger step (176/2?), that makes
its lower bits very bad entropy source, leaving half of taskqueues unused.
Switch to sbinuptime(), closer to upstreams, mitigates the problem by the
rate conversion working as kind of hash function. In case that is somehow
not enough (timer rate is too low or too divisible) mix in curcpu.

Details

Provenance
mavAuthored on
Parents
rS345121: MFC r344866: Add respective tunables to few ZFS sysctls.
Branches
Unknown
Tags
Unknown