Initial commit of OpenSPARC T2 design and verification files.
[OpenSPARC-T2-DV] / verif / diag / assembly / include / constants.h
CommitLineData
86530b38
AT
1/*
2* ========== Copyright Header Begin ==========================================
3*
4* OpenSPARC T2 Processor File: constants.h
5* Copyright (C) 1995-2007 Sun Microsystems, Inc. All Rights Reserved
6* 4150 Network Circle, Santa Clara, California 95054, U.S.A.
7*
8* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
9*
10* This program is free software; you can redistribute it and/or modify
11* it under the terms of the GNU General Public License as published by
12* the Free Software Foundation; version 2 of the License.
13*
14* This program is distributed in the hope that it will be useful,
15* but WITHOUT ANY WARRANTY; without even the implied warranty of
16* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17* GNU General Public License for more details.
18*
19* You should have received a copy of the GNU General Public License
20* along with this program; if not, write to the Free Software
21* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22*
23* For the avoidance of doubt, and except that if any non-GPL license
24* choice is available it will apply instead, Sun elects to use only
25* the General Public License version 2 (GPLv2) at this time for any
26* software where a choice of GPL license versions is made
27* available with the language indicating that GPLv2 or any later version
28* may be used, or where a choice of which version of the GPL is applied is
29* otherwise unspecified.
30*
31* Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
32* CA 95054 USA or visit www.sun.com if you need additional information or
33* have any questions.
34*
35*
36* ========== Copyright Header End ============================================
37*/
38#ifndef __CONSTANTS_H__
39#define __CONSTANTS_H__
40
41#define ALREADY_INCLUDED_CONSTANTS_DOT_H
42
43#define PAGE_4K_MASK 0xfff
44#define PAGE_8K_MASK 0x1fff
45#define PAGE_64K_MASK 0xffff
46#define PAGE_512K_MASK 0x7ffff
47#define PAGE_4M_MASK 0x3fffff
48
49#define ALIGN_PAGE_4K .align PAGE_4K_MASK+1
50#define ALIGN_PAGE_8K .align PAGE_8K_MASK+1
51#define ALIGN_PAGE_64K .align PAGE_64K_MASK+1
52#define ALIGN_PAGE_512K .align PAGE_512K_MASK+1
53#define ALIGN_PAGE_4M .align PAGE_4M_MASK+1
54
55#if 0
56
57#define ICACHE_LINE_SIZE_IN_BYTES 32
58#define DCACHE_LINE_SIZE_IN_BYTES 32
59#define PCACHE_LINE_SIZE_IN_BYTES 64
60#define WCACHE_LINE_SIZE_IN_BYTES 64
61
62#define ECACHE_LINE_SIZE_IN_BYTES_1M 64
63#define ECACHE_LINE_SIZE_IN_BYTES_4M 256
64#define ECACHE_LINE_SIZE_IN_BYTES_8M 512
65
66! ASR field definitions
67#include "asr.h"
68
69! ASI field definitions and alternate names
70#include "asi_s.h"
71
72! MEMBAR definitions
73#include "membar.h"
74
75! PSTATE field definitions
76#include "pstate.h"
77
78! TSTATE field definitions and initialization
79#include "tstate.h"
80
81! VER field definitions
82#include "ver.h"
83
84! MMU and TSB mappings and definitions:
85#include "mmu_tsb_map.h"
86
87! DCU_CONTROL_REGISTER field definitions and initializations
88#include "dcu_ctrl_reg.h"
89
90! SAFARI field definitions and initializations
91#include "safari_config_reg.h"
92#include "safari_port_id.h"
93
94! ESTATE definitions and initializations
95#include "estate.h"
96
97! AFSR (Asynchronous Fault Status Register) definitions and initializations
98#include "afsr.h"
99
100! DISPATCH_CONTROL_REGISTER definitions and initializations
101#include "dispatch_ctrl_reg.h"
102
103/* Add fields to the below list as needed. 2/24/94 lyoungs */
104
105! TTE definitions and switches
106#include "tte.h"
107
108! TLB definitions and constants
109#include "tlb.h"
110#include "tlb_tag.h"
111#include "tlb_cam.h"
112
113! ICACHE Diagnostic Access registers' field definitions
114#include "icache_tag.h"
115#include "icache_instr.h"
116#include "icache_snoop.h"
117
118! DCACHE Diagnostic Access registers' field definitions
119#include "dcache_tag.h"
120#include "dcache_data.h"
121#include "dcache_snoop.h"
122
123! WCACHE Diagnostic Access registers' field definitions
124#include "wcache_tag.h"
125#include "wcache_data.h"
126#include "wcache_snoop.h"
127
128! PCACHE Diagnostic Access registers' field definitions
129#include "pcache_tag.h"
130#include "pcache_status_data.h"
131#include "pcache_data.h"
132#include "pcache_snoop.h"
133#include "pcache_hist_tag.h"
134#include "pcache_hist_data.h"
135
136! ECACHE Diagnostic Access registers' field definitions
137#include "ecache_ctrl_reg.h"
138#include "ecache_data.h"
139#include "ecache_tag.h"
140
141! ASI_BRANCH_PREDICTION_ARRAY field definitions
142#include "bpa.h"
143
144! ASI_FDIV_SQRT_SEED field definitions
145#include "fdiv_seed_tbl.h"
146
147! ASR_PERF_CONTROL_REG field definitions
148#include "pcr.h"
149
150! ASR_PERF_COUNTER field definitions
151#include "pic.h"
152
153! ASR_GRAPHIC_STATUS_REG field definitions
154#include "gsr.h"
155
156! TSB register definitions
157#include "tsb_tag.h"
158#include "tsb_base.h"
159#include "tsb_ext.h"
160
161! misc. MMU definitions
162#include "context_reg.h"
163#include "sfsr.h"
164#include "demap.h"
165
166! MCU registers
167#include "mcu_tim1_ctrl_reg.h"
168#include "mcu_tim2_ctrl_reg.h"
169#include "mcu_tim3_ctrl_reg.h"
170#include "mcu_tim4_ctrl_reg.h"
171#include "mcu_addr_dec_reg0.h"
172#include "mcu_addr_dec_reg1.h"
173#include "mcu_addr_dec_reg2.h"
174#include "mcu_addr_dec_reg3.h"
175#include "mcu_addr_ctrl_reg.h"
176
177!Floating point status register
178#include "fsr.h"
179
180! TICK registers
181#include "tick.h"
182#include "tick_compare.h"
183#include "stick.h"
184#include "stick_compare.h"
185
186! Interrupt registers
187#include "intr_dispatch_status.h"
188#include "intr_receive.h"
189#include "softint.h"
190
191! Boot Bus registers
192#include "bootbus_ctrl_reg.h"
193
194! Trap Types definitions
195#include "trap_types.h"
196
197! Poweron-sequence initialization
198#include "poweron_init.h"
199
200#ifdef PDU_DIAGS
201
202#ifndef STOP_SIM
203#define STOP_SIM 0x48
204#endif
205#define STALL_G(n) tn %icc, n
206#define STALL2_G(n) sub %g0, n, %g0
207
208#endif PDU_DIAGS
209
210#endif /* if 0 */
211
212#endif /* __CONSTANTS_H__*/