OpenCores
URL https://opencores.org/ocsvn/turbo8051/turbo8051/trunk

Subversion Repositories turbo8051

[/] [turbo8051/] [trunk/] [rtl/] [gmac/] [mac/] [g_rx_top.v] - Blame information for rev 37

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 12 dinesha
//////////////////////////////////////////////////////////////////////
2
////                                                              ////
3
////  Tubo 8051 cores MAC Interface Module                        ////
4
////                                                              ////
5
////  This file is part of the Turbo 8051 cores project           ////
6
////  http://www.opencores.org/cores/turbo8051/                   ////
7
////                                                              ////
8
////  Description                                                 ////
9
////  Turbo 8051 definitions.                                     ////
10
////                                                              ////
11
////  To Do:                                                      ////
12
////    nothing                                                   ////
13
////                                                              ////
14
////  Author(s):                                                  ////
15
////      - Dinesh Annayya, dinesha@opencores.org                 ////
16
////                                                              ////
17
//////////////////////////////////////////////////////////////////////
18
////                                                              ////
19
//// Copyright (C) 2000 Authors and OPENCORES.ORG                 ////
20
////                                                              ////
21
//// This source file may be used and distributed without         ////
22
//// restriction provided that this copyright statement is not    ////
23
//// removed from the file and that any derivative work contains  ////
24
//// the original copyright notice and the associated disclaimer. ////
25
////                                                              ////
26
//// This source file is free software; you can redistribute it   ////
27
//// and/or modify it under the terms of the GNU Lesser General   ////
28
//// Public License as published by the Free Software Foundation; ////
29
//// either version 2.1 of the License, or (at your option) any   ////
30
//// later version.                                               ////
31
////                                                              ////
32
//// This source is distributed in the hope that it will be       ////
33
//// useful, but WITHOUT ANY WARRANTY; without even the implied   ////
34
//// warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR      ////
35
//// PURPOSE.  See the GNU Lesser General Public License for more ////
36
//// details.                                                     ////
37
////                                                              ////
38
//// You should have received a copy of the GNU Lesser General    ////
39
//// Public License along with this source; if not, download it   ////
40
//// from http://www.opencores.org/lgpl.shtml                     ////
41
////                                                              ////
42
//////////////////////////////////////////////////////////////////////
43
//`timescale 1ns/100ps
44
 
45
 module g_rx_top(
46
                app_reset_n,
47
                phy_rx_clk,
48
                rx_reset_n,
49
                app_clk,
50
                          scan_mode,
51
                rx_sts_vld,
52
                rx_sts_bytes_rcvd,
53
                rx_sts_large_pkt,
54
                rx_sts_lengthfield_err,
55
                rx_sts_len_mismatch,
56
                rx_sts_crc_err,
57
                rx_sts_runt_pkt_rcvd,
58
                rx_sts_rx_overrun,
59
                rx_sts_frm_length_err,
60
                clr_rx_error_from_rx_fsm,
61
                rx_fifo_full,
62
                rx_dt_wrt,
63
                rx_dt_out,
64
                rx_commit_wr,
65
                commit_write_done,
66
                rx_rewind_wr,
67
                mi2rx_strt_rcv,
68
                mi2rx_rcv_vld,
69
                mi2rx_rx_byte,
70
                mi2rx_end_rcv,
71
                mi2rx_extend,
72
                mi2rx_frame_err,
73
                mi2rx_end_frame,
74
                phy_rx_dv,
75
                cf2rx_max_pkt_sz,
76
                cf2rx_rx_ch_en,
77
                cf2rx_strp_pad_en,
78
                cf2rx_snd_crc,
79
                cf2df_dfl_single_rx,
80
                cf2rx_rcv_runt_pkt_en,
81
                cf_macmode,
82
                mi2rx_crs,
83
                df2rx_dfl_dn,
84
                ap2rx_rx_fifo_err,
85
      //A200 change Port added for crs based flow control
86 37 dinesha
      phy_crs
87 12 dinesha
               );
88
 
89
    input               app_reset_n;
90
    input               phy_rx_clk;
91
    input               rx_reset_n;
92
    input               app_clk;
93
   input        scan_mode;
94
 
95
    output              rx_sts_vld;
96
    output [15:0]       rx_sts_bytes_rcvd;
97
    output              rx_sts_large_pkt;
98
    output              rx_sts_lengthfield_err;
99
    output              rx_sts_len_mismatch;
100
    output              rx_sts_crc_err;
101
    output              rx_sts_runt_pkt_rcvd;
102
    output              rx_sts_rx_overrun;
103
    output              rx_sts_frm_length_err;
104
 
105
    output              clr_rx_error_from_rx_fsm;
106
    input               rx_fifo_full;
107
    output              rx_dt_wrt;
108
    output [8:0] rx_dt_out;
109
    output              rx_commit_wr;
110
    output              commit_write_done;
111
    output              rx_rewind_wr;
112
    input               mi2rx_strt_rcv;
113
    input               mi2rx_rcv_vld;
114
    input [7:0]          mi2rx_rx_byte;
