Lines Matching full:threshold
125 "Invalid threshold direction specified in entity manager"); in getThresholdType()
146 "Invalid threshold severity specified in entity manager"); in getSeverityField()
158 "Invalid threshold severity specified in entity manager"); in getSeverityField()
180 auto threshold = getThresholdType(direction, severity); in parseThresholds() local
181 thresholds[threshold] = value; in parseThresholds()
187 thresholds[threshold + "Hysteresis"] = hysteresis; in parseThresholds()
192 thresholds[threshold + "Direction"] = entityInterface; in parseThresholds()
243 /* Get threshold values if defined in config */ in initVirtualSensor()
244 auto threshold = sensorConfig.value("Threshold", empty); in initVirtualSensor() local
246 createThresholds(threshold, objPath, units); in initVirtualSensor()
401 /* Each threshold is on it's own interface with a number as a suffix in initVirtualSensor()
498 sdbusplus::event::xyz::openbmc_project::sensor::Threshold; in updateVirtualSensor()
514 const Json& threshold, const std::string& objPath, ValueIface::Unit units) in createThresholds() argument
516 if (threshold.empty()) in createThresholds()
520 // Only create the threshold interfaces if in createThresholds()
522 if (threshold.contains("CriticalHigh") || threshold.contains("CriticalLow")) in createThresholds()
524 criticalIface = std::make_unique<Threshold<CriticalObject>>( in createThresholds()
527 if (threshold.contains("CriticalHigh")) in createThresholds()
530 threshold.value("CriticalHighDirection", "")); in createThresholds()
531 debug("Sensor Threshold:{NAME} = intf:{INTF}", "NAME", objPath, in createThresholds()
532 "INTF", threshold.value("CriticalHighDirection", "")); in createThresholds()
534 if (threshold.contains("CriticalLow")) in createThresholds()
537 threshold.value("CriticalLowDirection", "")); in createThresholds()
538 debug("Sensor Threshold:{NAME} = intf:{INTF}", "NAME", objPath, in createThresholds()
539 "INTF", threshold.value("CriticalLowDirection", "")); in createThresholds()
543 debug("Sensor Threshold:{NAME} = path:{PATH}", "NAME", objPath, "PATH", in createThresholds()
546 criticalIface->criticalHigh(threshold.value( in createThresholds()
548 criticalIface->criticalLow(threshold.value( in createThresholds()
551 threshold.value("CriticalHighHysteresis", defaultHysteresis)); in createThresholds()
553 threshold.value("CriticalLowHysteresis", defaultHysteresis)); in createThresholds()
556 if (threshold.contains("WarningHigh") || threshold.contains("WarningLow")) in createThresholds()
558 warningIface = std::make_unique<Threshold<WarningObject>>( in createThresholds()
561 if (threshold.contains("WarningHigh")) in createThresholds()
564 threshold.value("WarningHighDirection", "")); in createThresholds()
565 debug("Sensor Threshold:{NAME} = intf:{INTF}", "NAME", objPath, in createThresholds()
566 "INTF", threshold.value("WarningHighDirection", "")); in createThresholds()
568 if (threshold.contains("WarningLow")) in createThresholds()
571 threshold.value("WarningLowDirection", "")); in createThresholds()
572 debug("Sensor Threshold:{NAME} = intf:{INTF}", "NAME", objPath, in createThresholds()
573 "INTF", threshold.value("WarningLowDirection", "")); in createThresholds()
577 debug("Sensor Threshold:{NAME} = path:{PATH}", "NAME", objPath, "PATH", in createThresholds()
580 warningIface->warningHigh(threshold.value( in createThresholds()
582 warningIface->warningLow(threshold.value( in createThresholds()
585 threshold.value("WarningHighHysteresis", defaultHysteresis)); in createThresholds()
587 threshold.value("WarningLowHysteresis", defaultHysteresis)); in createThresholds()
590 if (threshold.contains("HardShutdownHigh") || in createThresholds()
591 threshold.contains("HardShutdownLow")) in createThresholds()
593 hardShutdownIface = std::make_unique<Threshold<HardShutdownObject>>( in createThresholds()
596 hardShutdownIface->hardShutdownHigh(threshold.value( in createThresholds()
598 hardShutdownIface->hardShutdownLow(threshold.value( in createThresholds()
601 threshold.value("HardShutdownHighHysteresis", defaultHysteresis)); in createThresholds()
603 threshold.value("HardShutdownLowHysteresis", defaultHysteresis)); in createThresholds()
606 if (threshold.contains("SoftShutdownHigh") || in createThresholds()
607 threshold.contains("SoftShutdownLow")) in createThresholds()
609 softShutdownIface = std::make_unique<Threshold<SoftShutdownObject>>( in createThresholds()
612 softShutdownIface->softShutdownHigh(threshold.value( in createThresholds()
614 softShutdownIface->softShutdownLow(threshold.value( in createThresholds()
617 threshold.value("SoftShutdownHighHysteresis", defaultHysteresis)); in createThresholds()
619 threshold.value("SoftShutdownLowHysteresis", defaultHysteresis)); in createThresholds()
622 if (threshold.contains("PerformanceLossHigh") || in createThresholds()
623 threshold.contains("PerformanceLossLow")) in createThresholds()
625 perfLossIface = std::make_unique<Threshold<PerformanceLossObject>>( in createThresholds()
628 perfLossIface->performanceLossHigh(threshold.value( in createThresholds()
630 perfLossIface->performanceLossLow(threshold.value( in createThresholds()
632 perfLossIface->setHighHysteresis(threshold.value( in createThresholds()
635 threshold.value("PerformanceLossLowHysteresis", defaultHysteresis)); in createThresholds()