/openbmc/phosphor-power/tools/power-utils/ |
H A D | version.cpp | 53 PsuVersionInfo getVersionInfo(const std::string& psuInventoryPath) in getVersionInfo() argument 68 auto devicePath = devices->find(psuInventoryPath); in getVersionInfo() 72 entry("PATH=%s", psuInventoryPath.c_str())); in getVersionInfo() 107 std::string getVersionJson(const std::string& psuInventoryPath) in getVersionJson() argument 110 const auto [devicePath, type, fileName] = getVersionInfo(psuInventoryPath); in getVersionJson() 135 const std::string& psuInventoryPath) in getVersionDbus() argument 138 const auto [i2cbus, i2caddr] = getPsuI2c(bus, psuInventoryPath); in getVersionDbus() 171 const std::string& psuInventoryPath) in getVersion() argument 179 version = internal::getVersionJson(psuInventoryPath); in getVersion() 184 version = internal::getVersionDbus(bus, psuInventoryPath); in getVersion()
|
H A D | model.cpp | 55 std::string getModelJson(const std::string& psuInventoryPath) in getModelJson() argument 67 auto device = it->find(psuInventoryPath); in getModelJson() 71 "Unable to find device path for PSU {}", psuInventoryPath)}; in getModelJson() 77 std::format("Empty device path for PSU {}", psuInventoryPath)}; in getModelJson() 123 const std::string& psuInventoryPath) in getModelDbus() argument 126 const auto [i2cBus, i2cAddr] = getPsuI2c(bus, psuInventoryPath); in getModelDbus() 138 std::string getModel(sdbusplus::bus_t& bus, const std::string& psuInventoryPath) in getModel() argument 146 model = internal::getModelJson(psuInventoryPath); in getModel() 151 model = internal::getModelDbus(bus, psuInventoryPath); in getModel()
|
H A D | updater.cpp | 50 const std::string& model, const std::string& psuInventoryPath, in getClassInstance() argument 55 return std::make_unique<aeiUpdater::AeiUpdater>(psuInventoryPath, in getClassInstance() 58 return std::make_unique<Updater>(psuInventoryPath, devPath, imageDir); in getClassInstance() 184 bool update(sdbusplus::bus_t& bus, const std::string& psuInventoryPath, in update() argument 187 auto devPath = utils::getDevicePath(bus, psuInventoryPath); in update() 197 fsPath.filename().string(), psuInventoryPath, devPath, imageDir); in update() 202 psuInventoryPath); in update() 213 Updater::Updater(const std::string& psuInventoryPath, in Updater() argument 215 bus(sdbusplus::bus::new_default()), psuInventoryPath(psuInventoryPath), in Updater() 264 auto service = util::getService(psuInventoryPath, INVENTORY_IFACE, bus); in setPresent() [all …]
|
H A D | updater.hpp | 53 bool update(sdbusplus::bus_t& bus, const std::string& psuInventoryPath, 73 Updater(const std::string& psuInventoryPath, const std::string& devPath, 114 return psuInventoryPath; in getPsuInventoryPath() 268 std::string psuInventoryPath; member in updater::Updater 321 const std::string& model, const std::string& psuInventoryPath,
|
H A D | utils.cpp | 49 PsuI2cInfo getPsuI2c(sdbusplus::bus_t& bus, const std::string& psuInventoryPath) in getPsuI2c() argument 78 if (path.back() == psuInventoryPath.back()) in getPsuI2c() 191 const std::string& psuInventoryPath) in getDevicePath() argument 202 auto devicePath = data["psuDevices"][psuInventoryPath]; in getDevicePath() 211 const auto [i2cbus, i2caddr] = getPsuI2c(bus, psuInventoryPath); in getDevicePath()
|
H A D | utils.hpp | 48 const std::string& psuInventoryPath); 108 const std::string& psuInventoryPath);
|
H A D | aei_updater.hpp | 48 AeiUpdater(const std::string& psuInventoryPath, const std::string& devPath, in AeiUpdater() argument 50 Updater(psuInventoryPath, devPath, imageDir) in AeiUpdater()
|
H A D | model.hpp | 34 const std::string& psuInventoryPath);
|
H A D | version.hpp | 36 const std::string& psuInventoryPath);
|
/openbmc/phosphor-psu-code-mgmt/src/ |
H A D | activation.cpp | 124 bool Activation::doUpdate(const std::string& psuInventoryPath) in doUpdate() argument 126 currentUpdatingPsu = psuInventoryPath; in doUpdate() 139 "PSU", psuInventoryPath, "ERROR", e); in doUpdate() 337 bool Activation::isPresent(const std::string& psuInventoryPath) in isPresent() argument 343 utils::getService(bus, psuInventoryPath.c_str(), ITEM_IFACE); in isPresent() 345 psuInventoryPath.c_str(), ITEM_IFACE, in isPresent() 353 "PSU", psuInventoryPath, "ERROR", e); in isPresent() 358 bool Activation::isCompatible(const std::string& psuInventoryPath) in isCompatible() argument 364 utils::getService(bus, psuInventoryPath.c_str(), ASSET_IFACE); in isCompatible() 366 bus, service.c_str(), psuInventoryPath.c_str(), ASSET_IFACE, in isCompatible() [all …]
|
H A D | item_updater.cpp | 210 const std::string& psuInventoryPath) in onUpdateDone() argument 216 utils::isAssociated(psuInventoryPath, it->second->associations())) in onUpdateDone() 218 removePsuObject(psuInventoryPath); in onUpdateDone() 231 psuPathActivationMap.emplace(psuInventoryPath, it->second); in onUpdateDone() 245 void ItemUpdater::createPsuObject(const std::string& psuInventoryPath, in createPsuObject() argument 258 ACTIVATION_REV_ASSOCIATION, psuInventoryPath)); in createPsuObject() 260 psuPathActivationMap.emplace(psuInventoryPath, it->second); in createPsuObject() 270 ACTIVATION_REV_ASSOCIATION, psuInventoryPath)); in createPsuObject() 275 psuPathActivationMap.emplace(psuInventoryPath, activations[versionId]); in createPsuObject() 287 void ItemUpdater::removePsuObject(const std::string& psuInventoryPath) in removePsuObject() argument [all …]
|
H A D | utils.hpp | 126 bool isAssociated(const std::string& psuInventoryPath, 165 virtual bool isAssociated(const std::string& psuInventoryPath, 205 bool isAssociated(const std::string& psuInventoryPath, 250 inline bool isAssociated(const std::string& psuInventoryPath, in isAssociated() argument 253 return getUtils().isAssociated(psuInventoryPath, assocs); in isAssociated()
|
H A D | activation.hpp | 218 bool doUpdate(const std::string& psuInventoryPath); 239 bool isPresent(const std::string& psuInventoryPath); 242 bool isCompatible(const std::string& psuInventoryPath); 255 std::string getUpdateService(const std::string& psuInventoryPath);
|
H A D | item_updater.hpp | 113 const std::string& psuInventoryPath) override; 171 void createPsuObject(const std::string& psuInventoryPath, 180 void removePsuObject(const std::string& psuInventoryPath);
|
H A D | utils.cpp | 252 bool Utils::isAssociated(const std::string& psuInventoryPath, in isAssociated() argument 256 [&psuInventoryPath](const auto& assoc) { in isAssociated() 257 return psuInventoryPath == std::get<2>(assoc); in isAssociated()
|
H A D | activation_listener.hpp | 22 const std::string& psuInventoryPath) = 0;
|
/openbmc/phosphor-psu-code-mgmt/test/ |
H A D | mocked_utils.hpp | 34 std::string(const std::string& psuInventoryPath)); 37 std::string(const std::string& psuInventoryPath)); 42 MOCK_CONST_METHOD2(isAssociated, bool(const std::string& psuInventoryPath,
|
H A D | mocked_activation_listener.hpp | 20 const std::string& psuInventoryPath));
|
H A D | test_activation.cpp | 68 std::string getUpdateService(const std::string& psuInventoryPath) const in getUpdateService() 70 return activation->getUpdateService(psuInventoryPath); in getUpdateService() 104 std::string psuInventoryPath = "/com/example/inventory/powersupply1"; in TEST_F() local 114 auto service = getUpdateService(psuInventoryPath); in TEST_F()
|
/openbmc/phosphor-power/tools/power-utils/test/ |
H A D | test_updater.cpp | 75 std::string psuInventoryPath = "/com/example/psu"; member in TestUpdater 81 updater = std::make_unique<Updater>(psuInventoryPath, devPath, imageDir); in TEST_F() 86 updater = std::make_unique<Updater>(psuInventoryPath, devPath, imageDir); in TEST_F()
|
/openbmc/phosphor-power/phosphor-power-supply/ |
H A D | psu_manager.cpp | 926 auto psuInventoryPath = psu->getInventoryPath(); in updateMissingPSUs() local 928 psuInventoryPath.substr(strlen(INVENTORY_OBJ_PATH)); in updateMissingPSUs() 935 presProperty = getPresence(bus, psuInventoryPath); in updateMissingPSUs() 945 psuInventoryPath) in updateMissingPSUs()
|