History log of /openbmc/phosphor-power/tools/ (Results 1 – 25 of 41)
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
f0c0c47b07-Dec-2024 Jayanth Othayoth <ojayanth@gmail.com>

clang-tidy: Suppress unused variable warnings

The following errors were reported during clang-tidy enablement due to
multiple unused variables. This temporary fix suppresses the warnings
using a pra

clang-tidy: Suppress unused variable warnings

The following errors were reported during clang-tidy enablement due to
multiple unused variables. This temporary fix suppresses the warnings
using a pragma approach until a permanent solution is
implemented.

Changes:
- Commented out unused variables to suppress the -Wunused-variable
warnings.

'''
../tools/power-utils/aei_updater.cpp:36:15: error: unused variable 'MEM_STRETCH_DELAY' [-Werror
../tools/power-utils/aei_updater.cpp:40:19: error: unused variable 'I2C_SMBUS_BLOCK_MAX' [-Werror
../tools/power-utils/aei_updater.cpp:41:19: error: unused variable 'FW_READ_BLOCK_SIZE' [-Werror
../tools/power-utils/aei_updater.cpp:43:19: error: unused variable 'READ_SEQ_ST_CML_SIZE' [-Werror
../tools/power-utils/aei_updater.cpp:45:19: error: unused variable 'START_SEQUENCE_INDEX' [-Werror
../tools/power-utils/aei_updater.cpp:46:19: error: unused variable 'STATUS_CML_INDEX' [-Werror
../tools/power-utils/aei_updater.cpp:63:19: error: unused variable 'B_CHKSUM_ERR' [-Werror
../tools/power-utils/aei_updater.cpp:64:19: error: unused variable 'B_CHKSUM_SUCCESS' [-Werror
../tools/power-utils/aei_updater.cpp:66:19: error: unused variable 'B_MEM_ERR' [-Werror
../tools/power-utils/aei_updater.cpp:67:19: error: unused variable 'B_ALIGN_ERR' [-Werror
../tools/power-utils/aei_updater.cpp:68:19: error: unused variable 'B_KEY_ERR' [-Werror
../tools/power-utils/aei_updater.cpp:69:19: error: unused variable 'B_START_ERR' [-Werror
../tools/power-utils/aei_updater.cpp:70:19: error: unused variable 'B_IMG_MISSMATCH_ERR' [-Werror
../tools/power-utils/aei_updater.cpp:73:19: error: unused variable 'B_ISP_MODE_CHKSUM_GOOD' [-Werror
../tools/power-utils/aei_updater.cpp:74:19: error: unused variable 'B_PRGM_BUSY' [-Werror
../tools/power-utils/aei_updater.cpp:35:15: error: unused variable 'MEM_WRITE_DELAY' [-Werror
'''

Tested: Build and unit testing verified.

Change-Id: Idbe50bfc465f12f0cf4fd7e382a6f04879f08dba
Signed-off-by: Jayanth Othayoth <ojayanth@gmail.com>

show more ...

12c4a42006-Dec-2024 Jayanth Othayoth <ojayanth@gmail.com>

clang-tidy: Fix override errors

The following errors were reported during the clang-tidy enablement
build due to overridden functions not being marked with the override
keyword. The proposed fix is

clang-tidy: Fix override errors

The following errors were reported during the clang-tidy enablement
build due to overridden functions not being marked with the override
keyword. The proposed fix is to add the override keyword where it
was missing.

'''
1m../tools/i2c/i2c.hpp:176:10:
error: 'open' overrides a member function but is not marked 'override' [-Werror
1m../tools/i2c/i2c.hpp:179:10:
error: 'isOpen' overrides a member function but is not marked 'override' [-Werror
1m../tools/i2c/i2c.hpp:185:10:
error: 'close' overrides a member function but is not marked 'override' [-Werror
'''

Tested: Verified Build and unit testing.

Change-Id: Iad01481761c6a4339e051c183c3dd238baf19d70
Signed-off-by: Jayanth Othayoth <ojayanth@gmail.com>

show more ...

8dca507523-Nov-2024 Faisal Awada <faisal@us.ibm.com>

psutils: Add new functions to AEI Updater class

The following functions handle the critical stages of firmware update,
including validation, reading, preparation, and reboot verification.
Error han

psutils: Add new functions to AEI Updater class

The following functions handle the critical stages of firmware update,
including validation, reading, preparation, and reboot verification.
Error handling and logging are incorporated to isolate issues during the
update.

getFirmwarePath()
Retrieves the firmware file path from the image directory. Uses
getFWFilenamePath to fetch the path. Logs an error if the firmware path
is not found and returns an empty string otherwise returns firmware
path.

isFirmwareFileValid()
Validates the firmware file at the given path using validateFWFile.
Ensure the firmware file exists and meets requirements before proceeding
with the update. Logs an error if validation fails.

openFirmwareFile()
Opens the firmware file at the specified path for reading in binary
mode. Logs an error if the file cannot be opened.

readFirmwareBlock()
Reads a block of data from the firmware file.Uses readFirmwareBytes to
read the specified number of bytes.

prepareCommandBlock()
Prepares a command block for writing firmware data to the PSU. Adds
metadata, data, and a CRC8 checksum. Packages firmware data in a format
suitable for I2C transmission.

ispReboot()
Sends a reboot command to the status register to apply new firmware.

ispReadRebootStatus()
Reads the reboot status from ISP, returns true for success otherwise
false.

Tested:
- Validated that the firmware path retrieves the correct file.
- A validation error is logged when the file is empty or path is
incorrect.
- Removed read permission on the firmware file and verified that an
error was logged.
- Verify the block of data read as specified in the specification.
- Printed the command block and verified that the command and data are
ready to be sent to the PSU via I2C.
- Downloaded the firmware and verified that the command block, ISP
reboot and reboot status are working as expected.

Change-Id: I097b4aeefc0967d5591b8fb6aefb3c600c9f77f8
Signed-off-by: Faisal Awada <faisal@us.ibm.com>

show more ...

5a582d3c15-Nov-2024 Faisal Awada <faisal@us.ibm.com>

psutils: Partial AEI Updater class

The AeiUpdater class within the aeiUpdater namespace, responsible for
updating AEI PSU firmware via I2C communication. The code focuses on
executing various stage

psutils: Partial AEI Updater class

The AeiUpdater class within the aeiUpdater namespace, responsible for
updating AEI PSU firmware via I2C communication. The code focuses on
executing various stages of the firmware update process, ensuring each
step performed and validated correctly. The following partial functions
of the key component of the class:

doUpdate()
This method initiates the firmware update process. It checks and sets
the ISP (In-System Programming) mode using writeIspKey(),
writeIspMode(), and writeIspStatusReset().

writeIspKey()
Unlocks the ISP by writing a specific key to the KEY_REGISTER. Handles
exceptions for any I2C communication errors and logs the failure.

writeIspMode()
Sends a command to enter ISP mode and checks the status register.
Retries on failure, with a maximum retry limit. Checks the status
register to confirm the mode has been set. Logs any I2C errors
encountered.

writeIspStatusReset()
Resets ISP status register, clearing any existing status flags. Verifies
the reset by reading the status register, retrying as needed. Logs any
I2C errors encountered.

Test:
Tested the function listed in the class on a system with AEI PSU:

- Validated the PSU ISP key was accepted and no error logged.
- Validated an error was logged when I used wrong key.
- Validated the PSU entered to ISP mode by reading back status register
and confirmed the bit is set.
- Validated the PSU status reset by reading the back status register and
confirmed the bit is set.

Change-Id: I1e8e594f088e7d66d8fc5b1723c4bd33b08bd3f8
Signed-off-by: Faisal Awada <faisal@us.ibm.com>

show more ...

