1 /**
2 * @file cpmac_regs.h
3 *
4 * @brief
5 * This file contains the Register Desciptions for EMAC
6 *
7 * \par
8 * NOTE:
9 * (C) Copyright 2008, Texas Instruments, Inc.
10 *
11 * Redistribution and use in source and binary forms, with or without
12 * modification, are permitted provided that the following conditions
13 * are met:
14 *
15 * Redistributions of source code must retain the above copyright
16 * notice, this list of conditions and the following disclaimer.
17 *
18 * Redistributions in binary form must reproduce the above copyright
19 * notice, this list of conditions and the following disclaimer in the
20 * documentation and/or other materials provided with the
21 * distribution.
22 *
23 * Neither the name of Texas Instruments Incorporated nor the names of
24 * its contributors may be used to endorse or promote products derived
25 * from this software without specific prior written permission.
26 *
27 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
28 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
29 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
30 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
31 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
32 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
33 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
34 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
35 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
36 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
37 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
38 *
39 * \par
40 */
42 #ifndef __CPMAC_REGS_H__
43 #define __CPMAC_REGS_H__
45 /**
46 * @brief
47 * The structure describes the CPMAC Register Overlay.
48 *
49 * @details
50 * This is the CPMAC Register overlay data structure which is used
51 * by the CPMAC Driver.
52 */
53 typedef struct CPMAC_REGS
54 {
55 volatile uint32_t TXIDVER;
56 volatile uint32_t TXCONTROL;
57 volatile uint32_t TXTEARDOWN;
58 volatile uint8_t RSVD0[4];
59 volatile uint32_t RXIDVER;
60 volatile uint32_t RXCONTROL;
61 volatile uint32_t RXTEARDOWN;
62 volatile uint8_t RSVD1[100];
63 volatile uint32_t TXINTSTATRAW;
64 volatile uint32_t TXINTSTATMASKED;
65 volatile uint32_t TXINTMASKSET;
66 volatile uint32_t TXINTMASKCLEAR;
67 volatile uint32_t MACINVECTOR;
68 volatile uint8_t RSVD2[12];
69 volatile uint32_t RXINTSTATRAW;
70 volatile uint32_t RXINTSTATMASKED;
71 volatile uint32_t RXINTMASKSET;
72 volatile uint32_t RXINTMASKCLEAR;
73 volatile uint32_t MACINTSTATRAW;
74 volatile uint32_t MACINTSTATMASKED;
75 volatile uint32_t MACINTMASKSET;
76 volatile uint32_t MACINTMASKCLEAR;
77 volatile uint8_t RSVD3[64];
78 volatile uint32_t RXMBPENABLE;
79 volatile uint32_t RXUNICASTSET;
80 volatile uint32_t RXUNICASTCLEAR;
81 volatile uint32_t RXMAXLEN;
82 volatile uint32_t RXBUFFEROFFSET;
83 volatile uint32_t RXFILTERLOWTHRESH;
84 volatile uint8_t RSVD4[8];
85 volatile uint32_t RX0FLOWTHRESH;
86 volatile uint32_t RX1FLOWTHRESH;
87 volatile uint32_t RX2FLOWTHRESH;
88 volatile uint32_t RX3FLOWTHRESH;
89 volatile uint32_t RX4FLOWTHRESH;
90 volatile uint32_t RX5FLOWTHRESH;
91 volatile uint32_t RX6FLOWTHRESH;
92 volatile uint32_t RX7FLOWTHRESH;
93 volatile uint32_t RX0FREEBUFFER;
94 volatile uint32_t RX1FREEBUFFER;
95 volatile uint32_t RX2FREEBUFFER;
96 volatile uint32_t RX3FREEBUFFER;
97 volatile uint32_t RX4FREEBUFFER;
98 volatile uint32_t RX5FREEBUFFER;
99 volatile uint32_t RX6FREEBUFFER;
100 volatile uint32_t RX7FREEBUFFER;
101 volatile uint32_t MACCONTROL;
102 volatile uint32_t MACSTATUS;
103 volatile uint32_t EMCONTROL;
104 volatile uint32_t FIFOCONTROL;
105 volatile uint32_t MACCONFIG;
106 volatile uint32_t SOFTRESET;
107 volatile uint8_t RSVD5[88];
108 volatile uint32_t MACSRCADDRLO;
109 volatile uint32_t MACSRCADDRHI;
110 volatile uint32_t MACHASH1;
111 volatile uint32_t MACHASH2;
112 volatile uint32_t BOFFTEST;
113 volatile uint32_t TPACETEST;
114 volatile uint32_t RXPAUSE;
115 volatile uint32_t TXPAUSE;
116 volatile uint8_t RSVD6[16];
117 volatile uint32_t RXGOODFRAMES;
118 volatile uint32_t RXBCASTFRAMES;
119 volatile uint32_t RXMCASTFRAMES;
120 volatile uint32_t RXPAUSEFRAMES;
121 volatile uint32_t RXCRCERRORS;
122 volatile uint32_t RXALIGNCODEERRORS;
123 volatile uint32_t RXOVERSIZED;
124 volatile uint32_t RXJABBER;
125 volatile uint32_t RXUNDERSIZED;
126 volatile uint32_t RXFRAGMENTS;
127 volatile uint32_t RXFILTERED;
128 volatile uint32_t RXQOSFILTERED;
129 volatile uint32_t RXOCTETS;
130 volatile uint32_t TXGOODFRAMES;
131 volatile uint32_t TXBCASTFRAMES;
132 volatile uint32_t TXMCASTFRAMES;
133 volatile uint32_t TXPAUSEFRAMES;
134 volatile uint32_t TXDEFERRED;
135 volatile uint32_t TXCOLLISION;
136 volatile uint32_t TXSINGLECOLL;
137 volatile uint32_t TXMULTICOLL;
138 volatile uint32_t TXEXCESSIVECOLL;
139 volatile uint32_t TXLATECOLL;
140 volatile uint32_t TXUNDERRUN;
141 volatile uint32_t TXCARRIERSENSE;
142 volatile uint32_t TXOCTETS;
143 volatile uint32_t FRAME64;
144 volatile uint32_t FRAME65T127;
145 volatile uint32_t FRAME128T255;
146 volatile uint32_t FRAME256T511;
147 volatile uint32_t FRAME512T1023;
148 volatile uint32_t FRAME1024TUP;
149 volatile uint32_t NETOCTETS;
150 volatile uint32_t RXSOFOVERRUNS;
151 volatile uint32_t RXMOFOVERRUNS;
152 volatile uint32_t RXDMAOVERRUNS;
153 volatile uint8_t RSVD7[624];
154 volatile uint32_t MACADDRLO;
155 volatile uint32_t MACADDRHI;
156 volatile uint32_t MACINDEX;
157 volatile uint8_t RSVD8[244];
158 volatile uint32_t TX0HDP;
159 volatile uint32_t TX1HDP;
160 volatile uint32_t TX2HDP;
161 volatile uint32_t TX3HDP;
162 volatile uint32_t TX4HDP;
163 volatile uint32_t TX5HDP;
164 volatile uint32_t TX6HDP;
165 volatile uint32_t TX7HDP;
166 volatile uint32_t RX0HDP;
167 volatile uint32_t RX1HDP;
168 volatile uint32_t RX2HDP;
169 volatile uint32_t RX3HDP;
170 volatile uint32_t RX4HDP;
171 volatile uint32_t RX5HDP;
172 volatile uint32_t RX6HDP;
173 volatile uint32_t RX7HDP;
174 volatile uint32_t TX0CP;
175 volatile uint32_t TX1CP;
176 volatile uint32_t TX2CP;
177 volatile uint32_t TX3CP;
178 volatile uint32_t TX4CP;
179 volatile uint32_t TX5CP;
180 volatile uint32_t TX6CP;
181 volatile uint32_t TX7CP;
182 volatile uint32_t RX0CP;
183 volatile uint32_t RX1CP;
184 volatile uint32_t RX2CP;
185 volatile uint32_t RX3CP;
186 volatile uint32_t RX4CP;
187 volatile uint32_t RX5CP;
188 volatile uint32_t RX6CP;
189 volatile uint32_t RX7CP;
190 }CPMAC_REGS;
192 /* MACADDRLO: Bit Mask Definitions. */
193 #define CPMAC_MACADDRLO_VALID (0x00100000u)
194 #define CPMAC_MACADDRLO_MATCHFILT (0x00080000u)
196 /* MACCONTROL: Bit Mask Definitions. */
197 #define CPMAC_MACCONTROL_RXOWNERSHIP (0x00002000u)
198 #define CPMAC_MACCONTROL_RXOFFLENBLOCK (0x00004000u)
199 #define CPMAC_MACCONTROL_MIIEN (0x00000020u)
201 /* RXMBP Enable: Bit Mask Definitions. */
202 #define CPMAC_RXMBPENABLE_RXBROADEN (0x00002000u)
204 #endif /* __CPMAC_REGS_H__ */