4c17af4701a9b083891991fb3f67c10753f350a8
[linux-flexiantxendom0-3.2.10.git] / include / asm-ia64 / sn / mca.h
1 /*
2  * File:        mca.h
3  * Purpose:     Machine check handling specific to the SN platform defines
4  *
5  * Copyright (C) 2001-2002 Silicon Graphics, Inc. All rights reserved.
6  * 
7  * This program is free software; you can redistribute it and/or modify it 
8  * under the terms of version 2 of the GNU General Public License 
9  * as published by the Free Software Foundation.
10  * 
11  * This program is distributed in the hope that it would be useful, but 
12  * WITHOUT ANY WARRANTY; without even the implied warranty of 
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 
14  * 
15  * Further, this software is distributed without any warranty that it is 
16  * free of the rightful claim of any third person regarding infringement 
17  * or the like.  Any license provided herein, whether implied or 
18  * otherwise, applies only to this software file.  Patent licenses, if 
19  * any, provided herein do not apply to combinations of this program with 
20  * other software, or any other product whatsoever.
21  * 
22  * You should have received a copy of the GNU General Public 
23  * License along with this program; if not, write the Free Software 
24  * Foundation, Inc., 59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
25  * 
26  * Contact information:  Silicon Graphics, Inc., 1600 Amphitheatre Pkwy, 
27  * Mountain View, CA  94043, or:
28  * 
29  * http://www.sgi.com 
30  * 
31  * For further information regarding this notice, see: 
32  * 
33  * http://oss.sgi.com/projects/GenInfo/NoticeExplan
34  */
35
36 #include <linux/config.h>
37 #include <linux/types.h>
38 #include <asm/sal.h>
39 #include <asm/mca.h>
40
41 #ifdef CONFIG_IA64_SGI_SN
42
43 typedef u64 __uint64_t;
44
45 typedef struct {
46         __uint64_t sh_event_occurred;
47         __uint64_t sh_first_error;
48         __uint64_t sh_event_overflow;
49         __uint64_t sh_pi_first_error;
50         __uint64_t sh_pi_error_summary;
51         __uint64_t sh_pi_error_overflow;
52         __uint64_t sh_pi_error_detail_1;
53         __uint64_t sh_pi_error_detail_2;
54         __uint64_t sh_pi_hw_time_stamp;
55         __uint64_t sh_pi_uncorrected_detail_1;
56         __uint64_t sh_pi_uncorrected_detail_2;
57         __uint64_t sh_pi_uncorrected_detail_3;
58         __uint64_t sh_pi_uncorrected_detail_4;
59         __uint64_t sh_pi_uncor_time_stamp;
60         __uint64_t sh_pi_corrected_detail_1;
61         __uint64_t sh_pi_corrected_detail_2;
62         __uint64_t sh_pi_corrected_detail_3;
63         __uint64_t sh_pi_corrected_detail_4;
64         __uint64_t sh_pi_cor_time_stamp;
65         __uint64_t sh_mem_error_summary;
66         __uint64_t sh_mem_error_overflow;
67         __uint64_t sh_misc_err_hdr_lower;
68         __uint64_t sh_misc_err_hdr_upper;
69         __uint64_t sh_dir_uc_err_hdr_lower;
70         __uint64_t sh_dir_uc_err_hdr_upper;
71         __uint64_t sh_dir_cor_err_hdr_lower;
72         __uint64_t sh_dir_cor_err_hdr_upper;
73         __uint64_t sh_mem_error_mask;
74         __uint64_t sh_md_uncor_time_stamp;
75         __uint64_t sh_md_cor_time_stamp;
76         __uint64_t sh_md_hw_time_stamp;
77         __uint64_t sh_xn_error_summary;
78         __uint64_t sh_xn_first_error;
79         __uint64_t sh_xn_error_overflow;
80         __uint64_t sh_xniilb_error_summary;
81         __uint64_t sh_xniilb_first_error;
82         __uint64_t sh_xniilb_error_overflow;
83         __uint64_t sh_xniilb_error_detail_1;
84         __uint64_t sh_xniilb_error_detail_2;
85         __uint64_t sh_xniilb_error_detail_3;
86         __uint64_t sh_xnpi_error_summary;
87         __uint64_t sh_xnpi_first_error;
88         __uint64_t sh_xnpi_error_overflow;
89         __uint64_t sh_xnpi_error_detail_1;
90         __uint64_t sh_xnmd_error_summary;
91         __uint64_t sh_xnmd_first_error;
92         __uint64_t sh_xnmd_error_overflow;
93         __uint64_t sh_xnmd_ecc_err_report;
94         __uint64_t sh_xnmd_error_detail_1;
95         __uint64_t sh_lb_error_summary;
96         __uint64_t sh_lb_first_error;
97         __uint64_t sh_lb_error_overflow;
98         __uint64_t sh_lb_error_detail_1;
99         __uint64_t sh_lb_error_detail_2;
100         __uint64_t sh_lb_error_detail_3;
101         __uint64_t sh_lb_error_detail_4;
102         __uint64_t sh_lb_error_detail_5;
103 } sal_log_shub_state_t;
104
105 typedef struct {
106 sal_log_section_hdr_t header;
107         struct
108         {
109                 __uint64_t    err_status      : 1,
110                 guid            : 1,
111                 oem_data        : 1,
112                 reserved        : 61;
113         } valid;
114         __uint64_t             err_status;
115         efi_guid_t      guid;
116         __uint64_t shub_nic;
117         sal_log_shub_state_t    shub_state;
118 } sal_log_plat_info_t;
119
120
121 extern void sal_log_plat_print(int header_len, int sect_len, u8 *p_data, prfunc_t prfunc);
122
123 #ifdef platform_plat_specific_err_print
124 #undef platform_plat_specific_err_print
125 #endif
126 #define platform_plat_specific_err_print sal_log_plat_print
127
128 #endif /* CONFIG_IA64_SGI_SN */