xref: /openbmc/bmcweb/features/redfish/include/generated/enums/pcie_device.hpp (revision dd5c81e9e330c20f534496174472efb6fe2c112e)
10ec8b83dSEd Tanous #pragma once
20ec8b83dSEd Tanous #include <nlohmann/json.hpp>
30ec8b83dSEd Tanous 
40ec8b83dSEd Tanous namespace pcie_device
50ec8b83dSEd Tanous {
60ec8b83dSEd Tanous // clang-format off
70ec8b83dSEd Tanous 
80ec8b83dSEd Tanous enum class PCIeTypes{
90ec8b83dSEd Tanous     Invalid,
100ec8b83dSEd Tanous     Gen1,
110ec8b83dSEd Tanous     Gen2,
120ec8b83dSEd Tanous     Gen3,
130ec8b83dSEd Tanous     Gen4,
140ec8b83dSEd Tanous     Gen5,
15*dd5c81e9SGunnar Mills     Gen6,
160ec8b83dSEd Tanous };
170ec8b83dSEd Tanous 
180ec8b83dSEd Tanous enum class DeviceType{
190ec8b83dSEd Tanous     Invalid,
200ec8b83dSEd Tanous     SingleFunction,
210ec8b83dSEd Tanous     MultiFunction,
220ec8b83dSEd Tanous     Simulated,
230ec8b83dSEd Tanous     Retimer,
240ec8b83dSEd Tanous };
250ec8b83dSEd Tanous 
260ec8b83dSEd Tanous enum class SlotType{
270ec8b83dSEd Tanous     Invalid,
280ec8b83dSEd Tanous     FullLength,
290ec8b83dSEd Tanous     HalfLength,
300ec8b83dSEd Tanous     LowProfile,
310ec8b83dSEd Tanous     Mini,
320ec8b83dSEd Tanous     M2,
330ec8b83dSEd Tanous     OEM,
340ec8b83dSEd Tanous     OCP3Small,
350ec8b83dSEd Tanous     OCP3Large,
360ec8b83dSEd Tanous     U2,
370ec8b83dSEd Tanous };
380ec8b83dSEd Tanous 
390ec8b83dSEd Tanous enum class LaneSplittingType{
400ec8b83dSEd Tanous     Invalid,
410ec8b83dSEd Tanous     None,
420ec8b83dSEd Tanous     Bridged,
430ec8b83dSEd Tanous     Bifurcated,
440ec8b83dSEd Tanous };
450ec8b83dSEd Tanous 
46a8d8f9d8SEd Tanous enum class CXLDeviceType{
47a8d8f9d8SEd Tanous     Invalid,
48a8d8f9d8SEd Tanous     Type1,
49a8d8f9d8SEd Tanous     Type2,
50a8d8f9d8SEd Tanous     Type3,
51a8d8f9d8SEd Tanous };
52a8d8f9d8SEd Tanous 
53e9cc1bc9SEd Tanous enum class CXLDynamicCapacityPolicies{
54e9cc1bc9SEd Tanous     Invalid,
55e9cc1bc9SEd Tanous     Free,
56e9cc1bc9SEd Tanous     Contiguous,
57e9cc1bc9SEd Tanous     Prescriptive,
58e9cc1bc9SEd Tanous     TagBased,
59e9cc1bc9SEd Tanous };
60e9cc1bc9SEd Tanous 
610ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(PCIeTypes, {
620ec8b83dSEd Tanous     {PCIeTypes::Invalid, "Invalid"},
630ec8b83dSEd Tanous     {PCIeTypes::Gen1, "Gen1"},
640ec8b83dSEd Tanous     {PCIeTypes::Gen2, "Gen2"},
650ec8b83dSEd Tanous     {PCIeTypes::Gen3, "Gen3"},
660ec8b83dSEd Tanous     {PCIeTypes::Gen4, "Gen4"},
670ec8b83dSEd Tanous     {PCIeTypes::Gen5, "Gen5"},
68*dd5c81e9SGunnar Mills     {PCIeTypes::Gen6, "Gen6"},
690ec8b83dSEd Tanous });
700ec8b83dSEd Tanous 
710ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(DeviceType, {
720ec8b83dSEd Tanous     {DeviceType::Invalid, "Invalid"},
730ec8b83dSEd Tanous     {DeviceType::SingleFunction, "SingleFunction"},
740ec8b83dSEd Tanous     {DeviceType::MultiFunction, "MultiFunction"},
750ec8b83dSEd Tanous     {DeviceType::Simulated, "Simulated"},
760ec8b83dSEd Tanous     {DeviceType::Retimer, "Retimer"},
770ec8b83dSEd Tanous });
780ec8b83dSEd Tanous 
790ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(SlotType, {
800ec8b83dSEd Tanous     {SlotType::Invalid, "Invalid"},
810ec8b83dSEd Tanous     {SlotType::FullLength, "FullLength"},
820ec8b83dSEd Tanous     {SlotType::HalfLength, "HalfLength"},
830ec8b83dSEd Tanous     {SlotType::LowProfile, "LowProfile"},
840ec8b83dSEd Tanous     {SlotType::Mini, "Mini"},
850ec8b83dSEd Tanous     {SlotType::M2, "M2"},
860ec8b83dSEd Tanous     {SlotType::OEM, "OEM"},
870ec8b83dSEd Tanous     {SlotType::OCP3Small, "OCP3Small"},
880ec8b83dSEd Tanous     {SlotType::OCP3Large, "OCP3Large"},
890ec8b83dSEd Tanous     {SlotType::U2, "U2"},
900ec8b83dSEd Tanous });
910ec8b83dSEd Tanous 
920ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(LaneSplittingType, {
930ec8b83dSEd Tanous     {LaneSplittingType::Invalid, "Invalid"},
940ec8b83dSEd Tanous     {LaneSplittingType::None, "None"},
950ec8b83dSEd Tanous     {LaneSplittingType::Bridged, "Bridged"},
960ec8b83dSEd Tanous     {LaneSplittingType::Bifurcated, "Bifurcated"},
970ec8b83dSEd Tanous });
980ec8b83dSEd Tanous 
99a8d8f9d8SEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(CXLDeviceType, {
100a8d8f9d8SEd Tanous     {CXLDeviceType::Invalid, "Invalid"},
101a8d8f9d8SEd Tanous     {CXLDeviceType::Type1, "Type1"},
102a8d8f9d8SEd Tanous     {CXLDeviceType::Type2, "Type2"},
103a8d8f9d8SEd Tanous     {CXLDeviceType::Type3, "Type3"},
104a8d8f9d8SEd Tanous });
105a8d8f9d8SEd Tanous 
106e9cc1bc9SEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(CXLDynamicCapacityPolicies, {
107e9cc1bc9SEd Tanous     {CXLDynamicCapacityPolicies::Invalid, "Invalid"},
108e9cc1bc9SEd Tanous     {CXLDynamicCapacityPolicies::Free, "Free"},
109e9cc1bc9SEd Tanous     {CXLDynamicCapacityPolicies::Contiguous, "Contiguous"},
110e9cc1bc9SEd Tanous     {CXLDynamicCapacityPolicies::Prescriptive, "Prescriptive"},
111e9cc1bc9SEd Tanous     {CXLDynamicCapacityPolicies::TagBased, "TagBased"},
112e9cc1bc9SEd Tanous });
113e9cc1bc9SEd Tanous 
1140ec8b83dSEd Tanous }
1150ec8b83dSEd Tanous // clang-format on
116