HomeFreeBSD

rctl(4): support throttling resource usage to 0

Description

rctl(4): support throttling resource usage to 0

For rate-based resources that support throttling (e.g.
readiops/writeips), this fixes a divide-by-zero panic when rctl(8)
passes 0 as the throttle value. For these resources, treat
zero-throttle requests as requests to suspend forward progress as long
as possible using the duration specified in
kern.racct.rctl.throttle_max.

PR: 251803
Reported by: chris@cretaforce.gr
Reviewed by: kib
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D27858

Details

Provenance
jahAuthored on Dec 30 2020, 11:29 PM
Reviewer
kib
Differential Revision
D27858: rctl(4): support throttling resource usage to 0
Parents
rG2defbe9f0e01: Use rn_match instead of doing indirect calls in fib_algo.
Branches
Unknown
Tags
Unknown