Commit | Line | Data |
---|---|---|
86530b38 AT |
1 | // ========== Copyright Header Begin ========================================== |
2 | // | |
3 | // OpenSPARC T2 Processor File: niu_smx_rdreq_dmc.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 | ||
36 | module niu_smx_rdreq_dmc( | |
37 | /*AUTOARG*/ | |
38 | // Outputs | |
39 | meta_dmc1_req_accept, rdreq_cmdff_wr, rdreq_cmdff_wdata, | |
40 | rdreq_xtb_wr, rdreq_xtb_waddr, rdreq_xtb_wdata, rdreq_cmdreq_idle, | |
41 | rdreq_cmd_cs, | |
42 | // Inputs | |
43 | clk, reset_l, dmc_meta1_req, dmc_meta1_req_cmd, | |
44 | dmc_meta1_req_address, dmc_meta1_req_length, | |
45 | dmc_meta1_req_transID, dmc_meta1_req_port_num, | |
46 | dmc_meta1_req_dma_num, dmc_meta1_req_client, rdreq_cmdff_full, | |
47 | rdreq_rst_xtb_wr, stall_enable, tid_valid_rdata_bus | |
48 | ); | |
49 | ||
50 | input clk; | |
51 | input reset_l; | |
52 | ||
53 | input dmc_meta1_req; | |
54 | input [7:0] dmc_meta1_req_cmd; | |
55 | input [63:0] dmc_meta1_req_address; | |
56 | input [13:0] dmc_meta1_req_length; | |
57 | input [5:0] dmc_meta1_req_transID; | |
58 | input [1:0] dmc_meta1_req_port_num; | |
59 | input [4:0] dmc_meta1_req_dma_num; | |
60 | input [7:0] dmc_meta1_req_client; | |
61 | output meta_dmc1_req_accept; | |
62 | ||
63 | // cmd ff | |
64 | output rdreq_cmdff_wr; | |
65 | output [65:0] rdreq_cmdff_wdata; | |
66 | input rdreq_cmdff_full; | |
67 | ||
68 | // xtb | |
69 | output rdreq_xtb_wr; | |
70 | output [5:0] rdreq_xtb_waddr; | |
71 | output [127:0] rdreq_xtb_wdata; | |
72 | input rdreq_rst_xtb_wr; | |
73 | ||
74 | // stall_hdlr if | |
75 | input stall_enable; | |
76 | output rdreq_cmdreq_idle; | |
77 | ||
78 | output [2:0] rdreq_cmd_cs; | |
79 | ||
80 | // status | |
81 | // added 121405 | |
82 | input [63:0] tid_valid_rdata_bus; | |
83 | ||
84 | wire [2:0] cmd_cs; | |
85 | wire [2:0] rdreq_cmd_cs= cmd_cs; | |
86 | ||
87 | // req input | |
88 | wire dmc_smx_req= dmc_meta1_req; | |
89 | wire [7:0] dmc_smx_req_cmd= dmc_meta1_req_cmd; | |
90 | wire [63:0] dmc_smx_req_addr= dmc_meta1_req_address; | |
91 | wire [13:0] dmc_smx_req_len= dmc_meta1_req_length; | |
92 | wire [5:0] dmc_smx_req_xid= dmc_meta1_req_transID; | |
93 | wire [1:0] dmc_smx_req_port= dmc_meta1_req_port_num; | |
94 | wire [4:0] dmc_smx_req_dma= dmc_meta1_req_dma_num; | |
95 | wire [7:0] dmc_smx_req_client= dmc_meta1_req_client; | |
96 | // req output | |
97 | wire smx_dmc_req_accept; | |
98 | wire meta_dmc1_req_accept= smx_dmc_req_accept; | |
99 | ||
100 | ||
101 | niu_smx_sm_req_cmdreq rd_sm_cmd( | |
102 | .clk (clk), | |
103 | .reset_l (reset_l), | |
104 | .req (dmc_smx_req), | |
105 | .req_cmd (dmc_smx_req_cmd[7:0]), | |
106 | .req_addr (dmc_smx_req_addr[63:0]), | |
107 | .req_len (dmc_smx_req_len[13:0]), | |
108 | .req_xid (dmc_smx_req_xid[5:0]), | |
109 | .req_port (dmc_smx_req_port[1:0]), | |
110 | .req_dma (dmc_smx_req_dma[4:0]), | |
111 | .req_client (dmc_smx_req_client[7:0]), | |
112 | .ack (smx_dmc_req_accept), | |
113 | .cmdflag (), // nc | |
114 | .cmdflag_data (), // nc | |
115 | .early_cmdflag_n (), // nc | |
116 | .early_cmdflag_data_n (), // nc | |
117 | .rst_cmdflag (1'b0), | |
118 | .cfg_no_cmdflag (1'b1), // disable cmdflag gen | |
119 | .cfg_no_sameclientck (1'b1), // disable same client check; | |
120 | // rd can switch over immediately | |
121 | .datareq_idle (1'b0), | |
122 | .xtb_wr (rdreq_xtb_wr), | |
123 | .xtb_waddr (rdreq_xtb_waddr[5:0]), | |
124 | .xtb_wdata (rdreq_xtb_wdata[127:0]), | |
125 | .rst_xtb_wr (rdreq_rst_xtb_wr), | |
126 | .ff_wr (rdreq_cmdff_wr), | |
127 | .ff_wdata (rdreq_cmdff_wdata[65:0]), | |
128 | .ff_full (rdreq_cmdff_full), | |
129 | .lnen_ff_wr (), // nc | |
130 | .lnen_ff_wdata (), // nc | |
131 | .lnen_ff_full (1'b0), | |
132 | ||
133 | .stall_enable (stall_enable), | |
134 | .cmdreq_idle (rdreq_cmdreq_idle), | |
135 | ||
136 | .cmd_cs (cmd_cs [2:0]), | |
137 | ||
138 | .tid_valid_rdata_bus (tid_valid_rdata_bus[63:0]), | |
139 | ||
140 | .xfer_done (1'b1) | |
141 | ); | |
142 | ||
143 | endmodule | |
144 | ||
145 |