]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
pidctrl_daemon() implements a variation on the classical, discrete PID
authoralc <alc@FreeBSD.org>
Thu, 7 Jun 2018 02:54:11 +0000 (02:54 +0000)
committeralc <alc@FreeBSD.org>
Thu, 7 Jun 2018 02:54:11 +0000 (02:54 +0000)
commitffaddd3ad94563f2fe0d20a919c7442e32e1edff
treeed3b64c121b244d2b194911fe8f9bb38638446a0
parent972bb0b63c8dc9237e2143812838c97b49e12501
pidctrl_daemon() implements a variation on the classical, discrete PID
controller that tries to handle early invocations of the controller,
in other words, invocations before the expected end of the interval.
However, there were some calculation errors in this early invocation
case.  Notably, if an early invocation occurred while the error was
negative, the derivative term was off by a large amount.  One visible
effect of this error was that processes were being killed by the
virtual memory system's OOM killer when in fact there was plentiful
free memory.

Correct a couple minor errors in the sysctl descriptions, and apply
some style fixes.

Reviewed by: jeff, markj
sys/kern/subr_pidctrl.c