Sunny Srivastava | fa5e4d3 | 2023-03-12 11:59:49 -0500 | [diff] [blame] | 1 | #pragma once |
| 2 | |
| 3 | #include <cstdint> |
Rekha Aparna | 9f255f5 | 2025-04-23 05:25:07 -0500 | [diff] [blame^] | 4 | #include <string> |
| 5 | #include <vector> |
Sunny Srivastava | fa5e4d3 | 2023-03-12 11:59:49 -0500 | [diff] [blame] | 6 | |
| 7 | namespace vpd |
| 8 | { |
| 9 | namespace constants |
| 10 | { |
| 11 | static constexpr auto KEYWORD_SIZE = 2; |
| 12 | static constexpr auto RECORD_SIZE = 4; |
| 13 | static constexpr auto INDENTATION = 4; |
| 14 | static constexpr auto SUCCESS = 0; |
| 15 | static constexpr auto FAILURE = -1; |
| 16 | |
| 17 | // To be explicitly used for string comparison. |
| 18 | static constexpr auto STR_CMP_SUCCESS = 0; |
| 19 | |
| 20 | constexpr auto inventoryManagerService = |
| 21 | "xyz.openbmc_project.Inventory.Manager"; |
| 22 | constexpr auto baseInventoryPath = "/xyz/openbmc_project/inventory"; |
Anupama B R | 844f88f | 2025-01-26 02:47:06 -0600 | [diff] [blame] | 23 | constexpr auto pimPersistPath = "/var/lib/phosphor-inventory-manager"; |
Sunny Srivastava | fa5e4d3 | 2023-03-12 11:59:49 -0500 | [diff] [blame] | 24 | constexpr auto ipzVpdInfPrefix = "com.ibm.ipzvpd."; |
| 25 | |
| 26 | constexpr auto vpdManagerService = "com.ibm.VPD.Manager"; |
| 27 | constexpr auto vpdManagerObjectPath = "/com/ibm/VPD/Manager"; |
| 28 | constexpr auto vpdManagerInfName = "com.ibm.VPD.Manager"; |
| 29 | constexpr auto inventoryItemInf = "xyz.openbmc_project.Inventory.Item"; |
Sunny Srivastava | df9e554 | 2025-02-12 12:33:07 -0600 | [diff] [blame] | 30 | constexpr auto viniInf = "com.ibm.ipzvpd.VINI"; |
Sunny Srivastava | fa5e4d3 | 2023-03-12 11:59:49 -0500 | [diff] [blame] | 31 | constexpr auto locationCodeInf = "com.ibm.ipzvpd.Location"; |
| 32 | constexpr auto assetInf = "xyz.openbmc_project.Inventory.Decorator.Asset"; |
| 33 | constexpr auto objectMapperService = "xyz.openbmc_project.ObjectMapper"; |
| 34 | constexpr auto objectMapperObjectPath = "/xyz/openbmc_project/object_mapper"; |
| 35 | constexpr auto objectMapperInfName = "xyz.openbmc_project.ObjectMapper"; |
Anupama B R | 6be2c01 | 2025-01-23 02:59:27 -0600 | [diff] [blame] | 36 | constexpr auto chassisStateManagerService = "xyz.openbmc_project.State.Chassis"; |
| 37 | constexpr auto chassisStateManagerObjectPath = |
| 38 | "/xyz/openbmc_project/state/chassis0"; |
| 39 | constexpr auto chassisStateManagerInfName = "xyz.openbmc_project.State.Chassis"; |
Souvik Roy | 7f749a6 | 2025-02-10 22:23:41 -0600 | [diff] [blame] | 40 | constexpr auto dbusService = "org.freedesktop.DBus"; |
| 41 | constexpr auto dbusObjectPath = "/org/freedesktop/DBus"; |
| 42 | constexpr auto dbusInterface = "org.freedesktop.DBus"; |
| 43 | constexpr auto biosConfigMgrService = "xyz.openbmc_project.BIOSConfigManager"; |
Sunny Srivastava | df9e554 | 2025-02-12 12:33:07 -0600 | [diff] [blame] | 44 | constexpr auto networkInf = |
| 45 | "xyz.openbmc_project.Inventory.Item.NetworkInterface"; |
| 46 | constexpr auto pcieSlotInf = "xyz.openbmc_project.Inventory.Item.PCIeSlot"; |
| 47 | constexpr auto slotNumInf = "xyz.openbmc_project.Inventory.Decorator.Slot"; |
| 48 | constexpr auto i2cDeviceInf = |
| 49 | "xyz.openbmc_project.Inventory.Decorator.I2CDevice"; |
Anupama B R | 844f88f | 2025-01-26 02:47:06 -0600 | [diff] [blame] | 50 | constexpr auto vpdManagerProcessName = "vpd-manager"; |
Souvik Roy | 36dba30 | 2025-01-23 03:38:04 -0600 | [diff] [blame] | 51 | constexpr auto biosConfigMgrObjPath = |
| 52 | "/xyz/openbmc_project/bios_config/manager"; |
| 53 | constexpr auto biosConfigMgrInterface = |
| 54 | "xyz.openbmc_project.BIOSConfig.Manager"; |
| 55 | |
Rekha Aparna | 9f255f5 | 2025-04-23 05:25:07 -0500 | [diff] [blame^] | 56 | constexpr auto KwdIM = "IM"; |
| 57 | |
| 58 | // Valid IM values list. |
| 59 | static std::vector<std::string> validImValues{ |
| 60 | "0x50001000", "0x50001001", "0x50001002", "0x50003000", "0x50004000", |
| 61 | "0x60001000", "0x60001001", "0x60001002", "0x60002000", "0x60004000"}; |
| 62 | |
Souvik Roy | 36dba30 | 2025-01-23 03:38:04 -0600 | [diff] [blame] | 63 | static constexpr auto VALUE_0 = 0; |
| 64 | static constexpr auto VALUE_1 = 1; |
| 65 | static constexpr auto VALUE_2 = 2; |
| 66 | static constexpr auto VALUE_3 = 3; |
| 67 | static constexpr auto VALUE_4 = 4; |
| 68 | static constexpr auto VALUE_5 = 5; |
| 69 | static constexpr auto VALUE_6 = 6; |
| 70 | static constexpr auto VALUE_7 = 7; |
| 71 | static constexpr auto VALUE_8 = 8; |
| 72 | static constexpr auto VALUE_32 = 32; |
Sunny Srivastava | fa5e4d3 | 2023-03-12 11:59:49 -0500 | [diff] [blame] | 73 | } // namespace constants |
| 74 | } // namespace vpd |