23dee38311-Nov-2024 Shawn McCarney <shawnmm@us.ibm.com>

psutils: Move functions from updater to utils

Move common, utility functions from updater.*pp to utils.*pp. This will
enable those functions to be used by other command line options in the
psutils

psutils: Move functions from updater to utils

Move common, utility functions from updater.*pp to utils.*pp. This will
enable those functions to be used by other command line options in the
psutils tool.

Modify --get-version and --get-model to use the new utility functions.

Also update --get-version to provide a single getVersion() function that
handles the existence of the psu.json file as a low-level implementation
detail.

Tested:
* Verified all automated tests run successfully
* Verified --get-version still works
* With psu.json file
* Without psu.json file
* Verified --get-model still works
* With psu.json file
* Without psu.json file
* Verified --update still gets correct device path, device name, and I2C
bus/address from functions that moved to utils.*pp
* The complete test plan is available at
https://gist.github.com/smccarney/c049e24655d32e22cab9d521d145774a

Change-Id: I51ceca10957dc9a924d0d7516dc29632a6ed82d3
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>

show more ...

0fbc2f6a05-Nov-2024 Shawn McCarney <shawnmm@us.ibm.com>

psutils: Add --get-model option

Add a --get-model command line option to the psutils tool. This option
obtains the PSU model using information in sysfs.

Supports both methods of obtaining informat

psutils: Add --get-model option

Add a --get-model command line option to the psutils tool. This option
obtains the PSU model using information in sysfs.

Supports both methods of obtaining information about a PSU:
* psu.json file
* D-Bus

Tested:
* Verified --get-version still works
* With psu.json file
* Without psu.json file
* Verified new --get-model property works
* With psu.json file
* Without psu.json file
* Tested all error paths
* See the following gist for the complete test plan:
https://gist.github.com/smccarney/859ffaaa94ce12992af1b24e6c899962

Change-Id: If1be01f4b70ad9d80ce01402c57730990fd2c2ea
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>

show more ...

14572cf406-Nov-2024 Shawn McCarney <shawnmm@us.ibm.com>

psutils: Move utility functions to utils.*pp

The files named version.hpp and version.cpp implement the --get-version
option of the psutils tool.

However, the files also contain some utility functio

psutils: Move utility functions to utils.*pp

The files named version.hpp and version.cpp implement the --get-version
option of the psutils tool.

However, the files also contain some utility functions that would be
helpful for implementing other command line options, such as --update or
the planned new option --get-model.

Move the utility functions into new files named utils.hpp and utils.cpp.
The functions will be defined within a namespace named 'utils'.

Tested:
* Verified automated testcases ran successfully
* Verified --get-version option worked correctly
* When using a psu.json file
* When using D-Bus information

Change-Id: If902ee4581fce000af37073ac2e7a7b0ade01f78
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>

show more ...

ec61bbd704-Nov-2024 Faisal Awada <faisal@us.ibm.com>

Utility functions for download firmware

Added set of utility functions to be used within the classes for
managing the PSU firmware updates. Here is a breakdown of the key
functions:

- getDevicePath

Utility functions for download firmware

Added set of utility functions to be used within the classes for
managing the PSU firmware updates. Here is a breakdown of the key
functions:

- getDevicePath():
Construct the PSU device path using I2C bus and address.

- getClassInstance():
Determines the appropriate updater class to use based on PSU model
number.

- getFWFilenamePath():
Searches a directory for a firmware file matching a specified prefix
and file extension (.bin or .hex).

- calculateCRC8():
Computes the CRC-8 checksum for transferred data.

- delay():
Pauses execution for a specified number of milliseconds.

- bigEndianToLittleEndian():
Converts a 32-bit value from big-endian to little-endian.

- validateFWFile():
Checks if a firmware file exists and is non-empty.

- openFirmwareFile():
Opens a firmware file in binary mode, returning a file stream if
successful.

- readFirmwareBytes():
Reads specified number of data bytes from a firmware file into a
buffer. Return data read or null to the caller.

- usePsuJsonFile():
Wrapper to check the existence of the PSU JSON file.

- Class accessors to private data:
getPsuInventoryPath(): Accessor for PSU inventory path.
getDevPath(): Accessor for device path.
getDevName(): Accessor for device name.
getImageDir(): Accessor for image directory.
getI2C(): I2C interface accessor.

Tested every function manually:

- getDevicePath() (using busctl):
- Validate I2C bus and address values through psuInventoryPath
validate expected result
- Modified psuInventoryPath to invalid path
validate returned invalid path.

- getClassInstance():
- Validate with matching model number the function instantiate
appropriate class.
- Validate the default class instantiated.

- getFWFilenamePath():
- Validate return of the correct file name in the PSU FW directory
- Validate null returns when FW files don't exist

- calculaterCRC8():
- Validate single byte 0x0 result 0x0, single byte 0x01 result 0x07

- delay():
- Verified the task suspend execution.

- bigEndianToLittleEndian():
- Verified input 0x12345678 resulted in 0x78563412

- validateFWFile():
- Validate the existence of the file otherwise an error is logged
- Validate the file size is greater than 0 otherwise an error is
logged.

- openFirmwareFile():
- Validate ifstream object is returned and was able to read from.
- Validate error logged if the file name is null
- validate error logged when unable to open the file

- readFirmwareBytes():
- Validate data read from FW file
- Validate number of bytes read.

- usePsuJsonFile():
- Added JSON file to simulator and validated true return.

Change-Id: I0b8b24ae7d37724dab608d2c4977c1b42d4e1632
Signed-off-by: Faisal Awada <faisal@us.ibm.com>

show more ...

37c2612b24-Oct-2024 Shawn McCarney <shawnmm@us.ibm.com>

psutils: Do not pad PSU version with blanks

When `psutils --get-version <inventory_path>` is run, it returns the
firmware version for the specified PSU inventory path.

If no psu.json file is found,

psutils: Do not pad PSU version with blanks

When `psutils --get-version <inventory_path>` is run, it returns the
firmware version for the specified PSU inventory path.

If no psu.json file is found, the PSU I2C bus and address are obtained
from D-Bus. The PSU version is then obtained from a file in sysfs.

The contents of the sysfs file are currently treated as VPD. Invalid
characters are replaced with spaces, and the value is padded with spaces
if needed to reach an expected VPD length.

If an error occurs trying to read the sysfs file, the version is
initially set to "". However, since it is being treated as VPD it is
later padded with blanks. Since the version is not an empty string, it
is treated as valid by psutils and the PSU code update application.
This causes subsequent code update issues.

Modify psutils so that the contents of the sysfs file are treated as a
simple string. If an error occurs, set the version to "". This will
cause psutils and the PSU code update application to correctly conclude
that an error occurred and the version is not valid.

Tested:
* psutils --get-version
* psu.json file exists
* Test where getting the version works
* Verify file contents are obtained
* Verify psutils prints out the version
* Verify psutils exits with a return code of 0
* Test where getting the version fails
* Verify exception is written to the journal
* Verify psutils prints out an empty string
* Verify psutils exits with a return code of 1
* psu.json file does not exist; PSU information is obtained from D-Bus
* Test where getting the version works
* Verify file contents are obtained
* Verify psutils prints out the version
* Verify psutils exits with a return code of 0
* Test where getting the version fails
* Verify exception is written to the journal
* Verify psutils prints out an empty string
* Verify psutils exits with a return code of 1

Change-Id: I131ba1b73f5ee96606bcfe86943da258196eca62
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>

show more ...

a3ff7e7115-Oct-2024 Shawn McCarney <shawnmm@us.ibm.com>

I2CInterface: Add process call methods

Add C++ methods to perform the following SMBus commands:
* Process Call
* Block Write-Block Read Process Call

