blob: 20f260ce5ee0ee4745f62cce50ea2e424b02f4d5 [file] [log] [blame]
Marri Devender Raoa62bacc2017-06-04 23:40:16 -05001#ifndef OPENBMC_IPMI_FRU_READ_H
2#define OPENBMC_IPMI_FRU_READ_H
3
4#include <systemd/sd-bus.h>
Patrick Venture0b02be92018-08-31 11:55:55 -07005
Marri Devender Raoa62bacc2017-06-04 23:40:16 -05006#include <array>
Marri Devender Raoa62bacc2017-06-04 23:40:16 -05007#include <map>
Patrick Venture0b02be92018-08-31 11:55:55 -07008#include <string>
Marri Devender Raoa62bacc2017-06-04 23:40:16 -05009#include <vector>
10
11struct IPMIFruData
12{
13 std::string section;
14 std::string property;
15 std::string delimiter;
16};
17
18using DbusProperty = std::string;
19using DbusPropertyVec = std::vector<std::pair<DbusProperty, IPMIFruData>>;
20
21using DbusInterface = std::string;
22using DbusInterfaceVec = std::vector<std::pair<DbusInterface, DbusPropertyVec>>;
23
24using FruInstancePath = std::string;
Ratan Gupta00330972018-01-19 16:23:10 +053025
26struct FruInstance
27{
28 uint8_t entityID;
29 uint8_t entityInstance;
30 FruInstancePath path;
31 DbusInterfaceVec interfaces;
32};
33
34using FruInstanceVec = std::vector<FruInstance>;
Marri Devender Raoa62bacc2017-06-04 23:40:16 -050035
36using FruId = uint32_t;
37using FruMap = std::map<FruId, FruInstanceVec>;
38
39#endif