a5ef5409 | 01-Mar-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add PMBusError/WriteVerificationError
Add the PMBusError and WriteVerificationError exception classes. These classes will be used to implement the pmbus_write_vout_command action in the
regulators: Add PMBusError/WriteVerificationError
Add the PMBusError and WriteVerificationError exception classes. These classes will be used to implement the pmbus_write_vout_command action in the JSON config file.
New exception classes are needed because these errors are handled differently than other exception types, such as internal errors or I2C errors.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I1c3b1d3f3a70060906d7f046af863065a6c436b5
show more ...
|
6663abf3 | 29-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Add PMBus utilities
Create namespace pmbus_utils. This namespace contains utilities for sending PMBus commands over an I2C interface.
These utilities are needed to implement the pmbus_
regulators: Add PMBus utilities
Create namespace pmbus_utils. This namespace contains utilities for sending PMBus commands over an I2C interface.
These utilities are needed to implement the pmbus_write_vout_command and pmbus_read_sensor actions from the JSON config file.
See pmbus_write_vout_command.md and pmbus_read_sensor.md for more information on these actions.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I2fabca3ac8b9cd8b1f2b462c80feef6b6d7d60e8
show more ...
|
d114cd94 | 09-Feb-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add check infinite loops function.
Add check_infinite_loops function. It checks whether infinite loop happened in the config file.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-
regulators: Add check infinite loops function.
Add check_infinite_loops function. It checks whether infinite loop happened in the config file.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I34e7feb6e6200687538c1a68ba7e3cb785055d6e
show more ...
|
5b27a95b | 20-Jan-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add check_duplicate_object_id function.
Add the check_duplicate_object_id function to the config file validation tool. It checks that there aren't any JSON objects with the same 'id' pro
regulators: Add check_duplicate_object_id function.
Add the check_duplicate_object_id function to the config file validation tool. It checks that there aren't any JSON objects with the same 'id' property value.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I1e0d8de50f3687f88509476a5cc81e5577d4c84c
show more ...
|
88d5b698 | 25-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Implement i2c_write_bit action
Implement the i2c_write_bit action in the JSON config file. See i2c_write_bit.md for more information about this action.
Signed-off-by: Shawn McCarney <s
regulators: Implement i2c_write_bit action
Implement the i2c_write_bit action in the JSON config file. See i2c_write_bit.md for more information about this action.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I3e056580da98ab89a13667077cb87cbd063630c9
show more ...
|
83169bfe | 24-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Implement i2c_write_bytes action
Implement the i2c_write_bytes action in the JSON config file. See i2c_write_bytes.md for more information about this action.
Signed-off-by: Shawn McCar
regulators: Implement i2c_write_bytes action
Implement the i2c_write_bytes action in the JSON config file. See i2c_write_bytes.md for more information about this action.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: Ifd4ef481f0a6b74bd3e5689a7b9f3a989ed5e214
show more ...
|
f1c9061c | 24-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Implement i2c_write_byte action
Implement the i2c_write_byte action in the JSON config file. See i2c_write_byte.md for more information about this action.
Signed-off-by: Shawn McCarney
regulators: Implement i2c_write_byte action
Implement the i2c_write_byte action in the JSON config file. See i2c_write_byte.md for more information about this action.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I37fb9b81ee6d9e7fc226787a3242f389b8903714
show more ...
|
2c657004 | 20-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Improve gmock EXPECT_CALL() usage
Improve usage of gmock EXPECT_CALL() to specify the expected input parameter values when useful.
The expected input parameter values to the mocked I2C
regulators: Improve gmock EXPECT_CALL() usage
Improve usage of gmock EXPECT_CALL() to specify the expected input parameter values when useful.
The expected input parameter values to the mocked I2C interface are important as they contain information like the register to read and the number of bytes to read.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: Ifb39910c2edd6c1b3c9533704393f32723892e85
show more ...
|
5ad53945 | 20-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Implement i2c_compare_bytes action
Implement the i2c_compare_bytes action in the JSON config file. See i2c_compare_bytes.md for more information about this action.
Signed-off-by: Shawn
regulators: Implement i2c_compare_bytes action
Implement the i2c_compare_bytes action in the JSON config file. See i2c_compare_bytes.md for more information about this action.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I6997f647a2b899f08f06de43aba62d32f88e1911
show more ...
|
7d3a9f1b | 11-Feb-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Fix 'run_rule' and 'set_device' test cases fail.
Fix test case failures for the 'run_rule' and 'set_device' actions. The failures are caused by new logic in the validator that checks for
regulators: Fix 'run_rule' and 'set_device' test cases fail.
Fix test case failures for the 'run_rule' and 'set_device' actions. The failures are caused by new logic in the validator that checks for invalid rule IDs and device IDs.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I764bd101d0ef635375d13b2921a292799ff1ada9
show more ...
|
63d795f1 | 11-Feb-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Fix 'rule' test cases fail.
Fix test case failures for the 'rule' object. The failures are caused by new logic in the validator that checks for invalid rule IDs.
Signed-off-by: Bob King
regulators: Fix 'rule' test cases fail.
Fix test case failures for the 'rule' object. The failures are caused by new logic in the validator that checks for invalid rule IDs.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I68c80abbd73c94d3ff6b63633e046f9b6bb956b0
show more ...
|
f4ff1168 | 11-Feb-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Fix 'presence_detection' test cases fail.
Fix test case failures for the 'presence_detection' object. The failures are caused by new logic in the validator that checks for invalid rule I
regulators: Fix 'presence_detection' test cases fail.
Fix test case failures for the 'presence_detection' object. The failures are caused by new logic in the validator that checks for invalid rule IDs.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I93e813ee9a7ad64a87075f1ddcb2fb6199e74cda
show more ...
|
2d27dcfe | 11-Feb-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Fix test cases fail for 'if'.
Fix test cases for the 'if' action that are failing due to new logic in the validator tool that checks for invalid rule IDs.
Signed-off-by: Bob King <Bob_K
regulators: Fix test cases fail for 'if'.
Fix test cases for the 'if' action that are failing due to new logic in the validator tool that checks for invalid rule IDs.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: Id857a1fe7cd6b2811df57834ec30f212674fd0b2
show more ...
|
b3e48bca | 17-Feb-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Fix test case failures.
Fix test case failures caused by new validator logic to check for invalid rule IDs.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I6655916fe0c499262d
regulators: Fix test case failures.
Fix test case failures caused by new validator logic to check for invalid rule IDs.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I6655916fe0c499262d7ce40105930fea389f256a
show more ...
|
8215be3f | 19-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Implement i2c_compare_bit action
Implement the i2c_compare_bit action in the JSON config file. See i2c_compare_bit.md for more information about this action.
Signed-off-by: Shawn McCar
regulators: Implement i2c_compare_bit action
Implement the i2c_compare_bit action in the JSON config file. See i2c_compare_bit.md for more information about this action.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: Idb5a2cc9bac3f8b392c0230fbb8bfa0e1b08f3c0
show more ...
|
188db7d8 | 30-Jan-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add test cases for 'i2c_write_bit' and 'i2c_write_byte(s)'.
i2c_write_bit test cases: *Valid: test rule i2c_write_bit. *Invalid: test i2c_write_bit with no register. *Invalid: test i2c_w
regulators: Add test cases for 'i2c_write_bit' and 'i2c_write_byte(s)'.
i2c_write_bit test cases: *Valid: test rule i2c_write_bit. *Invalid: test i2c_write_bit with no register. *Invalid: test i2c_write_bit with no position. *Invalid: test i2c_write_bit with no value. *Invalid: test i2c_write_bit with register wrong type. *Invalid: test i2c_write_bit with register wrong format. *Invalid: test i2c_write_bit with position wrong type. *Invalid: test i2c_write_bit with position greater than 7. *Invalid: test i2c_write_bit with position less than 0. *Invalid: test i2c_write_bit with value wrong type. *Invalid: test i2c_write_bit with value greater than 1. *Invalid: test i2c_write_bit with value less than 0. i2c_write_byte test cases: *Valid: test i2c_write_byte with all properties *Valid: test i2c_write_byte with all required properties *Invalid: test i2c_write_byte with no register *Invalid: test i2c_write_byte with no value *Invalid: test i2c_write_byte with property register wrong type *Invalid: test i2c_write_byte with property value wrong type *Invalid: test i2c_write_byte with property mask wrong type *Invalid: test i2c_write_byte with property register more than 2 hex digits. *Invalid: test i2c_write_byte with property value more than 2 hex digits. *Invalid: test i2c_write_byte with property mask more than 2 hex digits. *Invalid: test i2c_write_byte with property register less than 2 hex digits. *Invalid: test i2c_write_byte with property value less than 2 hex digits. *Invalid: test i2c_write_byte with property mask less than 2 hex digits. *Invalid: test i2c_write_byte with property register no leading prefix. *Invalid: test i2c_write_byte with property value no leading prefix. *Invalid: test i2c_write_byte with property mask no leading prefix. *Invalid: test i2c_write_byte with property register invalid hex digit. *Invalid: test i2c_write_byte with property value invalid hex digit. *Invalid: test i2c_write_byte with property mask invalid hex digit. i2c_write_bytes test cases: *Valid: test i2c_write_bytes *Valid: test i2c_write_bytes with all required properties *Invalid: test i2c_write_bytes with no register *Invalid: test i2c_write_bytes with no values *Invalid: test i2c_write_bytes with property values as empty array *Invalid: test i2c_write_bytes with property masks as empty array *Invalid: test i2c_write_bytes with property register wrong type *Invalid: test i2c_write_bytes with property values wrong type *Invalid: test i2c_write_bytes with property masks wrong type *Invalid: test i2c_write_bytes with property register more than 2 hex digits. *Invalid: test i2c_write_bytes with property value more than 2 hex digits. *Invalid: test i2c_write_bytes with property mask more than 2 hex digits. *Invalid: test i2c_write_bytes with property register less than 2 hex digits. *Invalid: test i2c_write_bytes with property value less than 2 hex digits. *Invalid: test i2c_write_bytes with property mask less than 2 hex digits. *Invalid: test i2c_write_bytes with property register no leading prefix. *Invalid: test i2c_write_bytes with property value no leading prefix. *Invalid: test i2c_write_bytes with property mask no leading prefix. *Invalid: test i2c_write_bytes with property register invalid hex digit. *Invalid: test i2c_write_bytes with property value invalid hex digit. *Invalid: test i2c_write_bytes with property mask invalid hex digit.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I7d9593605985ad466f6e32df7cbf23d6e513f991
show more ...
|
64df7daa | 30-Jan-2020 |
Bob King <Bob_King@wistron.com> |
regulators: change the test cases sorting.
Put the validator test cases in alphabetical order.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: If2d5a2f3b202e2ada33b0fcf4d74585627c7865d |
3643cc06 | 30-Jan-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add test cases for check duplicates and infinite loop.
*Invalid: test duplicate ID in rule. *Invalid: test duplicate number in chassis. *Invalid: test duplicate ID in device. *Invalid: t
regulators: Add test cases for check duplicates and infinite loop.
*Invalid: test duplicate ID in rule. *Invalid: test duplicate number in chassis. *Invalid: test duplicate ID in device. *Invalid: test duplicate ID in rail. *Invalid: test run_rule with infinite loop (rule runs itself). *Invalid: test run_rule with infinite loop (rules run each other). *Invalid: test run_rule with infinite loop (indirect loop).
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I06a5d68d1bbb2214a9fba63920b4527a1aa3df84
show more ...
|
fcc2a2fb | 30-Jan-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add test cases for object 'sensor_monitoring'.
*Valid: test sensor_monitoring with only property rule id. *Valid: test sensor_monitoring with only property actions. *Invalid: test sensor
regulators: Add test cases for object 'sensor_monitoring'.
*Valid: test sensor_monitoring with only property rule id. *Valid: test sensor_monitoring with only property actions. *Invalid: test sensor_monitoring with both property rule_id and actions. *Invalid: test sensor_monitoring with no rule_id and actions. *Invalid: test sensor_monitoring with property comments wrong type. *Invalid: test sensor_monitoring with property rule_id wrong type. *Invalid: test sensor_monitoring with property actions wrong type. *Invalid: test sensor_monitoring with property rule_id wrong format. *Invalid: test sensor_monitoring with property comments empty array. *Invalid: test sensor_monitoring with property actions empty array.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I8892dbdfe3546dd983b2c7d7478c287f79e98cc9
show more ...
|
e9260b57 | 20-Jan-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add test cases for object 'rail'.
*Valid: test rail. *Valid: test rail with required properties. *Invalid: test rail with no id. *Invalid: test rail with comments wrong type. *Invalid: t
regulators: Add test cases for object 'rail'.
*Valid: test rail. *Valid: test rail with required properties. *Invalid: test rail with no id. *Invalid: test rail with comments wrong type. *Invalid: test rail with id wrong type. *Invalid: test rail with configuration wrong type. *Invalid: test rail with sensor_monitoring wrong type. *Invalid: test rail with comments empty array. *Invalid: test rail with id wrong format.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I1302426c1ccddbd4437f0ed6eb5c4b3a857ffe6b
show more ...
|
4c67a3a0 | 06-Feb-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add test cases for object 'configuration'.
*Valid: test configuration with property rule_id and with no actions. *Valid: test configuration with property actions and with no rule_id. *Va
regulators: Add test cases for object 'configuration'.
*Valid: test configuration with property rule_id and with no actions. *Valid: test configuration with property actions and with no rule_id. *Valid: comments not specified (optional property). *Valid: volts not specified (optional property). *Valid: configuration is property of a rail (vs. a device). *Invalid: comments property has wrong data type (not an array). *Invalid: test configuration with both property actions rule_id. *Invalid: test configuration with no rule_id and actions. *Invalid: test configuration with property volts wrong type. *Invalid: test configuration with property rule_id wrong type. *Invalid: test configuration with property actions wrong type. *Invalid: test configuration with property comments empty array. *Invalid: test configuration with property rule_id wrong format. *Invalid: test configuration with property actions empty array.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I9b1617c8eb1ac49c28089b4d0d85ae2bd55db80d
show more ...
|
99d8fa1a | 30-Jan-2020 |
Bob King <Bob_King@wistron.com> |
regulators: Add test cases for object 'presence_detection'.
*Valid: test presence_detection with only property rule_id. *Valid: test presence_detection with only property actions. *Invalid: test pre
regulators: Add test cases for object 'presence_detection'.
*Valid: test presence_detection with only property rule_id. *Valid: test presence_detection with only property actions. *Invalid: test presence_detection with both property rule_id and actions. *Invalid: test presence_detection with no rule_id and actions. *Invalid: test presence_detection with property comments wrong type. *Invalid: test presence_detection with property rule_id wrong type. *Invalid: test presence_detection with property actions wrong type. *Invalid: test presence_detection with property rule_id wrong format. *Invalid: test presence_detection with property comments empty array. *Invalid: test presence_detection with property actions empty array.
Signed-off-by: Bob King <Bob_King@wistron.com> Change-Id: I37bf69281cfe98c4d87852554c744763baffa5b7
show more ...
|
b38da99f | 13-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Implement i2c_compare_byte action
Implement the i2c_compare_byte action in the JSON config file. See i2c_compare_byte.md for more information about this action.
Signed-off-by: Shawn Mc
regulators: Implement i2c_compare_byte action
Implement the i2c_compare_byte action in the JSON config file. See i2c_compare_byte.md for more information about this action.
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com> Change-Id: I258027f969684022f6fd5d85ab4dc32b4746a69c
show more ...
|
dc8e9312 | 14-Feb-2020 |
Brandon Wyman <bjwyman@gmail.com> |
Add OE-SDK option to Meson
Add option to enable oe-sdk which will setup linker arguments to allow for building and running tests with the x86 SDK.
Signed-off-by: Brandon Wyman <bjwyman@gmail.com> C
Add OE-SDK option to Meson
Add option to enable oe-sdk which will setup linker arguments to allow for building and running tests with the x86 SDK.
Signed-off-by: Brandon Wyman <bjwyman@gmail.com> Change-Id: I8279b7d862e29235d2d4eae39405cc35a51b762f
show more ...
|
8f0d1428 | 02-Feb-2020 |
Shawn McCarney <shawnmm@us.ibm.com> |
regulators: Create ActionError class
Create the ActionError exception class. This exception describes an error that occurred while executing an action, such as i2c_write_byte.
Change-Id: Ie11b5966
regulators: Create ActionError class
Create the ActionError exception class. This exception describes an error that occurred while executing an action, such as i2c_write_byte.
Change-Id: Ie11b59663ba51da74967454d6ca6ad8856ddd189 Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>
show more ...
|