For Block Write-Block Read Process Call, impleme

I2CInterface: Add process call methods

Add C++ methods to perform the following SMBus commands:
* Process Call
* Block Write-Block Read Process Call

For Block Write-Block Read Process Call, implement support for writes up
to 255 bytes. SMBus 2.0 supported a maximum of 32 bytes, and SMBus 3.0
supports a maximum of 255 bytes. The current Linux SMBus function only
supports 32 byte writes. Provide an alternate implementation using the
lower level I2C_RDWR ioctl() to support up to 255 bytes.

Tested:
* Verified Process Call worked correctly
* Verified Block Write-Block Read Process Call worked correctly
* When using SMBus function
* When using I2C_RDWR ioctl()
* Tested error cases
* See complete test plan at
https://gist.github.com/smccarney/96eda4c7c11fe4f89e4491c768f76047

Change-Id: Icc1ba840741b1e26a50fe32bad8b2181a01dbb24
Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>

show more ...

5dce1a7419-Aug-2024 Faisal Awada <faisal@us.ibm.com>

power-utils: Retrieve Firmware Version from sysfs

Added support to retrieve firmware version from sysfs. This required the
following code additions and modifications:

1 - Locate the target PSU obje

power-utils: Retrieve Firmware Version from sysfs

Added support to retrieve firmware version from sysfs. This required the
following code additions and modifications:

1 - Locate the target PSU object and retrieve 'i2cBus' and 'i2cAddress'.
2 - Obtain PMBus interface access.
3 - Read the firmware version from sysfs.

Tested:
The new code was loaded onto a system, and the firmware version was
successfully read from sysfs. Verified getVersion using psu.json file
did not change.

Change-Id: I791788f45e4d682578efbed33e3832a833644dad
Signed-off-by: Faisal Awada <faisal@us.ibm.com>

show more ...

f540219716-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 ...


/openbmc/phosphor-power/.clang-format
/openbmc/phosphor-power/.gitignore
/openbmc/phosphor-power/OWNERS
/openbmc/phosphor-power/README.md
/openbmc/phosphor-power/cold-redundancy/cold_redundancy.cpp
/openbmc/phosphor-power/compatible_system_types_finder.cpp
/openbmc/phosphor-power/compatible_system_types_finder.hpp
/openbmc/phosphor-power/dbus_interfaces_finder.cpp
/openbmc/phosphor-power/dbus_interfaces_finder.hpp
/openbmc/phosphor-power/elog-errors.hpp
/openbmc/phosphor-power/format_utils.hpp
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/README.md
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/BlueRidge.json
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/Bonnell.json
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/Everest.json
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/Fuji.json
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/Rainier.json
/openbmc/phosphor-power/phosphor-power-sequencer/docs/README.md
/openbmc/phosphor-power/phosphor-power-sequencer/docs/config_file/README.md
/openbmc/phosphor-power/phosphor-power-sequencer/docs/config_file/config_file.md
/openbmc/phosphor-power/phosphor-power-sequencer/docs/config_file/gpio.md
/openbmc/phosphor-power/phosphor-power-sequencer/docs/config_file/rail.md
/openbmc/phosphor-power/phosphor-power-sequencer/docs/testing.md
/openbmc/phosphor-power/phosphor-power-sequencer/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/config_file_parser.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/config_file_parser.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/config_file_parser_error.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/device_finder.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/device_finder.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/pmbus_driver_device.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/pmbus_driver_device.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_interface.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_interface.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_sequencer_device.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/rail.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/rail.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/services.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/services.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/standard_device.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/standard_device.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90160_device.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90160_device.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90320_device.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90320_device.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90x_device.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90x_device.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/config_file_parser_error_tests.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/config_file_parser_tests.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/test/mock_device.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/mock_pmbus.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/mock_services.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/pmbus_driver_device_tests.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/rail_tests.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/standard_device_tests.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/ucd90160_device_tests.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/ucd90320_device_tests.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/test/ucd90x_device_tests.cpp
/openbmc/phosphor-power/phosphor-power-supply/README.md
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/test/mock.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/power_supply_tests.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.hpp
/openbmc/phosphor-power/phosphor-power-supply/util_base.hpp
/openbmc/phosphor-power/phosphor-regulators/README.md
/openbmc/phosphor-power/phosphor-regulators/config_files/BlueRidge.json
/openbmc/phosphor-power/phosphor-regulators/config_files/Bonnell.json
/openbmc/phosphor-power/phosphor-regulators/config_files/Everest.json
/openbmc/phosphor-power/phosphor-regulators/config_files/Fuji.json
/openbmc/phosphor-power/phosphor-regulators/config_files/Rainier.json
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/README.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/action.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/and.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/chassis.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_presence.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_vpd.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/config_file.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/configuration.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/device.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_capture_bytes.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_compare_bit.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_compare_byte.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_compare_bytes.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_interface.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_write_bit.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_write_byte.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_write_bytes.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/if.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/log_phase_fault.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/not.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/or.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/phase_fault_detection.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/pmbus_read_sensor.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/pmbus_write_vout_command.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/presence_detection.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/rail.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/rule.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/run_rule.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/sensor_monitoring.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/set_device.md
/openbmc/phosphor-power/phosphor-regulators/src/actions/action_environment.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/compare_vpd_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_byte_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_bytes_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_byte_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_bytes_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_read_sensor_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_read_sensor_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_write_vout_command_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_write_vout_command_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/chassis.cpp
/openbmc/phosphor-power/phosphor-regulators/src/chassis.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.cpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.hpp
/openbmc/phosphor-power/phosphor-regulators/src/configuration.hpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensor.cpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensor.hpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensors.cpp
/openbmc/phosphor-power/phosphor-regulators/src/device.hpp
/openbmc/phosphor-power/phosphor-regulators/src/ffdc_file.cpp
/openbmc/phosphor-power/phosphor-regulators/src/ffdc_file.hpp
/openbmc/phosphor-power/phosphor-regulators/src/id_map.cpp
/openbmc/phosphor-power/phosphor-regulators/src/id_map.hpp
/openbmc/phosphor-power/phosphor-regulators/src/journal.cpp
/openbmc/phosphor-power/phosphor-regulators/src/journal.hpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.hpp
/openbmc/phosphor-power/phosphor-regulators/src/meson.build
/openbmc/phosphor-power/phosphor-regulators/src/phase_fault_detection.cpp
/openbmc/phosphor-power/phosphor-regulators/src/phase_fault_detection.hpp
/openbmc/phosphor-power/phosphor-regulators/src/pmbus_error.hpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_detection.cpp
/openbmc/phosphor-power/phosphor-regulators/src/rail.hpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/main.cpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/utility.hpp
/openbmc/phosphor-power/phosphor-regulators/src/rule.hpp
/openbmc/phosphor-power/phosphor-regulators/src/system.hpp
/openbmc/phosphor-power/phosphor-regulators/src/write_verification_error.hpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/compare_vpd_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_compare_bit_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/set_device_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/chassis_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/config_file_parser_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/id_map_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/phase_fault_detection_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/system_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/test_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/pmbus.cpp
/openbmc/phosphor-power/pmbus.hpp
/openbmc/phosphor-power/power-sequencer/pgood_monitor.hpp
/openbmc/phosphor-power/power-sequencer/runtime_monitor.hpp
/openbmc/phosphor-power/power-supply/main.cpp
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/subprojects/boost.wrap
/openbmc/phosphor-power/subprojects/nlohmann_json.wrap
/openbmc/phosphor-power/subprojects/packagefiles/boost/meson.build
/openbmc/phosphor-power/temporary_file.cpp
/openbmc/phosphor-power/temporary_file.hpp
/openbmc/phosphor-power/temporary_subdirectory.cpp
/openbmc/phosphor-power/temporary_subdirectory.hpp
/openbmc/phosphor-power/test/format_utils_tests.cpp
/openbmc/phosphor-power/test/meson.build
/openbmc/phosphor-power/test/temporary_file_tests.cpp
/openbmc/phosphor-power/test/temporary_subdirectory_tests.cpp
i2c/i2c.cpp
i2c/i2c.hpp
i2c/i2c_interface.hpp
power-utils/updater.cpp
power-utils/version.cpp
/openbmc/phosphor-power/utility.cpp
/openbmc/phosphor-power/utility.hpp
5c6a693e29-Nov-2023 Patrick Williams <patrick@stwcx.xyz>