115
    input               mi2rx_end_rcv;
116
    input               mi2rx_extend;
117
    input               mi2rx_frame_err;
118
    input               mi2rx_end_frame;
119
    input               phy_rx_dv;
120
    input [15:0]        cf2rx_max_pkt_sz;
121
    input               cf2rx_rx_ch_en;
122
    input               cf2rx_strp_pad_en;
123
    input               cf2rx_snd_crc;
124
    input               cf2rx_rcv_runt_pkt_en;
125
    input               cf_macmode;
126
    input  [7:0]        cf2df_dfl_single_rx;
127
    input               ap2rx_rx_fifo_err;
128
    input               mi2rx_crs;
129
    output              df2rx_dfl_dn;
130
 
131
    //A200 change Port added for crs based flow control
132
    input            phy_crs;
133
 
134
 
135
 
136
    g_rx_fsm u_rx_fsm(
137
              // Status information to Applications
138
              .rx_sts_vld(rx_sts_vld),
139
              .rx_sts_bytes_rcvd(rx_sts_bytes_rcvd),
140
              .rx_sts_large_pkt(rx_sts_large_pkt),
141
              .rx_sts_lengthfield_err(rx_sts_lengthfield_err),
142
              .rx_sts_len_mismatch(rx_sts_len_mismatch),
143
              .rx_sts_crc_err(rx_sts_crc_err),
144
              .rx_sts_runt_pkt_rcvd(rx_sts_runt_pkt_rcvd),
145
              .rx_sts_rx_overrun(rx_sts_rx_overrun),
146
              .rx_sts_frm_length_err(rx_sts_frm_length_err),
147
              // Data Signals to Fifo Management Block
148
              .clr_rx_error_from_rx_fsm(clr_rx_error_from_rx_fsm),
149
              .rx2ap_rx_fsm_wrt(rx_dt_wrt),
150
              .rx2ap_rx_fsm_dt(rx_dt_out),
151
              // Fifo Control Signal to Fifo Management Block
152
              .rx2ap_commit_write(rx_commit_wr),
153
              .rx2ap_rewind_write(rx_rewind_wr),
154
              // To address filtering block
155
              .commit_write_done(commit_write_done),
156
 
157
              // Global Signals 
158
              .reset_n(rx_reset_n),
159
              .phy_rx_clk(phy_rx_clk),
160
              // Signals from Mii/Rmii block for Receive data 
161
              .mi2rx_strt_rcv(mi2rx_strt_rcv),
162
              .mi2rx_rcv_vld(mi2rx_rcv_vld),
163
              .mi2rx_rx_byte(mi2rx_rx_byte),
164
              .mi2rx_end_rcv(mi2rx_end_rcv),
165
              .mi2rx_extend(mi2rx_extend),
166
              .mi2rx_end_frame(mi2rx_end_frame),
167
              .mi2rx_frame_err(mi2rx_frame_err),
168
              // Rx fifo management signal to indicate overrun
169
              .rx_fifo_full(rx_fifo_full),
170
              .ap2rx_rx_fifo_err(ap2rx_rx_fifo_err),
171
              // Signal from CRC check block
172
              .rc2rx_crc_ok(rc2rx_crc_ok),
173
              // Signals from Address filtering block
174
              // Signals from Config Management Block
175
              .cf2rx_max_pkt_sz(cf2rx_max_pkt_sz),
176
              .cf2rx_rx_ch_en(cf2rx_rx_ch_en),
177
              .cf2rx_strp_pad_en(cf2rx_strp_pad_en),
178
              .cf2rx_snd_crc(cf2rx_snd_crc),
179
              .cf2rx_rcv_runt_pkt_en(cf2rx_rcv_runt_pkt_en),
180
              .cf2rx_gigabit_xfr(cf_macmode),
181
         //A200 change Port added for crs based flow control
182 37 dinesha
         .phy_crs(phy_crs)
183 12 dinesha
              );
184
 
185
 
186
  g_rx_crc32 u_rx_crc32 (
187
              // CRC Valid signal to rx_fsm
188
              .rc2rf_crc_ok(rc2rx_crc_ok),
189
 
190
              // Global Signals
191
              .phy_rx_clk(phy_rx_clk),
192
              .reset_n(rx_reset_n),
193
              // CRC Data signals
194
              .mi2rc_strt_rcv(mi2rx_strt_rcv),
195
              .mi2rc_rcv_valid(mi2rx_rcv_vld),
196
              .mi2rc_rx_byte(mi2rx_rx_byte)
197
              );
198
 
199
 
200
  g_deferral_rx U_deferral_rx (
201
//0503 Changed .port names to match g_deferral_rx
202
            .rx_dfl_dn(df2rx_dfl_dn),
203
            .dfl_single(cf2df_dfl_single_rx),
204
            .rx_dv(phy_rx_dv),
205
//0504      .phy_rx_er(phy_rx_er),
206
            .rx_clk(phy_rx_clk),
207
            .reset_n(rx_reset_n));
208
 
209
  endmodule

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.