#
f5402197 |
| 16-Aug-2024 |
Patrick Williams <patrick@stwcx.xyz> |
clang-format: re-format for clang-18
clang-format-18 isn't compatible with the clang-format-17 output, so we need to reformat the code with the latest version. The way clang-18 handles lambda forma
clang-format: re-format for clang-18
clang-format-18 isn't compatible with the clang-format-17 output, so we need to reformat the code with the latest version. The way clang-18 handles lambda formatting also changed, so we have made changes to the organization default style format to better handle lambda formatting.
See I5e08687e696dd240402a2780158664b7113def0e for updated style. See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement.
Change-Id: I7b90380845efee6bf6a1fe342a793d71aa9ff181 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
41a6b9f3 |
| 31-May-2023 |
Patrick Williams <patrick@stwcx.xyz> |
remove unnecessary std::move calls
GCC 13 now flags a std::move of an returned temporary as unnecessary and likely preventing RVO. Remove the unnecessary std::move.
Signed-off-by: Patrick Williams
remove unnecessary std::move calls
GCC 13 now flags a std::move of an returned temporary as unnecessary and likely preventing RVO. Remove the unnecessary std::move.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: Ibde052b5a4efd84bdbbac2f2f6e673729b32e6cd
show more ...
|
#
48781aef |
| 10-May-2023 |
Patrick Williams <patrick@stwcx.xyz> |
clang-format: copy latest and re-format
clang-format-16 has some backwards incompatible changes that require additional settings for best compatibility and re-running the formatter. Copy the latest
clang-format: copy latest and re-format
clang-format-16 has some backwards incompatible changes that require additional settings for best compatibility and re-running the formatter. Copy the latest .clang-format from the docs repository and reformat the repository.
Change-Id: If66f68c96df4baf8dc07abf8729a3cb7657e932d Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
fa2734d6 |
| 30-Mar-2022 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Retry failed sensor monitoring
If a failure occurs while trying to read voltage regulator sensors, retry the operation 5 times before logging an error.
This provides "de-glitching" to i
regulators: Retry failed sensor monitoring
If a failure occurs while trying to read voltage regulator sensors, retry the operation 5 times before logging an error.
This provides "de-glitching" to ignore transient hardware problems.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I310c15eb0f0d36d938057d6280a12b5aef854d20
show more ...
|
#
2ee4494c |
| 09-Sep-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Clear phase fault history in Device
Enhance the clearErrorHistory() method of the Device class to clear phase fault error history.
Update the gtest test case to exercise the modified co
regulators: Clear phase fault history in Device
Enhance the clearErrorHistory() method of the Device class to clear phase fault error history.
Update the gtest test case to exercise the modified code.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I109932c0f4812bb36af05ac24e47a561270b4fcc
show more ...
|
#
1fd0b145 |
| 09-Sep-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add detectPhaseFaults() to Device
Add a detectPhaseFaults() method to the Device class. This method executes the PhaseFaultDetection data member added in a previous commit.
Add a gtest
regulators: Add detectPhaseFaults() to Device
Add a detectPhaseFaults() method to the Device class. This method executes the PhaseFaultDetection data member added in a previous commit.
Add a gtest test case to exercise the new code.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: Ie8a2bf7d1b60ebc29c256e8563e3e4808bb6a20e
show more ...
|
#
2874e902 |
| 09-Sep-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Simplify Device test cases
Simplify the gtest test cases for the Device class by making the following enhancements: * Convert the test suite to a test fixture class. Automatically creat
regulators: Simplify Device test cases
Simplify the gtest test cases for the Device class by making the following enhancements: * Convert the test suite to a test fixture class. Automatically create the parent Chassis and System objects in the class constructor. * Use auto when creating objects using std::make_unique() to eliminate redundant type declarations. * Define a constant for the Device inventory path.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I86702a33c7ea7e1595ec251935e648c1c228d02b
show more ...
|
#
32252599 |
| 08-Sep-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add PhaseFaultDetection to Device
Add a PhaseFaultDetection data member to the Device class. This is the first step in enabling phase fault detection for Device objects.
Create and mod
regulators: Add PhaseFaultDetection to Device
Add a PhaseFaultDetection data member to the Device class. This is the first step in enabling phase fault detection for Device objects.
Create and modify gtest test cases to exercise new code.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: Icc771eda5c79ace854acb1d7c395b82b34213996
show more ...
|
#
371e244a |
| 14-May-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add clearErrorHistory to Device class
Add a clearErrorHistory() method to the Device class. The method should clear all data on previously logged errors. If the error occurs again in t
regulators: Add clearErrorHistory to Device class
Add a clearErrorHistory() method to the Device class. The method should clear all data on previously logged errors. If the error occurs again in the future, it will be logged again.
This method is normally called when the system is being powered on. For code that runs repeatedly, errors are only logged once per boot.
When the system is powered off, hardware may be replaced that fixes the problem. Thus, errors are cleared during power on.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I6683b0c7b9abd61748ccb3512dda9111daed4929
show more ...
|
#
17bac89e |
| 08-May-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Complete SensorMonitoring class
Complete the SensorMonitoring class. This class implements the "sensor_monitoring" object in the JSON config file.
Add calls to the startRail() and endR
regulators: Complete SensorMonitoring class
Complete the SensorMonitoring class. This class implements the "sensor_monitoring" object in the JSON config file.
Add calls to the startRail() and endRail() methods of the Sensors service.
Add ErrorHistory data member so that errors are only logged once per boot since sensor monitoring occurs repeatedly once per second.
Add error count data member to limit the number of error messages written to the journal since monitoring occurs repeatedly.
Update all affected test cases.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I0bd20d03ccea9e15cd0f97529f6ccdad2fa015c8
show more ...
|
#
cb3f6a63 |
| 30-Apr-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add inventory path to Chassis class
A previous commit added the "inventory_path" property to the "chassis" object in the JSON configuration file.
This commit adds that new property to t
regulators: Add inventory path to Chassis class
A previous commit added the "inventory_path" property to the "chassis" object in the JSON configuration file.
This commit adds that new property to the C++ implementation: * Chassis class and associated gtests * JSON configuration file parser functions and associated gtests * Other gtests affected by the change to the Chassis constructor
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I7406f874263d01e6faa2b8c333cb1baf915cf2ac
show more ...
|
#
2f9e14f6 |
| 29-Apr-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Convert to new SensorType enumeration
There are several types of voltage regulator sensors, such as vout, iout, and temperature.
The sensor types were previously defined by the enumerat
regulators: Convert to new SensorType enumeration
There are several types of voltage regulator sensors, such as vout, iout, and temperature.
The sensor types were previously defined by the enumeration pmbus_utils::SensorValueType. This enumeration should not have been placed in the pmbus_utils namespace because it is not specific to PMBus.
A new enumeration with the simpler name SensorType was created in sensors.hpp in a previous commit.
Remove the old enumeration from pmbus_utils. Convert affected files to use the new enumeration.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I4136b392b104edd3eee41ec29c779ad084c7c4de
show more ...
|
#
81a2f90b |
| 23-Mar-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Create error log entries
Create error log entries when the following regulator operations fail: * configuration * presence detection * sensor monitoring * closing I2C devices
Use the re
regulators: Create error log entries
Create error log entries when the following regulator operations fail: * configuration * presence detection * sensor monitoring * closing I2C devices
Use the recently created error_logging_utils namespace to create error logs based on caught exceptions.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I25824ecfdaa270abbce92b52bdea0602271d926d
show more ...
|
#
48033bf6 |
| 27-Jan-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Only configure/monitor if present
Enhance the configure and monitor operations to only be performed if the device is present.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-I
regulators: Only configure/monitor if present
Enhance the configure and monitor operations to only be performed if the device is present.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I57fed4f92937b808ac6f8c37899e28d6009747e6
show more ...
|
#
9bd94d36 |
| 25-Jan-2021 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Clear cached hardware data during boot
Clear cached data about hardware devices when the system is powering on (booting).
While the system was powered off, hardware devices containing v
regulators: Clear cached hardware data during boot
Clear cached data about hardware devices when the system is powering on (booting).
While the system was powered off, hardware devices containing voltage regulators could have been added, removed, or replaced. Cached hardware data might now be invalid.
Tested: * Ran automated test cases * Verified that cached data is cleared without errors during boot * When config file was found and loaded * When no config file was found
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: Ief45fe32ddcb122847d201e89ca1267526a87e3c
show more ...
|
#
a76898f1 |
| 13-Oct-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Enhance config file parser
Enhance JSON config file parser to convert relative inventory paths to absolute form.
Tested: Run local CI with -Dlong-tests=enabled to enable tests for valid
regulators: Enhance config file parser
Enhance JSON config file parser to convert relative inventory paths to absolute form.
Tested: Run local CI with -Dlong-tests=enabled to enable tests for validate-regulators-config.py.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I80237a673f9c5918898db15363847722141388e6
show more ...
|
#
d692d6df |
| 14-Sep-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Modify close() to use services
Modify the Device::close() method in the Device class to have a new first parameter: Services& services.
Modify Device::close() to log messages using the
regulators: Modify close() to use services
Modify the Device::close() method in the Device class to have a new first parameter: Services& services.
Modify Device::close() to log messages using the new Journal interface.
Modify the Chassis::closeDevices() method in the Chassis class to have a new first parameter: Services& services.
Modify Chassis::closeDevices() to log messages using the new Journal interface.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I2a07417d6f7470685f2c27c878ef7936e9f1aa8a
show more ...
|
#
8a55292d |
| 05-Aug-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Modify monitorSensors() to use Services
Modify the monitorSensors() method in the System, Chassis, Device, and Rail classes to have a new first parameter: Services& services.
Modify Sen
regulators: Modify monitorSensors() to use Services
Modify the monitorSensors() method in the System, Chassis, Device, and Rail classes to have a new first parameter: Services& services.
Modify SensorMonitoring::execute() to log messages using the new Journal interface.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I05820cfa94bc3d15dee7a1714a3d253720aa7f92
show more ...
|
#
5cfe5103 |
| 30-Jul-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Modify Configuration to use Journal
Modify Configuration::execute() to log messages using the new Journal interface.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: If7dee12ca
regulators: Modify Configuration to use Journal
Modify Configuration::execute() to log messages using the new Journal interface.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: If7dee12ca064147386fc076223474f004281d7ec
show more ...
|
#
23243f84 |
| 28-Jul-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add Services& services to classes
Modify the configure() method in the System, Chassis, Device, and Rail classes to have a new first parameter: Services& services.
Fix mock_services.hpp
regulators: Add Services& services to classes
Modify the configure() method in the System, Chassis, Device, and Rail classes to have a new first parameter: Services& services.
Fix mock_services.hpp bug.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I6ef41de65d2c5b68c55edb42189ba9c0f2e436ed
show more ...
|
#
8e1cd0b6 |
| 08-Jul-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add monitorSensors support to Device
Implemented the monitorSensors() method in the Device class. This method reads the sensors for the voltage rails produced by the device.
Signed-off
regulators: Add monitorSensors support to Device
Implemented the monitorSensors() method in the Device class. This method reads the sensors for the voltage rails produced by the device.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I5ca48ba8d6ab2019c1840f3905d9603233b1881a
show more ...
|
#
b4d18a45 |
| 02-Jun-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add close method to Device class
Add a close method to the Device class. This will be used to close all devices in the system when monitoring is disabled. Monitoring is disabled when t
regulators: Add close method to Device class
Add a close method to the Device class. This will be used to close all devices in the system when monitoring is disabled. Monitoring is disabled when the system is being powered off.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I0712ad698ebbcac5d7b17a822443b94dda230429
show more ...
|
#
525e20c9 |
| 14-Apr-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add configure support to Chassis class
Implemented the configure() method in the Chassis class. This method configures all the regulator devices within the chassis.
Also made very mino
regulators: Add configure support to Chassis class
Implemented the configure() method in the Chassis class. This method configures all the regulator devices within the chassis.
Also made very minor fixes to two testcases.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: Ib29fdfa36e59f6b79d9467cdc52c3c6fc9c6886d
show more ...
|
#
eb7bec4a |
| 14-Apr-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add configure support to Device class
Implemented the configure() method in the Device class. This method applies any configuration changes that are defined for the device. Also config
regulators: Add configure support to Device class
Implemented the configure() method in the Device class. This method applies any configuration changes that are defined for the device. Also configures all rails within the device.
Also added a missing #include to rail_tests.cpp.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I2faceb7d968b6bb01ee7e1116367afee5864ca28
show more ...
|
#
db0b833c |
| 06-Apr-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Build IDMap for system
The IDMap class is used to map string IDs to the corresponding C++ Device, Rail, and Rule objects.
The IDMap class is complete and tested, but it was not previous
regulators: Build IDMap for system
The IDMap class is used to map string IDs to the corresponding C++ Device, Rail, and Rule objects.
The IDMap class is complete and tested, but it was not previously being populated except in testcases.
Add new methods to the System, Chassis, and Device classes to populate the IDMap with all the ID -> object mappings in the system.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I80f39b663b011ca643c91f7281ff50c956631331
show more ...
|