Initial commit of OpenSPARC T2 design and verification files.
[OpenSPARC-T2-DV] / design / sys / iop / spc / tlu / rtl / tlu_eem_dp.v
CommitLineData
86530b38
AT
1// ========== Copyright Header Begin ==========================================
2//
3// OpenSPARC T2 Processor File: tlu_eem_dp.v
4// Copyright (C) 1995-2007 Sun Microsystems, Inc. All Rights Reserved
5// 4150 Network Circle, Santa Clara, California 95054, U.S.A.
6//
7// * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
8//
9// This program is free software; you can redistribute it and/or modify
10// it under the terms of the GNU General Public License as published by
11// the Free Software Foundation; version 2 of the License.
12//
13// This program is distributed in the hope that it will be useful,
14// but WITHOUT ANY WARRANTY; without even the implied warranty of
15// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16// GNU General Public License for more details.
17//
18// You should have received a copy of the GNU General Public License
19// along with this program; if not, write to the Free Software
20// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21//
22// For the avoidance of doubt, and except that if any non-GPL license
23// choice is available it will apply instead, Sun elects to use only
24// the General Public License version 2 (GPLv2) at this time for any
25// software where a choice of GPL license versions is made
26// available with the language indicating that GPLv2 or any later version
27// may be used, or where a choice of which version of the GPL is applied is
28// otherwise unspecified.
29//
30// Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
31// CA 95054 USA or visit www.sun.com if you need additional information or
32// have any questions.
33//
34// ========== Copyright Header End ============================================
35module tlu_eem_dp (
36 asi_error_inject,
37 asi_error_mask,
38 asi_mbist_ecc_in,
39 asi_mbist_run,
40 ecc_in,
41 ecc_out);
42wire [7:0] error_inject;
43wire [7:0] ecc_pre_mux;
44wire [7:0] ecc_mux_0;
45wire mbist_run_;
46wire [7:0] ecc_mux_1;
47
48
49
50input asi_error_inject;
51input [7:0] asi_error_mask;
52
53input [7:0] asi_mbist_ecc_in;
54input asi_mbist_run;
55
56input [7:0] ecc_in;
57
58output [7:0] ecc_out;
59
60
61//assign wr_ecc[07:00] =
62// ((pwr_ecc[07:00] ^
63// ({8 {asi_error_tsau}} & asi_error_mask[07:00])) &
64// {8 {~asi_mbist_run}}) | asi_mbist_tsa_ecc_in[07:00];
65//
66
67tlu_eem_dp_and_macro__ports_2__stack_8r__width_8 error_inject_and (
68 .din0 ({8 {asi_error_inject}} ),
69 .din1 (asi_error_mask [7:0] ),
70 .dout (error_inject [7:0] )
71);
72
73tlu_eem_dp_xor_macro__ports_2__stack_8r__width_8 ecc_pre_mux_xor (
74 .din0 (ecc_in [7:0] ),
75 .din1 (error_inject [7:0] ),
76 .dout (ecc_pre_mux [7:0] )
77);
78
79tlu_eem_dp_inv_macro__stack_8r__width_8 ecc_mux_0_nand (
80 .din (asi_mbist_ecc_in [7:0] ),
81 .dout (ecc_mux_0 [7:0] )
82);
83
84tlu_eem_dp_inv_macro__stack_8r__width_1 mbist_run_inv (
85 .din (asi_mbist_run ),
86 .dout (mbist_run_ )
87);
88
89tlu_eem_dp_nand_macro__ports_2__stack_8r__width_8 ecc_mux_1_nand (
90 .din0 (ecc_pre_mux [7:0] ),
91 .din1 ({8 {mbist_run_}} ),
92 .dout (ecc_mux_1 [7:0] )
93);
94
95tlu_eem_dp_nand_macro__ports_2__stack_8r__width_8 ecc_mux_nand (
96 .din0 (ecc_mux_0 [7:0] ),
97 .din1 (ecc_mux_1 [7:0] ),
98 .dout (ecc_out [7:0] )
99);
100
101//mux_macro ecc_mux (width=8, ports=2, mux=aope, stack=8r) (
102// .din0 (asi_mbist_ecc_in [07:00] ),
103// .din1 (ecc_pre_mux [07:00] ),
104// .sel0 (asi_mbist_run ),
105// .dout (ecc_out [07:00] )
106//);
107
108
109
110supply0 vss; // <- port for ground
111supply1 vdd; // <- port for power
112
113endmodule
114
115
116
117//
118// and macro for ports = 2,3,4
119//
120//
121
122
123
124
125
126module tlu_eem_dp_and_macro__ports_2__stack_8r__width_8 (
127 din0,
128 din1,
129 dout);
130 input [7:0] din0;
131 input [7:0] din1;
132 output [7:0] dout;
133
134
135
136
137
138
139and2 #(8) d0_0 (
140.in0(din0[7:0]),
141.in1(din1[7:0]),
142.out(dout[7:0])
143);
144
145
146
147
148
149
150
151
152
153endmodule
154
155
156
157
158
159//
160// xor macro for ports = 2,3
161//
162//
163
164
165
166
167
168module tlu_eem_dp_xor_macro__ports_2__stack_8r__width_8 (
169 din0,
170 din1,
171 dout);
172 input [7:0] din0;
173 input [7:0] din1;
174 output [7:0] dout;
175
176
177
178
179
180xor2 #(8) d0_0 (
181.in0(din0[7:0]),
182.in1(din1[7:0]),
183.out(dout[7:0])
184);
185
186
187
188
189
190
191
192
193endmodule
194
195
196
197
198
199//
200// invert macro
201//
202//
203
204
205
206
207
208module tlu_eem_dp_inv_macro__stack_8r__width_8 (
209 din,
210 dout);
211 input [7:0] din;
212 output [7:0] dout;
213
214
215
216
217
218
219inv #(8) d0_0 (
220.in(din[7:0]),
221.out(dout[7:0])
222);
223
224
225
226
227
228
229
230
231
232endmodule
233
234
235
236
237
238//
239// invert macro
240//
241//
242
243
244
245
246
247module tlu_eem_dp_inv_macro__stack_8r__width_1 (
248 din,
249 dout);
250 input [0:0] din;
251 output [0:0] dout;
252
253
254
255
256
257
258inv #(1) d0_0 (
259.in(din[0:0]),
260.out(dout[0:0])
261);
262
263
264
265
266
267
268
269
270
271endmodule
272
273
274
275
276
277//
278// nand macro for ports = 2,3,4
279//
280//
281
282
283
284
285
286module tlu_eem_dp_nand_macro__ports_2__stack_8r__width_8 (
287 din0,
288 din1,
289 dout);
290 input [7:0] din0;
291 input [7:0] din1;
292 output [7:0] dout;
293
294
295
296
297
298
299nand2 #(8) d0_0 (
300.in0(din0[7:0]),
301.in1(din1[7:0]),
302.out(dout[7:0])
303);
304
305
306
307
308
309
310
311
312
313endmodule
314
315
316
317