build: use allowed over enabled

Meson feature options are typically in a tri-state of enabled, disabled,
or auto. The enabled and disabled functions on an option (from
`get_option`) no longer retur

build: use allowed over enabled

Meson feature options are typically in a tri-state of enabled, disabled,
or auto. The enabled and disabled functions on an option (from
`get_option`) no longer return true for auto features. Instead, the
expectation is to use `allowed()` which is true for both enabled and auto.

Switch all uses of `enabled` to `allowed`.

Change-Id: I37fcb391dcb215a86a60c26f7512f6ccb8312dc4
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


/openbmc/phosphor-power/.clang-format
/openbmc/phosphor-power/README.md
/openbmc/phosphor-power/cold-redundancy/cold_redundancy.cpp
/openbmc/phosphor-power/elog-errors.hpp
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/meson.options
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/UCD90160Monitor_ibm,bonnell.json
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/meson.build
/openbmc/phosphor-power/phosphor-power-supply/test/mock.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/power_supply_tests.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.hpp
/openbmc/phosphor-power/phosphor-power-supply/util_base.hpp
/openbmc/phosphor-power/phosphor-regulators/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/meson.build
/openbmc/phosphor-power/power-sequencer/main.cpp
/openbmc/phosphor-power/power-sequencer/meson.build
/openbmc/phosphor-power/power-supply/main.cpp
/openbmc/phosphor-power/power-supply/meson.build
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/power-supply/test/meson.build
/openbmc/phosphor-power/subprojects/googletest.wrap
/openbmc/phosphor-power/subprojects/nlohmann-json.wrap
/openbmc/phosphor-power/test/meson.build
i2c/meson.build
i2c/test/meson.build
power-utils/meson.build
power-utils/test/meson.build
c0b9e9e417-Jul-2023 Matt Spinler <spinler@us.ibm.com>

Fix standalone build fail in utils/version.cpp

Either the new compiler, C++ version, or nlohmann version starting
giving an error when building with subprojects:

