Index: sys/geom/eli/pkcs5v2.c =================================================================== --- sys/geom/eli/pkcs5v2.c +++ sys/geom/eli/pkcs5v2.c @@ -108,6 +108,7 @@ /* * Return the number of iterations which takes 'usecs' microseconds. + * Never return fewer than 100,000 iterations. */ int pkcs5v2_calculate(int usecs) @@ -119,7 +120,7 @@ if (v > 2000000) break; } - return (((intmax_t)iterations * (intmax_t)usecs) / v); + return MAX((((intmax_t)iterations * (intmax_t)usecs) / v), 100000); } #endif /* !_STAND */ #endif /* !_KERNEL */