File tree Expand file tree Collapse file tree
nixos/modules/system/boot Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1285,6 +1285,21 @@ let
12851285 "QuantumBytes"
12861286 ] )
12871287 ] ;
1288+
1289+ sectionEnhancedTransmissionSelection = checkUnitConfig "EnhancedTransmissionSelection" [
1290+ ( assertOnlyFields [
1291+ "Parent"
1292+ "Handle"
1293+ "Bands"
1294+ "StrictBands"
1295+ "QuantumBytes"
1296+ "PriorityMap"
1297+ ] )
1298+ ( assertInt "Bands" )
1299+ ( assertRange "Bands" 1 16 )
1300+ ( assertInt "StrictBands" )
1301+ ( assertRange "StrictBands" 1 16 )
1302+ ] ;
12881303 } ;
12891304 } ;
12901305
@@ -2118,6 +2133,17 @@ let
21182133 '' ;
21192134 } ;
21202135
2136+ enhancedTransmissionSelectionConfig = mkOption {
2137+ default = { } ;
2138+ example = { Parent = "root" ; QuantumBytes = "300k" ; Bands = 3 ; PriorityMap = "100 200 300" ; } ;
2139+ type = types . addCheck ( types . attrsOf unitOption ) check . network . sectionEnhancedTransmissionSelection ;
2140+ description = lib . mdDoc ''
2141+ Each attribute in this set specifies an option in the
2142+ `[EnhancedTransmissionSelection]` section of the unit. See
2143+ {manpage}`systemd.network(5)` for details.
2144+ '' ;
2145+ } ;
2146+
21212147 name = mkOption {
21222148 type = types . nullOr types . str ;
21232149 default = null ;
@@ -2609,6 +2635,10 @@ let
26092635 [DeficitRoundRobinSchedulerClass]
26102636 ${ attrsToSection def . deficitRoundRobinSchedulerClassConfig }
26112637 ''
2638+ + optionalString ( def . enhancedTransmissionSelectionConfig != { } ) ''
2639+ [EnhancedTransmissionSelection]
2640+ ${ attrsToSection def . enhancedTransmissionSelectionConfig }
2641+ ''
26122642 + def . extraConfig ;
26132643 } ;
26142644
You can’t perform that action at this time.
0 commit comments