```
../tools/power-utils/version.cp

Fix standalone build fail in utils/version.cpp

Either the new compiler, C++ version, or nlohmann version starting
giving an error when building with subprojects:

```
../tools/power-utils/version.cpp: In function ‘PsuVersionInfo utils::getVersionInfo(const std::string&)’:
../tools/power-utils/version.cpp:67:40: error: ambiguous overload for ‘operator=’ (operand types are ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’}
and ‘const nlohmann::basic_json<>::value_type’ {aka ‘const nlohmann::basic_json<>’})
67 | versionStr = fru["fileName"];
```

Change-Id: Ic0de80331a04110a279702b30bd7cf55ec8c083c
Signed-off-by: Matt Spinler <spinler@us.ibm.com>

show more ...

888bebde31-May-2023 Patrick Williams <patrick@stwcx.xyz>

meson: add necessary subprojects

Add subprojects for all the direct dependencies of the project such
that the project can be built outside of a Yocto SDK on a typical
Linux development system.

-

meson: add necessary subprojects

Add subprojects for all the direct dependencies of the project such
that the project can be built outside of a Yocto SDK on a typical
Linux development system.

- Update the .gitignore to ignore the subproject source directories.
- Update the .gitignore to ignore alternative build subdirectory
names as is typical with most projects in the openbmc organization.
- Add wrap files for direct dependencies, copied from other
repositories that already have the same dependencies.
- Modify the meson.build dependency for libgpiod so that the C++
bindings are included.
- Add many missing dependencies throughout.
- Sort all dependencies alphabetically for consistency.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I0feb6f0f175e6dba0b00a2c2b666eb0801575734

show more ...


/openbmc/phosphor-power/.gitignore
/openbmc/phosphor-power/OWNERS
/openbmc/phosphor-power/cold-redundancy/meson.build
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/names_values.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/meson.build
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/meson.build
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.hpp
/openbmc/phosphor-power/phosphor-regulators/src/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/temporary_file_tests.cpp
/openbmc/phosphor-power/power-sequencer/meson.build
/openbmc/phosphor-power/power-supply/meson.build
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/services/phosphor-regulators-config.service
/openbmc/phosphor-power/services/phosphor-regulators-monitor-disable.service
/openbmc/phosphor-power/services/phosphor-regulators-monitor-enable.service
/openbmc/phosphor-power/subprojects/CLI11.wrap
/openbmc/phosphor-power/subprojects/fmt.wrap
/openbmc/phosphor-power/subprojects/libgpiod.wrap
/openbmc/phosphor-power/subprojects/nlohmann-json.wrap
/openbmc/phosphor-power/subprojects/phosphor-dbus-interfaces.wrap
/openbmc/phosphor-power/subprojects/phosphor-logging.wrap
/openbmc/phosphor-power/subprojects/sdbusplus.wrap
/openbmc/phosphor-power/subprojects/sdeventplus.wrap
/openbmc/phosphor-power/subprojects/stdplus.wrap
/openbmc/phosphor-power/test/file_descriptor_tests.cpp
power-utils/meson.build
power-utils/test/meson.build
48781aef10-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 ...


/openbmc/phosphor-power/.clang-format
/openbmc/phosphor-power/cold-redundancy/cold_redundancy.cpp
/openbmc/phosphor-power/device.hpp
/openbmc/phosphor-power/file_descriptor.hpp
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/mock.hpp
/openbmc/phosphor-power/phosphor-power-supply/util.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_bytes_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/log_phase_fault_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_read_sensor_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_write_vout_command_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/run_rule_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.cpp
/openbmc/phosphor-power/phosphor-regulators/src/device.hpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging.hpp
/openbmc/phosphor-power/phosphor-regulators/src/journal.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.cpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_service.hpp
/openbmc/phosphor-power/phosphor-regulators/src/rail.hpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/main.cpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/utility.hpp
/openbmc/phosphor-power/phosphor-regulators/src/services.hpp
/openbmc/phosphor-power/phosphor-regulators/src/temporary_file.cpp
/openbmc/phosphor-power/phosphor-regulators/src/vpd.hpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_write_byte_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/set_device_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/id_map_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/phase_fault_detection_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/system_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/test_sdbus_error.hpp
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/pmbus.cpp
/openbmc/phosphor-power/power-sequencer/mihawk-cpld.hpp
/openbmc/phosphor-power/power-sequencer/ucd90160.cpp
/openbmc/phosphor-power/power-sequencer/ucd90160.hpp
/openbmc/phosphor-power/power-supply/main.cpp
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/power-supply/record_manager.cpp
/openbmc/phosphor-power/power-supply/record_manager.hpp
/openbmc/phosphor-power/services/phosphor-psu-monitor.service
power-utils/main.cpp
power-utils/version.cpp
/openbmc/phosphor-power/types.hpp
/openbmc/phosphor-power/utility.cpp
/openbmc/phosphor-power/utility.hpp
b9cf0d2b27-Feb-2023 George Liu <liuxiwei@inspur.com>

tools: Fix some warnings by cppcheck

Warning message:
tools/i2c/i2c.hpp:30:9: performance: Variable 'busStr' is assigned in
constructor body. Consider performing initialization in
initialization lis

tools: Fix some warnings by cppcheck

Warning message:
tools/i2c/i2c.hpp:30:9: performance: Variable 'busStr' is assigned in
constructor body. Consider performing initialization in
initialization list. [useInitializationList]
busStr = "/dev/i2c-" + std::to_string(busId);
^

tools/power-utils/updater.cpp:213:18: style: Local variable 'devPath'
shadows outer variable [shadowVariable]
auto devPath = internal::getDevicePath(p);
^
tools/power-utils/updater.hpp:108:17: note: Shadowed declaration
std::string devPath;
^
tools/power-utils/updater.cpp:213:18: note: Shadow variable
auto devPath = internal::getDevicePath(p);
^

Tested: Verify that there are no such warnings in local CI.

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: Ibc7536345ee40579256c398646ad00a05b686ab3

show more ...


/openbmc/phosphor-power/OWNERS
/openbmc/phosphor-power/README.md
/openbmc/phosphor-power/example/psu.json
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/org/open_power/Witherspoon/Fault.errors.yaml
/openbmc/phosphor-power/org/open_power/Witherspoon/Fault.metadata.yaml
/openbmc/phosphor-power/org/open_power/Witherspoon/Fault/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/README.md
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/README.md
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/UCD90320Monitor_ibm,everest.json
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/UCD90320Monitor_ibm,rainier.json
/openbmc/phosphor-power/phosphor-power-sequencer/src/README.md
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90320_monitor.cpp
/openbmc/phosphor-power/phosphor-power-supply/README.md
/openbmc/phosphor-power/phosphor-power-supply/configurations/witherspoon/psu_config.json
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/power_supply_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/README.md
/openbmc/phosphor-power/phosphor-regulators/config_files/ibm_bonnell.json
/openbmc/phosphor-power/phosphor-regulators/config_files/ibm_everest.json
/openbmc/phosphor-power/phosphor-regulators/config_files/ibm_rainier.json
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/README.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/action.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/and.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/chassis.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_presence.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_vpd.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/config_file.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/configuration.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/device.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_capture_bytes.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_compare_bit.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_compare_byte.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_compare_bytes.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_interface.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_write_bit.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_write_byte.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_write_bytes.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/if.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/log_phase_fault.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/not.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/or.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/phase_fault_detection.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/pmbus_read_sensor.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/pmbus_write_vout_command.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/presence_detection.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/rail.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/rule.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/run_rule.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/sensor_monitoring.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/set_device.md
/openbmc/phosphor-power/phosphor-regulators/docs/design.md
/openbmc/phosphor-power/phosphor-regulators/examples/config.json
/openbmc/phosphor-power/phosphor-regulators/schema/config_schema.json
/openbmc/phosphor-power/phosphor-regulators/src/journal.cpp
/openbmc/phosphor-power/phosphor-regulators/src/phase_fault.hpp
/openbmc/phosphor-power/phosphor-regulators/test/run-ci.sh
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/tools/validate-regulators-config.py
/openbmc/phosphor-power/power-sequencer/example/ucd90160.yaml
/openbmc/phosphor-power/power-sequencer/gen-ucd90160-defs.py
/openbmc/phosphor-power/services/phosphor-regulators-config.service
/openbmc/phosphor-power/services/phosphor-regulators.service
/openbmc/phosphor-power/services/pseq-monitor-pgood.service
i2c/i2c.hpp
power-utils/updater.cpp
7354ce6222-Jul-2022 Patrick Williams <patrick@stwcx.xyz>

sdbusplus: use shorter type aliases

The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines. Possible replacements are

sdbusplus: use shorter type aliases

The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines. Possible replacements are for:
* bus_t
* exception_t
* manager_t
* match_t
* message_t
* object_t
* slot_t

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ief05bd757cffb1453e058a719ee4b060861752e7

show more ...


/openbmc/phosphor-power/.gitignore
/openbmc/phosphor-power/OWNERS
/openbmc/phosphor-power/cold-redundancy/cold_redundancy.cpp
/openbmc/phosphor-power/cold-redundancy/cold_redundancy.hpp
/openbmc/phosphor-power/cold-redundancy/util.cpp
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/meson_options.txt
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/UCD90320Monitor_ibm,everest.json
/openbmc/phosphor-power/phosphor-power-sequencer/config_files/UCD90320Monitor_ibm,rainier.json
/openbmc/phosphor-power/phosphor-power-sequencer/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_interface.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_interface.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_sequencer_monitor.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_sequencer_monitor.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90320_monitor.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90320_monitor.hpp
/openbmc/phosphor-power/phosphor-power-supply/average.hpp
/openbmc/phosphor-power/phosphor-power-supply/maximum.hpp
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/record_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/record_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/meson.build
/openbmc/phosphor-power/phosphor-power-supply/test/mock.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/power_supply_tests.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.hpp
/openbmc/phosphor-power/phosphor-power-supply/util_base.hpp
/openbmc/phosphor-power/phosphor-regulators/config_files/ibm_rainier.json
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_capture_bytes_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_capture_bytes_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.cpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensor.cpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensor.hpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensors.hpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging.hpp
/openbmc/phosphor-power/phosphor-regulators/src/interfaces/manager_interface.cpp
/openbmc/phosphor-power/phosphor-regulators/src/interfaces/manager_interface.hpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.hpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_service.cpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_service.hpp
/openbmc/phosphor-power/phosphor-regulators/src/sensor_monitoring.cpp
/openbmc/phosphor-power/phosphor-regulators/src/sensor_monitoring.hpp
/openbmc/phosphor-power/phosphor-regulators/src/services.hpp
/openbmc/phosphor-power/phosphor-regulators/src/vpd.hpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_capture_bytes_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/chassis_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/mock_services.hpp
/openbmc/phosphor-power/phosphor-regulators/test/rail_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/sensor_monitoring_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/system_tests.cpp
/openbmc/phosphor-power/pmbus.cpp
/openbmc/phosphor-power/pmbus.hpp
/openbmc/phosphor-power/power-sequencer/mihawk-cpld.cpp
/openbmc/phosphor-power/power-sequencer/mihawk-cpld.hpp
/openbmc/phosphor-power/power-sequencer/pgood_monitor.hpp
/openbmc/phosphor-power/power-sequencer/runtime_monitor.cpp
/openbmc/phosphor-power/power-sequencer/runtime_monitor.hpp
/openbmc/phosphor-power/power-sequencer/ucd90160.cpp
/openbmc/phosphor-power/power-sequencer/ucd90160.hpp
/openbmc/phosphor-power/power-supply/average.hpp
/openbmc/phosphor-power/power-supply/main.cpp
/openbmc/phosphor-power/power-supply/maximum.hpp
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/power-supply/power_supply.hpp
/openbmc/phosphor-power/services/phosphor-power-control.service
/openbmc/phosphor-power/services/phosphor-psu-monitor.service
/openbmc/phosphor-power/services/phosphor-regulators-config.service
/openbmc/phosphor-power/services/phosphor-regulators-monitor-disable.service
/openbmc/phosphor-power/services/phosphor-regulators-monitor-enable.service
/openbmc/phosphor-power/services/phosphor-regulators.service
power-utils/updater.hpp
/openbmc/phosphor-power/types.hpp
/openbmc/phosphor-power/utility.cpp
/openbmc/phosphor-power/utility.hpp
770de58005-Nov-2021 Shawn McCarney <shawnmm@us.ibm.com>

Add retry support to I2CInterface

Enhance the I2CInterface class hierarchy to support retrying failed I2C
operations.

Add an optional parameter to i2c::create() to specify the maximum number
of ret

Add retry support to I2CInterface

Enhance the I2CInterface class hierarchy to support retrying failed I2C
operations.

Add an optional parameter to i2c::create() to specify the maximum number
of retries to perform for an I2C operation. Default to 0 retries so
that existing code will not be affected.

Testing:
* Tested each modified function
* When I2C operation succeeds
* When I2C operation fails
* When no retries are done
* When retries are done
* When retried operation succeeds
* When retried operation fails
* See complete test plan at
https://gist.github.com/smccarney/8d203a40d9984402ac495dc3d689c12d

Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>
Change-Id: I2b0e782e5caaafa9908ef5625687377b959b38ff

show more ...


/openbmc/phosphor-power/MAINTAINERS
/openbmc/phosphor-power/OWNERS
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_interface.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/mock.cpp
/openbmc/phosphor-power/phosphor-power-supply/test/mock.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/power_supply_tests.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.hpp
/openbmc/phosphor-power/phosphor-power-supply/util_base.hpp
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_vpd.md
/openbmc/phosphor-power/phosphor-regulators/schema/config_schema.json
/openbmc/phosphor-power/phosphor-regulators/src/chassis.cpp
/openbmc/phosphor-power/phosphor-regulators/src/chassis.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.cpp
/openbmc/phosphor-power/phosphor-regulators/src/device.cpp
/openbmc/phosphor-power/phosphor-regulators/src/device.hpp
/openbmc/phosphor-power/phosphor-regulators/src/interfaces/manager_interface.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.hpp
/openbmc/phosphor-power/phosphor-regulators/src/phase_fault_detection.hpp
/openbmc/phosphor-power/phosphor-regulators/src/rail.hpp
/openbmc/phosphor-power/phosphor-regulators/src/sensor_monitoring.hpp
/openbmc/phosphor-power/phosphor-regulators/src/system.cpp
/openbmc/phosphor-power/phosphor-regulators/src/system.hpp
/openbmc/phosphor-power/phosphor-regulators/src/vpd.cpp
/openbmc/phosphor-power/phosphor-regulators/src/vpd.hpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/compare_vpd_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/chassis_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/config_file_parser_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/system_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/pmbus.cpp
/openbmc/phosphor-power/pmbus.hpp
/openbmc/phosphor-power/power-sequencer/pgood_monitor.cpp
/openbmc/phosphor-power/power-sequencer/runtime_monitor.cpp
/openbmc/phosphor-power/power-sequencer/ucd90160.cpp
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/power-supply/record_manager.cpp
/openbmc/phosphor-power/services/phosphor-regulators-monitor-disable.service
i2c/i2c.cpp
i2c/i2c.hpp
i2c/i2c_interface.hpp
i2c/test/mocked_i2c_interface.cpp
/openbmc/phosphor-power/utility.cpp
/openbmc/phosphor-power/utility.hpp
0c9a33d613-Sep-2021 Adriana Kobylak <anoo@us.ibm.com>

clang updates

The openbmc CI was recently updated to clang-12 which requires some
formatting updates to the code:
https://github.com/openbmc/openbmc-build-scripts/commit/4569bf49daaebff06be048242690

clang updates

The openbmc CI was recently updated to clang-12 which requires some
formatting updates to the code:
https://github.com/openbmc/openbmc-build-scripts/commit/4569bf49daaebff06be0482426908bb5497fad08

Make those updates and refresh the clang-format file with the one from
docs:
https://github.com/openbmc/docs/blob/master/style/cpp/.clang-format

Change-Id: Ieb3626526373a053ec84431e7560003f229f338d
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>

show more ...


/openbmc/phosphor-power/.clang-format
/openbmc/phosphor-power/.shellcheck
/openbmc/phosphor-power/README.md
/openbmc/phosphor-power/device.hpp
/openbmc/phosphor-power/device_monitor.hpp
/openbmc/phosphor-power/elog-errors.hpp
/openbmc/phosphor-power/file_descriptor.hpp
/openbmc/phosphor-power/gpio.hpp
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/meson_options.txt
/openbmc/phosphor-power/phosphor-power-sequencer/README.md
/openbmc/phosphor-power/phosphor-power-sequencer/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/meson.build
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_control_main.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_interface.cpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/power_interface.hpp
/openbmc/phosphor-power/phosphor-power-sequencer/src/ucd90320_monitor.cpp
/openbmc/phosphor-power/phosphor-power-supply/README.md
/openbmc/phosphor-power/phosphor-power-supply/configurations/witherspoon/psu_config.json
/openbmc/phosphor-power/phosphor-power-supply/main.cpp
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/mock.cpp
/openbmc/phosphor-power/phosphor-power-supply/test/mock.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/power_supply_tests.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.hpp
/openbmc/phosphor-power/phosphor-power-supply/util_base.hpp
/openbmc/phosphor-power/phosphor-regulators/config_files/ibm_everest.json
/openbmc/phosphor-power/phosphor-regulators/config_files/ibm_rainier.json
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/README.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/action.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/chassis.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_vpd.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/config_file.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/device.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/i2c_capture_bytes.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/log_phase_fault.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/phase_fault_detection.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/pmbus_read_sensor.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/presence_detection.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/rule.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/set_device.md
/openbmc/phosphor-power/phosphor-regulators/docs/design.md
/openbmc/phosphor-power/phosphor-regulators/examples/config.json
/openbmc/phosphor-power/phosphor-regulators/schema/config_schema.json
/openbmc/phosphor-power/phosphor-regulators/src/actions/action_environment.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/and_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/compare_presence_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/compare_presence_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/compare_vpd_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/compare_vpd_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_capture_bytes_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_capture_bytes_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_byte_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_bytes_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_byte_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/if_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/log_phase_fault_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/not_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/or_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_read_sensor_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_read_sensor_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_write_vout_command_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_write_vout_command_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/run_rule_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/set_device_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/chassis.cpp
/openbmc/phosphor-power/phosphor-regulators/src/chassis.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.cpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser_error.hpp
/openbmc/phosphor-power/phosphor-regulators/src/configuration.cpp
/openbmc/phosphor-power/phosphor-regulators/src/configuration.hpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensor.cpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensor.hpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensors.cpp
/openbmc/phosphor-power/phosphor-regulators/src/dbus_sensors.hpp
/openbmc/phosphor-power/phosphor-regulators/src/device.cpp
/openbmc/phosphor-power/phosphor-regulators/src/device.hpp
/openbmc/phosphor-power/phosphor-regulators/src/error_history.hpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging.cpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging.hpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging_utils.cpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/src/exception_utils.cpp
/openbmc/phosphor-power/phosphor-regulators/src/exception_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/src/interfaces/manager_interface.cpp
/openbmc/phosphor-power/phosphor-regulators/src/journal.cpp
/openbmc/phosphor-power/phosphor-regulators/src/journal.hpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.hpp
/openbmc/phosphor-power/phosphor-regulators/src/meson.build
/openbmc/phosphor-power/phosphor-regulators/src/phase_fault.hpp
/openbmc/phosphor-power/phosphor-regulators/src/phase_fault_detection.cpp
/openbmc/phosphor-power/phosphor-regulators/src/phase_fault_detection.hpp
/openbmc/phosphor-power/phosphor-regulators/src/pmbus_error.hpp
/openbmc/phosphor-power/phosphor-regulators/src/pmbus_utils.cpp
/openbmc/phosphor-power/phosphor-regulators/src/pmbus_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_detection.cpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_detection.hpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_service.cpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_service.hpp
/openbmc/phosphor-power/phosphor-regulators/src/rail.cpp
/openbmc/phosphor-power/phosphor-regulators/src/rail.hpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/main.cpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/utility.hpp
/openbmc/phosphor-power/phosphor-regulators/src/rule.hpp
/openbmc/phosphor-power/phosphor-regulators/src/sensor_monitoring.cpp
/openbmc/phosphor-power/phosphor-regulators/src/sensor_monitoring.hpp
/openbmc/phosphor-power/phosphor-regulators/src/sensors.hpp
/openbmc/phosphor-power/phosphor-regulators/src/services.hpp
/openbmc/phosphor-power/phosphor-regulators/src/system.cpp
/openbmc/phosphor-power/phosphor-regulators/src/system.hpp
/openbmc/phosphor-power/phosphor-regulators/src/vpd.cpp
/openbmc/phosphor-power/phosphor-regulators/src/vpd.hpp
/openbmc/phosphor-power/phosphor-regulators/src/write_verification_error.hpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/action_environment_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/action_utils_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/and_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/compare_presence_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/compare_vpd_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_capture_bytes_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_compare_bit_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_compare_byte_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_compare_bytes_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_write_bit_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_write_byte_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_write_bytes_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/if_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/log_phase_fault_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/not_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/or_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/pmbus_read_sensor_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/pmbus_write_vout_command_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/run_rule_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/set_device_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/chassis_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/config_file_parser_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/configuration_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/error_history_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/error_logging_utils_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/exception_utils_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/id_map_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/mock_error_logging.hpp
/openbmc/phosphor-power/phosphor-regulators/test/mock_sensors.hpp
/openbmc/phosphor-power/phosphor-regulators/test/mock_services.hpp
/openbmc/phosphor-power/phosphor-regulators/test/mock_vpd.hpp
/openbmc/phosphor-power/phosphor-regulators/test/phase_fault_detection_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/phase_fault_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/pmbus_error_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/pmbus_utils_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/presence_detection_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/rail_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/rule_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/sensor_monitoring_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/sensors_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/system_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/test_sdbus_error.hpp
/openbmc/phosphor-power/phosphor-regulators/test/test_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/write_verification_error_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/tools/validate-regulators-config.py
/openbmc/phosphor-power/pmbus.hpp
/openbmc/phosphor-power/power-sequencer/mihawk-cpld.cpp
/openbmc/phosphor-power/power-sequencer/mihawk-cpld.hpp
/openbmc/phosphor-power/power-sequencer/pgood_monitor.hpp
/openbmc/phosphor-power/power-sequencer/runtime_monitor.hpp
/openbmc/phosphor-power/power-sequencer/ucd90160.cpp
/openbmc/phosphor-power/power-sequencer/ucd90160.hpp
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/power-supply/record_manager.hpp
/openbmc/phosphor-power/services/phosphor-psu-monitor.service
/openbmc/phosphor-power/services/phosphor-regulators-config.service
/openbmc/phosphor-power/services/pseq-monitor-pgood.service
/openbmc/phosphor-power/services/pseq-monitor.service
i2c/i2c.hpp
/openbmc/phosphor-power/utility.cpp
/openbmc/phosphor-power/utility.hpp
8429e88413-Dec-2020 Lei YU <yulei.sh@bytedance.com>

i2c: Initialize variable ret

The varialbe `ret` in some functions is not initialized and cause the
build warning and treated as error:

error: 'ret' may be used uninitialized in this function

i2c: Initialize variable ret

The varialbe `ret` in some functions is not initialized and cause the
build warning and treated as error:

error: 'ret' may be used uninitialized in this function
[-Werror=maybe-uninitialized]

Fixes openbmc/phosphor-power#3.

Signed-off-by: Lei YU <yulei.sh@bytedance.com>
Change-Id: Ica6b1af434736f6fd96a1bbb9e511bf1c8fb1d7a

show more ...


/openbmc/phosphor-power/.clang-format
/openbmc/phosphor-power/MAINTAINERS
/openbmc/phosphor-power/README.md
/openbmc/phosphor-power/cold-redundancy/cold_redundancy.hpp
/openbmc/phosphor-power/cold-redundancy/meson.build
/openbmc/phosphor-power/elog-errors.hpp
/openbmc/phosphor-power/file_descriptor.hpp
/openbmc/phosphor-power/gpio.hpp
/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/meson_options.txt
/openbmc/phosphor-power/org/open_power/Witherspoon/Fault.errors.yaml
/openbmc/phosphor-power/org/open_power/Witherspoon/Fault.metadata.yaml
/openbmc/phosphor-power/phosphor-power-supply/README.md
/openbmc/phosphor-power/phosphor-power-supply/configurations/witherspoon/psu_config.json
/openbmc/phosphor-power/phosphor-power-supply/main.cpp
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/power_supply.cpp
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/meson.build
/openbmc/phosphor-power/phosphor-power-supply/test/mock.cpp
/openbmc/phosphor-power/phosphor-power-supply/test/mock.hpp
/openbmc/phosphor-power/phosphor-power-supply/test/power_supply_tests.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.cpp
/openbmc/phosphor-power/phosphor-power-supply/util.hpp
/openbmc/phosphor-power/phosphor-power-supply/util_base.hpp
/openbmc/phosphor-power/phosphor-regulators/README.md
/openbmc/phosphor-power/phosphor-regulators/config_files/ibm_rainier.json
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/README.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_presence.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/compare_vpd.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/device.md
/openbmc/phosphor-power/phosphor-regulators/docs/config_file/presence_detection.md
/openbmc/phosphor-power/phosphor-regulators/docs/design.md
/openbmc/phosphor-power/phosphor-regulators/examples/config_file.json
/openbmc/phosphor-power/phosphor-regulators/src/actions/action_environment.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/compare_presence_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/compare_vpd_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_read_sensor_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_read_sensor_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_write_vout_command_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/pmbus_write_vout_command_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/chassis.cpp
/openbmc/phosphor-power/phosphor-regulators/src/chassis.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.cpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser.hpp
/openbmc/phosphor-power/phosphor-regulators/src/config_file_parser_error.hpp
/openbmc/phosphor-power/phosphor-regulators/src/configuration.cpp
/openbmc/phosphor-power/phosphor-regulators/src/configuration.hpp
/openbmc/phosphor-power/phosphor-regulators/src/device.cpp
/openbmc/phosphor-power/phosphor-regulators/src/device.hpp
/openbmc/phosphor-power/phosphor-regulators/src/error_history.hpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging.cpp
/openbmc/phosphor-power/phosphor-regulators/src/error_logging.hpp
/openbmc/phosphor-power/phosphor-regulators/src/exception_utils.cpp
/openbmc/phosphor-power/phosphor-regulators/src/exception_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/src/ffdc_file.cpp
/openbmc/phosphor-power/phosphor-regulators/src/ffdc_file.hpp
/openbmc/phosphor-power/phosphor-regulators/src/id_map.cpp
/openbmc/phosphor-power/phosphor-regulators/src/id_map.hpp
/openbmc/phosphor-power/phosphor-regulators/src/interfaces/manager_interface.cpp
/openbmc/phosphor-power/phosphor-regulators/src/interfaces/manager_interface.hpp
/openbmc/phosphor-power/phosphor-regulators/src/journal.cpp
/openbmc/phosphor-power/phosphor-regulators/src/journal.hpp
/openbmc/phosphor-power/phosphor-regulators/src/main.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.cpp
/openbmc/phosphor-power/phosphor-regulators/src/manager.hpp
/openbmc/phosphor-power/phosphor-regulators/src/meson.build
/openbmc/phosphor-power/phosphor-regulators/src/pmbus_error.hpp
/openbmc/phosphor-power/phosphor-regulators/src/pmbus_utils.cpp
/openbmc/phosphor-power/phosphor-regulators/src/pmbus_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_detection.hpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_service.cpp
/openbmc/phosphor-power/phosphor-regulators/src/presence_service.hpp
/openbmc/phosphor-power/phosphor-regulators/src/rail.cpp
/openbmc/phosphor-power/phosphor-regulators/src/rail.hpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/main.cpp
/openbmc/phosphor-power/phosphor-regulators/src/regsctl/utility.hpp
/openbmc/phosphor-power/phosphor-regulators/src/sensor_monitoring.cpp
/openbmc/phosphor-power/phosphor-regulators/src/sensor_monitoring.hpp
/openbmc/phosphor-power/phosphor-regulators/src/services.hpp
/openbmc/phosphor-power/phosphor-regulators/src/system.cpp
/openbmc/phosphor-power/phosphor-regulators/src/system.hpp
/openbmc/phosphor-power/phosphor-regulators/src/temporary_file.cpp
/openbmc/phosphor-power/phosphor-regulators/src/temporary_file.hpp
/openbmc/phosphor-power/phosphor-regulators/src/write_verification_error.hpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/action_environment_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/compare_presence_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/compare_vpd_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/pmbus_read_sensor_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/pmbus_write_vout_command_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/chassis_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/config_file_parser_error_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/config_file_parser_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/configuration_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/error_history_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/exception_utils_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/ffdc_file_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/id_map_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/mock_error_logging.hpp
/openbmc/phosphor-power/phosphor-regulators/test/mock_journal.hpp
/openbmc/phosphor-power/phosphor-regulators/test/mock_presence_service.hpp
/openbmc/phosphor-power/phosphor-regulators/test/mock_services.hpp
/openbmc/phosphor-power/phosphor-regulators/test/pmbus_error_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/pmbus_utils_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/presence_detection_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/rail_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/run-ci.sh
/openbmc/phosphor-power/phosphor-regulators/test/sensor_monitoring_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/system_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/temporary_file_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/test_utils.hpp
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/write_verification_error_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/tools/validate-regulators-config.py
/openbmc/phosphor-power/pmbus.cpp
/openbmc/phosphor-power/pmbus.hpp
/openbmc/phosphor-power/power-sequencer/gen-ucd90160-defs.py
/openbmc/phosphor-power/power-sequencer/main.cpp
/openbmc/phosphor-power/power-sequencer/meson.build
/openbmc/phosphor-power/power-sequencer/mihawk-cpld.cpp
/openbmc/phosphor-power/power-sequencer/mihawk-cpld.hpp
/openbmc/phosphor-power/power-sequencer/pgood_monitor.cpp
/openbmc/phosphor-power/power-sequencer/runtime_monitor.cpp
/openbmc/phosphor-power/power-supply/power_supply.cpp
/openbmc/phosphor-power/power-supply/record_manager.hpp
/openbmc/phosphor-power/services/phosphor-regulators-config.service
/openbmc/phosphor-power/services/phosphor-regulators-monitor-disable.service
/openbmc/phosphor-power/services/phosphor-regulators-monitor-enable.service
/openbmc/phosphor-power/test/file_descriptor_tests.cpp
/openbmc/phosphor-power/test/meson.build
i2c/i2c.cpp
/openbmc/phosphor-power/types.hpp
/openbmc/phosphor-power/utility.cpp
/openbmc/phosphor-power/utility.hpp
e632e14a29-Feb-2020 Shawn McCarney <shawnmm@us.ibm.com>

Document byte order of I2CInterface read/write

Update the doxygen comments for the following two I2CInterface methods:
* void read(uint8_t addr, uint16_t& data);
* void write(uint8_t addr, uint16_t

Document byte order of I2CInterface read/write

Update the doxygen comments for the following two I2CInterface methods:
* void read(uint8_t addr, uint16_t& data);
* void write(uint8_t addr, uint16_t data);

Document that the two bytes are transmitted with the low order byte
first.

The I2CInterface methods call the following two i2c-dev functions:
* i2c_smbus_read_word_data()
* i2c_smbus_write_word_data()

The SMBus Read Word and Write Word protocols require the low order byte
to be sent first.

Testing:
* Tested on Witherspoon using i2cget and i2cset. These command line
tools call the same two i2c-dev functions. Verified that the low
order byte is read/written first.

Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>
Change-Id: I83ba69f8cde08ee719d34802afed691a61fe3e84

show more ...


/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/phosphor-power-supply/main.cpp
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/power_supply.hpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.cpp
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_bit_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_bit_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_byte_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_byte_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_bytes_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_compare_bytes_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_bit_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_bit_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_byte_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_byte_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_bytes_action.cpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/i2c_write_bytes_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_compare_bit_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_compare_byte_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_compare_bytes_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_write_bit_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_write_byte_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/i2c_write_bytes_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/tools/validate-regulators-config.py
/openbmc/phosphor-power/services/phosphor-regulators.service
i2c/i2c_interface.hpp
dc8e931214-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 ...

ff48143813-Feb-2020 Shawn McCarney <shawnmm@us.ibm.com>

Only build tests if -Dtests=enabled specified

A meson build option named 'tests' is defined for this repository. It
indicates whether gtest/gmock tests should be built.

However, some tests are cur

Only build tests if -Dtests=enabled specified

A meson build option named 'tests' is defined for this repository. It
indicates whether gtest/gmock tests should be built.

However, some tests are currently always built even if -Dtests=enabled
isn't specified. This causes build errors in some environments where
gtest and gmock are not available.

Modify meson.build files to only descend into 'test' subdirectories and
build test cases if -Dtests=enabled was specified.

Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>
Change-Id: Ic0da2326e3d9c273ff76d54b5ac27cbe00d78876

show more ...


/openbmc/phosphor-power/meson.build
/openbmc/phosphor-power/phosphor-power-supply/main.cpp
/openbmc/phosphor-power/phosphor-power-supply/meson.build
/openbmc/phosphor-power/phosphor-power-supply/psu_manager.hpp
/openbmc/phosphor-power/phosphor-regulators/config_files/.keep
/openbmc/phosphor-power/phosphor-regulators/meson.build
/openbmc/phosphor-power/phosphor-regulators/src/actions/action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/action_error.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/and_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/if_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/not_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/or_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/run_rule_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/actions/set_device_action.hpp
/openbmc/phosphor-power/phosphor-regulators/src/device.hpp
/openbmc/phosphor-power/phosphor-regulators/src/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/actions/action_environment_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/action_error_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/and_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/if_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/mock_action.hpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/not_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/or_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/run_rule_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/actions/set_device_action_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/device_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/id_map_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/test/meson.build
/openbmc/phosphor-power/phosphor-regulators/test/validate-regulators-config_tests.cpp
/openbmc/phosphor-power/phosphor-regulators/tools/validate-regulators-config.py
/openbmc/phosphor-power/power-supply/meson.build
/openbmc/phosphor-power/services/phosphor-psu-monitor.service
i2c/meson.build
power-utils/meson.build
b1216b9621-Jan-2020 Shawn McCarney <shawnmm@us.ibm.com>

Create libi2c_dev_mock.a to solve linker errors

The i2c::create() function is currently defined in
mocked_i2c_interface.hpp. This causes linker errors if that header file
is included by multiple .c

Create libi2c_dev_mock.a to solve linker errors

The i2c::create() function is currently defined in
mocked_i2c_interface.hpp. This causes linker errors if that header file
is included by multiple .cpp files in the same test executable.

Moved i2c::create() to mocked_i2c_interface.cpp so that it is only
defined once. Created the static library libi2c_dev_mock.a that
contains mocked_i2c_interface.o.

Test executables that need the mock version of i2c::create() should link
with libi2c_dev_mock.a.

Normal executables that need the real version of i2c::create() should
link with libi2c_dev.a as before. This has not changed.

Signed-off-by: Shawn McCarney <shawnmm@us.ibm.com>
Change-Id: Ic00203c5429c1a2162327905ba547602258c6b0d

show more ...

12