Page MenuHomeFreeBSD

altq: Increase maximum number of CBQ and HFSC classes
ClosedPublic

Authored by kp on Mar 3 2021, 11:07 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Dec 29, 5:43 AM
Unknown Object (File)
Nov 29 2024, 2:23 AM
Unknown Object (File)
Nov 8 2024, 3:00 PM
Unknown Object (File)
Nov 8 2024, 1:34 PM
Unknown Object (File)
Nov 8 2024, 11:43 AM
Unknown Object (File)
Nov 3 2024, 11:01 PM
Unknown Object (File)
Oct 22 2024, 12:45 PM
Unknown Object (File)
Oct 14 2024, 10:57 AM

Details

Summary

In some configurations we need more classes than ALTQ supports by
default. Increase the maximum number of classes we allow.
This will only cost us a comparatively trivial amount of memory, so
there's little reason not to do so.

If ever we find we want even more we may want to consider turning these
defines into a tunable, but for now do the easy thing.

MFC after: 2 weeks
Sponsored by: Rubicon Communications, LLC ("Netgate")

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

kp requested review of this revision.Mar 3 2021, 11:07 AM

How common is this requirement?
For normal production the customer is able to set the values manually before compiling.
I don't assume they will wait 3 week before having it in STABLE and some months to have it in RELEASE.

How common is this requirement?

I have no idea. Rubicon (i.e. pfSense) need this, and this is part of the diff-reduction effort.
64 HFSC classes isn't all that many if you want per-client queues.

For normal production the customer is able to set the values manually before compiling.

Yeah, but that's not ideal. If we want users to be able to tune this we should make it a tuneable rather than a compile-time value.

Happily the impact is very limited, because it really is only a tiny increase in memory use, and ALTQ is disabled by default anyway.
For HFSC it's literally ~2000 extra pointers, so as close to nothing as makes no difference. The CBQ structure is a bit bigger, but we're still talking about a few hundred kilobytes at most (for the extra ~1800 classes).

This revision is now accepted and ready to land.Mar 3 2021, 7:19 PM