xref: /openbmc/bmcweb/features/redfish/include/generated/enums/pcie_device.hpp (revision a8d8f9d82afce0780f5cea13839d8a650787fc41)
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,
150ec8b83dSEd Tanous };
160ec8b83dSEd Tanous 
170ec8b83dSEd Tanous enum class DeviceType{
180ec8b83dSEd Tanous     Invalid,
190ec8b83dSEd Tanous     SingleFunction,
200ec8b83dSEd Tanous     MultiFunction,
210ec8b83dSEd Tanous     Simulated,
220ec8b83dSEd Tanous     Retimer,
230ec8b83dSEd Tanous };
240ec8b83dSEd Tanous 
250ec8b83dSEd Tanous enum class SlotType{
260ec8b83dSEd Tanous     Invalid,
270ec8b83dSEd Tanous     FullLength,
280ec8b83dSEd Tanous     HalfLength,
290ec8b83dSEd Tanous     LowProfile,
300ec8b83dSEd Tanous     Mini,
310ec8b83dSEd Tanous     M2,
320ec8b83dSEd Tanous     OEM,
330ec8b83dSEd Tanous     OCP3Small,
340ec8b83dSEd Tanous     OCP3Large,
350ec8b83dSEd Tanous     U2,
360ec8b83dSEd Tanous };
370ec8b83dSEd Tanous 
380ec8b83dSEd Tanous enum class LaneSplittingType{
390ec8b83dSEd Tanous     Invalid,
400ec8b83dSEd Tanous     None,
410ec8b83dSEd Tanous     Bridged,
420ec8b83dSEd Tanous     Bifurcated,
430ec8b83dSEd Tanous };
440ec8b83dSEd Tanous 
45*a8d8f9d8SEd Tanous enum class CXLDeviceType{
46*a8d8f9d8SEd Tanous     Invalid,
47*a8d8f9d8SEd Tanous     Type1,
48*a8d8f9d8SEd Tanous     Type2,
49*a8d8f9d8SEd Tanous     Type3,
50*a8d8f9d8SEd Tanous };
51*a8d8f9d8SEd Tanous 
520ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(PCIeTypes, {
530ec8b83dSEd Tanous     {PCIeTypes::Invalid, "Invalid"},
540ec8b83dSEd Tanous     {PCIeTypes::Gen1, "Gen1"},
550ec8b83dSEd Tanous     {PCIeTypes::Gen2, "Gen2"},
560ec8b83dSEd Tanous     {PCIeTypes::Gen3, "Gen3"},
570ec8b83dSEd Tanous     {PCIeTypes::Gen4, "Gen4"},
580ec8b83dSEd Tanous     {PCIeTypes::Gen5, "Gen5"},
590ec8b83dSEd Tanous });
600ec8b83dSEd Tanous 
610ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(DeviceType, {
620ec8b83dSEd Tanous     {DeviceType::Invalid, "Invalid"},
630ec8b83dSEd Tanous     {DeviceType::SingleFunction, "SingleFunction"},
640ec8b83dSEd Tanous     {DeviceType::MultiFunction, "MultiFunction"},
650ec8b83dSEd Tanous     {DeviceType::Simulated, "Simulated"},
660ec8b83dSEd Tanous     {DeviceType::Retimer, "Retimer"},
670ec8b83dSEd Tanous });
680ec8b83dSEd Tanous 
690ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(SlotType, {
700ec8b83dSEd Tanous     {SlotType::Invalid, "Invalid"},
710ec8b83dSEd Tanous     {SlotType::FullLength, "FullLength"},
720ec8b83dSEd Tanous     {SlotType::HalfLength, "HalfLength"},
730ec8b83dSEd Tanous     {SlotType::LowProfile, "LowProfile"},
740ec8b83dSEd Tanous     {SlotType::Mini, "Mini"},
750ec8b83dSEd Tanous     {SlotType::M2, "M2"},
760ec8b83dSEd Tanous     {SlotType::OEM, "OEM"},
770ec8b83dSEd Tanous     {SlotType::OCP3Small, "OCP3Small"},
780ec8b83dSEd Tanous     {SlotType::OCP3Large, "OCP3Large"},
790ec8b83dSEd Tanous     {SlotType::U2, "U2"},
800ec8b83dSEd Tanous });
810ec8b83dSEd Tanous 
820ec8b83dSEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(LaneSplittingType, {
830ec8b83dSEd Tanous     {LaneSplittingType::Invalid, "Invalid"},
840ec8b83dSEd Tanous     {LaneSplittingType::None, "None"},
850ec8b83dSEd Tanous     {LaneSplittingType::Bridged, "Bridged"},
860ec8b83dSEd Tanous     {LaneSplittingType::Bifurcated, "Bifurcated"},
870ec8b83dSEd Tanous });
880ec8b83dSEd Tanous 
89*a8d8f9d8SEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(CXLDeviceType, {
90*a8d8f9d8SEd Tanous     {CXLDeviceType::Invalid, "Invalid"},
91*a8d8f9d8SEd Tanous     {CXLDeviceType::Type1, "Type1"},
92*a8d8f9d8SEd Tanous     {CXLDeviceType::Type2, "Type2"},
93*a8d8f9d8SEd Tanous     {CXLDeviceType::Type3, "Type3"},
94*a8d8f9d8SEd Tanous });
95*a8d8f9d8SEd Tanous 
960ec8b83dSEd Tanous }
970ec8b83dSEd Tanous // clang-format on
98