Hi/Lo Thresholds only for extrema and prog-extrema.
Added condition to mandate high and low thresholds only for extrema and progressive extrema power capping strategies.
This commit is contained in:
parent
089b106fdb
commit
5a6a43937c
1 changed files with 12 additions and 8 deletions
20
scheduler.go
20
scheduler.go
|
@ -179,16 +179,20 @@ func main() {
|
||||||
} else {
|
} else {
|
||||||
if *powerCapPolicy == "extrema" {
|
if *powerCapPolicy == "extrema" {
|
||||||
extrema = true
|
extrema = true
|
||||||
} else {
|
} else if *powerCapPolicy == "prog-extrema" {
|
||||||
progExtrema = true
|
progExtrema = true
|
||||||
}
|
}
|
||||||
// High and Low Thresholds.
|
// High and Low thresholds are currently only needed for extrema and
|
||||||
// These values are not used to configure the scheduler.
|
// progressive extrema.
|
||||||
// hiThreshold and loThreshold are passed to the powercappers.
|
if extrema || progExtrema {
|
||||||
if *hiThreshold < *loThreshold {
|
// High and Low Thresholds.
|
||||||
logger.WriteLog(elekLogDef.ERROR, "High threshold is of a"+
|
// These values are not used to configure the scheduler.
|
||||||
" lower value than low threshold.")
|
// hiThreshold and loThreshold are passed to the powercappers.
|
||||||
os.Exit(1)
|
if *hiThreshold < *loThreshold {
|
||||||
|
logger.WriteLog(elekLogDef.ERROR, "High threshold is of a"+
|
||||||
|
" lower value than low threshold.")
|
||||||
|
os.Exit(1)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Reference in a new issue