1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef __ALPHA_ERR_EV7_H
3 #define __ALPHA_ERR_EV7_H 1
6 * Data for el packet class PAL (14), type LOGOUT_FRAME (1)
8 struct ev7_pal_logout_subpacket {
15 union el_timestamp timestamp;
21 * Data for el packet class PAL (14), type EV7_PROCESSOR (4)
23 struct ev7_pal_processor_subpacket {
52 * Data for el packet class PAL (14), type EV7_ZBOX (5)
54 struct ev7_pal_zbox_subpacket {
55 u32 zbox0_dram_err_status_1;
56 u32 zbox0_dram_err_status_2;
57 u32 zbox0_dram_err_status_3;
58 u32 zbox0_dram_err_ctl;
59 u32 zbox0_dram_err_adr;
60 u32 zbox0_dift_timeout;
61 u32 zbox0_dram_mapper_ctl;
62 u32 zbox0_frc_err_adr;
63 u32 zbox0_dift_err_status;
65 u32 zbox1_dram_err_status_1;
66 u32 zbox1_dram_err_status_2;
67 u32 zbox1_dram_err_status_3;
68 u32 zbox1_dram_err_ctl;
69 u32 zbox1_dram_err_adr;
70 u32 zbox1_dift_timeout;
71 u32 zbox1_dram_mapper_ctl;
72 u32 zbox1_frc_err_adr;
73 u32 zbox1_dift_err_status;
79 u64 zbox0_ored_syndrome;
80 u64 zbox1_ored_syndrome;
85 * Data for el packet class PAL (14), type EV7_RBOX (6)
87 struct ev7_pal_rbox_subpacket {
108 * Data for el packet class PAL (14), type EV7_IO (7)
110 struct ev7_pal_io_one_port {
124 struct ev7_pal_io_subpacket {
138 struct ev7_pal_io_one_port ports[4];
142 * Environmental subpacket. Data used for el packets:
143 * class PAL (14), type AMBIENT_TEMPERATURE (10)
144 * class PAL (14), type AIRMOVER_FAN (11)
145 * class PAL (14), type VOLTAGE (12)
146 * class PAL (14), type INTRUSION (13)
147 * class PAL (14), type POWER_SUPPLY (14)
148 * class PAL (14), type LAN (15)
149 * class PAL (14), type HOT_PLUG (16)
151 struct ev7_pal_environmental_subpacket {
156 u8 unit_id; /* unit reporting condition */
158 u8 condition; /* condition reported */
162 * Convert environmental type to index
164 static inline int ev7_lf_env_index(int type)
166 BUG_ON((type < EL_TYPE__PAL__ENV__AMBIENT_TEMPERATURE)
167 || (type > EL_TYPE__PAL__ENV__HOT_PLUG));
169 return type - EL_TYPE__PAL__ENV__AMBIENT_TEMPERATURE;
173 * Data for generic el packet class PAL.
175 struct ev7_pal_subpacket {
177 struct ev7_pal_logout_subpacket logout; /* Type 1 */
178 struct ev7_pal_processor_subpacket ev7; /* Type 4 */
179 struct ev7_pal_zbox_subpacket zbox; /* Type 5 */
180 struct ev7_pal_rbox_subpacket rbox; /* Type 6 */
181 struct ev7_pal_io_subpacket io; /* Type 7 */
182 struct ev7_pal_environmental_subpacket env; /* Type 10-16 */
183 u64 as_quad[1]; /* Raw u64 */
188 * Struct to contain collected logout from subpackets.
190 struct ev7_lf_subpackets {
191 struct ev7_pal_logout_subpacket *logout; /* Type 1 */
192 struct ev7_pal_processor_subpacket *ev7; /* Type 4 */
193 struct ev7_pal_zbox_subpacket *zbox; /* Type 5 */
194 struct ev7_pal_rbox_subpacket *rbox; /* Type 6 */
195 struct ev7_pal_io_subpacket *io; /* Type 7 */
196 struct ev7_pal_environmental_subpacket *env[7]; /* Type 10-16 */
201 #endif /* __ALPHA_ERR_EV7_H */