blob: 99ed1cb2042a9b6cebe893379e9d42090c457864 [file] [log] [blame]
Matt Spinler1a94cc32019-09-11 13:32:12 -05001#pragma once
2
3namespace openpower
4{
5namespace pels
6{
7
Matt Spinler289aa472019-09-20 12:33:29 -05008/**
9 * @brief Useful component IDs
10 */
Matt Spinler09d64002019-09-11 14:29:46 -050011enum class ComponentID
12{
13 phosphorLogging = 0x2000
14};
15
Matt Spinler1a94cc32019-09-11 13:32:12 -050016/**
17 * @brief PEL section IDs
18 */
19enum class SectionID
20{
21 privateHeader = 0x5048, // 'PH'
22 userHeader = 0x5548, // 'UH'
23 primarySRC = 0x5053, // 'PS'
24 secondarySRC = 0x5353, // 'SS'
25 extendedUserHeader = 0x4548, // 'EH'
26 failingMTMS = 0x4D54, // 'MT'
27 dumpLocation = 0x4448, // 'DH'
28 firmwareError = 0x5357, // 'SW'
29 impactedPart = 0x4C50, // 'LP'
30 logicalResource = 0x4C52, // 'LR'
31 hmcID = 0x484D, // 'HM'
32 epow = 0x4550, // 'EP'
33 ioEvent = 0x4945, // 'IE'
34 mfgInfo = 0x4D49, // 'MI'
35 callhome = 0x4348, // 'CH'
36 userData = 0x5544, // 'UD'
37 envInfo = 0x4549, // 'EI'
38 extUserData = 0x4544 // 'ED'
39};
40
Matt Spinler289aa472019-09-20 12:33:29 -050041/**
42 * @brief Useful SRC types
43 */
Matt Spinler93e29322019-09-20 11:16:15 -050044enum class SRCType
45{
46 bmcError = 0xBD,
Matt Spinler4deed972023-04-28 14:09:22 -050047 powerError = 0x11,
48 hostbootError = 0xBC
Matt Spinler93e29322019-09-20 11:16:15 -050049};
50
Matt Spinler289aa472019-09-20 12:33:29 -050051/**
52 * @brief Creator IDs
53 */
54enum class CreatorID
55{
56 fsp = 'E',
57 hmc = 'C',
58 hostboot = 'B',
59 ioDrawer = 'M',
60 occ = 'T',
61 openBMC = 'O',
62 partFW = 'L',
63 phyp = 'H',
64 powerControl = 'W',
65 powerNV = 'P',
66 sapphire = 'K',
67 slic = 'S',
68};
69
Matt Spinlerfdb6a202019-09-20 14:09:20 -050070/**
71 * @brief Useful event scope values
72 */
73enum class EventScope
74{
75 entirePlatform = 0x03
76};
77
78/**
79 * @brief Useful event type values
80 */
81enum class EventType
82{
Matt Spinlerf1e85e22019-11-01 11:31:31 -050083 notApplicable = 0x00,
84 miscInformational = 0x01,
85 tracing = 0x02
Matt Spinlerfdb6a202019-09-20 14:09:20 -050086};
87
Matt Spinlera7525aa2019-11-01 11:11:07 -050088/**
89 * @brief The major types of severity values, based on the
90 * the left nibble of the severity value.
91 */
92enum class SeverityType
93{
94 nonError = 0x00,
95 recovered = 0x10,
96 predictive = 0x20,
97 unrecoverable = 0x40,
98 critical = 0x50,
99 diagnostic = 0x60,
100 symptom = 0x70
101};
102
Matt Spinlerf1e85e22019-11-01 11:31:31 -0500103/**
104 * @brief The Action Flags values with the bit
105 * numbering needed by std::bitset.
106 *
107 * Not an enum class so that casting isn't needed
108 * by the bitset operations.
109 */
110enum ActionFlagsBits
111{
112 serviceActionFlagBit = 15, // 0x8000
113 hiddenFlagBit = 14, // 0x4000
114 reportFlagBit = 13, // 0x2000
115 dontReportToHostFlagBit = 12, // 0x1000
116 callHomeFlagBit = 11, // 0x0800
117 isolationIncompleteFlagBit = 10, // 0x0400
118 spCallHomeFlagBit = 8, // 0x0100
119 osSWErrorBit = 7, // 0x0080
120 osHWErrorBit = 6 // 0x0040
121};
122
Matt Spinlerf38ce982019-11-07 13:25:53 -0600123/**
124 * @brief The PEL transmission states
125 */
126enum class TransmissionState
127{
128 newPEL = 0,
129 badPEL = 1,
130 sent = 2,
131 acked = 3
132};
133
Matt Spinler578e0702020-03-13 09:40:43 -0500134/**
Matt Spinlerba0ee002020-03-13 11:24:14 -0500135 * @brief Callout priority values
136 */
137enum class CalloutPriority
138{
139 high = 'H',
140 medium = 'M',
141 mediumGroupA = 'A',
142 mediumGroupB = 'B',
143 mediumGroupC = 'C',
144 low = 'L'
145};
146
Matt Spinler1a94cc32019-09-11 13:32:12 -0500147} // namespace pels
148} // namespace openpower