Commit | Line | Data |
---|---|---|
86530b38 AT |
1 | // ========== Copyright Header Begin ========================================== |
2 | // | |
3 | // OpenSPARC T2 Processor File: mmu_mem_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 ============================================ | |
35 | module mmu_mem_dp ( | |
36 | asi_error_inject, | |
37 | asi_error_mask, | |
38 | asi_mbist_ecc, | |
39 | asi_mbist_run, | |
40 | parity_in, | |
41 | parity_out); | |
42 | wire mbist_run_; | |
43 | wire pre_error_inject_; | |
44 | wire pre_error_inject; | |
45 | wire error_inject; | |
46 | wire error_inject_; | |
47 | wire parity_in_; | |
48 | wire parity_mux_0; | |
49 | wire parity_mux_1; | |
50 | wire parity_mux_2; | |
51 | ||
52 | ||
53 | ||
54 | input asi_error_inject; | |
55 | input asi_error_mask; | |
56 | ||
57 | input asi_mbist_ecc; | |
58 | input asi_mbist_run; | |
59 | ||
60 | input parity_in; | |
61 | ||
62 | output parity_out; | |
63 | ||
64 | ||
65 | ||
66 | mmu_mem_dp_inv_macro__width_1 mbist_run_b_inv ( | |
67 | .din (asi_mbist_run ), | |
68 | .dout (mbist_run_ ) | |
69 | ); | |
70 | ||
71 | mmu_mem_dp_nand_macro__ports_2__width_1 pre_error_inject_b_nand ( | |
72 | .din0 ({1 {asi_error_inject}} ), | |
73 | .din1 (asi_error_mask ), | |
74 | .dout (pre_error_inject_ ) | |
75 | ); | |
76 | ||
77 | mmu_mem_dp_inv_macro__width_1 pre_error_inject_inv ( | |
78 | .din (pre_error_inject_ ), | |
79 | .dout (pre_error_inject ) | |
80 | ); | |
81 | ||
82 | mmu_mem_dp_and_macro__width_1 error_inject_and ( | |
83 | .din0 (pre_error_inject ), | |
84 | .din1 ({1 {mbist_run_}} ), | |
85 | .dout (error_inject ) | |
86 | ); | |
87 | ||
88 | mmu_mem_dp_and_macro__width_1 error_inject_b_and ( | |
89 | .din0 (pre_error_inject_ ), | |
90 | .din1 ({1 {mbist_run_}} ), | |
91 | .dout (error_inject_ ) | |
92 | ); | |
93 | ||
94 | mmu_mem_dp_inv_macro__width_1 parity_in_b_inv ( | |
95 | .din (parity_in ), | |
96 | .dout (parity_in_ ) | |
97 | ); | |
98 | ||
99 | mmu_mem_dp_nand_macro__ports_2__width_1 parity_mux_0_nand ( | |
100 | .din0 (asi_mbist_ecc ), | |
101 | .din1 (asi_mbist_run ), | |
102 | .dout (parity_mux_0 ) | |
103 | ); | |
104 | ||
105 | mmu_mem_dp_nand_macro__ports_2__width_1 parity_mux_1_nand ( | |
106 | .din0 (parity_in ), | |
107 | .din1 (error_inject_ ), | |
108 | .dout (parity_mux_1 ) | |
109 | ); | |
110 | ||
111 | mmu_mem_dp_nand_macro__ports_2__width_1 parity_mux_2_nand ( | |
112 | .din0 (parity_in_ ), | |
113 | .din1 (error_inject ), | |
114 | .dout (parity_mux_2 ) | |
115 | ); | |
116 | ||
117 | mmu_mem_dp_nand_macro__ports_3__width_1 parity_mux_nand ( | |
118 | .din0 (parity_mux_0 ), | |
119 | .din1 (parity_mux_1 ), | |
120 | .din2 (parity_mux_2 ), | |
121 | .dout (parity_out ) | |
122 | ); | |
123 | ||
124 | ||
125 | ||
126 | ||
127 | supply0 vss; // <- port for ground | |
128 | supply1 vdd; // <- port for power | |
129 | ||
130 | endmodule | |
131 | ||
132 | ||
133 | ||
134 | // | |
135 | // invert macro | |
136 | // | |
137 | // | |
138 | ||
139 | ||
140 | ||
141 | ||
142 | ||
143 | module mmu_mem_dp_inv_macro__width_1 ( | |
144 | din, | |
145 | dout); | |
146 | input [0:0] din; | |
147 | output [0:0] dout; | |
148 | ||
149 | ||
150 | ||
151 | ||
152 | ||
153 | ||
154 | inv #(1) d0_0 ( | |
155 | .in(din[0:0]), | |
156 | .out(dout[0:0]) | |
157 | ); | |
158 | ||
159 | ||
160 | ||
161 | ||
162 | ||
163 | ||
164 | ||
165 | ||
166 | ||
167 | endmodule | |
168 | ||
169 | ||
170 | ||
171 | ||
172 | ||
173 | // | |
174 | // nand macro for ports = 2,3,4 | |
175 | // | |
176 | // | |
177 | ||
178 | ||
179 | ||
180 | ||
181 | ||
182 | module mmu_mem_dp_nand_macro__ports_2__width_1 ( | |
183 | din0, | |
184 | din1, | |
185 | dout); | |
186 | input [0:0] din0; | |
187 | input [0:0] din1; | |
188 | output [0:0] dout; | |
189 | ||
190 | ||
191 | ||
192 | ||
193 | ||
194 | ||
195 | nand2 #(1) d0_0 ( | |
196 | .in0(din0[0:0]), | |
197 | .in1(din1[0:0]), | |
198 | .out(dout[0:0]) | |
199 | ); | |
200 | ||
201 | ||
202 | ||
203 | ||
204 | ||
205 | ||
206 | ||
207 | ||
208 | ||
209 | endmodule | |
210 | ||
211 | ||
212 | ||
213 | ||
214 | ||
215 | // | |
216 | // and macro for ports = 2,3,4 | |
217 | // | |
218 | // | |
219 | ||
220 | ||
221 | ||
222 | ||
223 | ||
224 | module mmu_mem_dp_and_macro__width_1 ( | |
225 | din0, | |
226 | din1, | |
227 | dout); | |
228 | input [0:0] din0; | |
229 | input [0:0] din1; | |
230 | output [0:0] dout; | |
231 | ||
232 | ||
233 | ||
234 | ||
235 | ||
236 | ||
237 | and2 #(1) d0_0 ( | |
238 | .in0(din0[0:0]), | |
239 | .in1(din1[0:0]), | |
240 | .out(dout[0:0]) | |
241 | ); | |
242 | ||
243 | ||
244 | ||
245 | ||
246 | ||
247 | ||
248 | ||
249 | ||
250 | ||
251 | endmodule | |
252 | ||
253 | ||
254 | ||
255 | ||
256 | ||
257 | // | |
258 | // nand macro for ports = 2,3,4 | |
259 | // | |
260 | // | |
261 | ||
262 | ||
263 | ||
264 | ||
265 | ||
266 | module mmu_mem_dp_nand_macro__ports_3__width_1 ( | |
267 | din0, | |
268 | din1, | |
269 | din2, | |
270 | dout); | |
271 | input [0:0] din0; | |
272 | input [0:0] din1; | |
273 | input [0:0] din2; | |
274 | output [0:0] dout; | |
275 | ||
276 | ||
277 | ||
278 | ||
279 | ||
280 | ||
281 | nand3 #(1) d0_0 ( | |
282 | .in0(din0[0:0]), | |
283 | .in1(din1[0:0]), | |
284 | .in2(din2[0:0]), | |
285 | .out(dout[0:0]) | |
286 | ); | |
287 | ||
288 | ||
289 | ||
290 | ||
291 | ||
292 | ||
293 | ||
294 | ||
295 | ||
296 | endmodule | |
297 | ||
298 | ||
299 | ||
300 |