]> nv-tegra.nvidia Code Review - linux-2.6.git/blob - drivers/staging/benet/fwcmd_eth_bmap.h
tracing/ring-buffer: fix non cpu hotplug case
[linux-2.6.git] / drivers / staging / benet / fwcmd_eth_bmap.h
1 /*
2  * Copyright (C) 2005 - 2008 ServerEngines
3  * All rights reserved.
4  *
5  * This program is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU General Public License version 2
7  * as published by the Free Software Foundation.  The full GNU General
8  * Public License is included in this distribution in the file called COPYING.
9  *
10  * Contact Information:
11  * linux-drivers@serverengines.com
12  *
13  * ServerEngines
14  * 209 N. Fair Oaks Ave
15  * Sunnyvale, CA 94085
16  */
17 /*
18  * Autogenerated by srcgen version: 0127
19  */
20 #ifndef __fwcmd_eth_bmap_h__
21 #define __fwcmd_eth_bmap_h__
22 #include "fwcmd_hdr_bmap.h"
23 #include "fwcmd_types_bmap.h"
24
25 struct MIB_ETH_STATISTICS_PARAMS_IN {
26         u32 rsvd0;
27 } __packed;
28
29 struct BE_RXF_STATS {
30         u32 p0recvdtotalbytesLSD;       /* DWORD 0 */
31         u32 p0recvdtotalbytesMSD;       /* DWORD 1 */
32         u32 p0recvdtotalframes; /* DWORD 2 */
33         u32 p0recvdunicastframes;       /* DWORD 3 */
34         u32 p0recvdmulticastframes;     /* DWORD 4 */
35         u32 p0recvdbroadcastframes;     /* DWORD 5 */
36         u32 p0crcerrors;        /* DWORD 6 */
37         u32 p0alignmentsymerrs; /* DWORD 7 */
38         u32 p0pauseframesrecvd; /* DWORD 8 */
39         u32 p0controlframesrecvd;       /* DWORD 9 */
40         u32 p0inrangelenerrors; /* DWORD 10 */
41         u32 p0outrangeerrors;   /* DWORD 11 */
42         u32 p0frametoolongerrors;       /* DWORD 12 */
43         u32 p0droppedaddressmatch;      /* DWORD 13 */
44         u32 p0droppedvlanmismatch;      /* DWORD 14 */
45         u32 p0ipdroppedtoosmall;        /* DWORD 15 */
46         u32 p0ipdroppedtooshort;        /* DWORD 16 */
47         u32 p0ipdroppedhdrtoosmall;     /* DWORD 17 */
48         u32 p0tcpdroppedlen;    /* DWORD 18 */
49         u32 p0droppedrunt;      /* DWORD 19 */
50         u32 p0recvd64;          /* DWORD 20 */
51         u32 p0recvd65_127;      /* DWORD 21 */
52         u32 p0recvd128_256;     /* DWORD 22 */
53         u32 p0recvd256_511;     /* DWORD 23 */
54         u32 p0recvd512_1023;    /* DWORD 24 */
55         u32 p0recvd1518_1522;   /* DWORD 25 */
56         u32 p0recvd1522_2047;   /* DWORD 26 */
57         u32 p0recvd2048_4095;   /* DWORD 27 */
58         u32 p0recvd4096_8191;   /* DWORD 28 */
59         u32 p0recvd8192_9216;   /* DWORD 29 */
60         u32 p0rcvdipcksmerrs;   /* DWORD 30 */
61         u32 p0recvdtcpcksmerrs; /* DWORD 31 */
62         u32 p0recvdudpcksmerrs; /* DWORD 32 */
63         u32 p0recvdnonrsspackets;       /* DWORD 33 */
64         u32 p0recvdippackets;   /* DWORD 34 */
65         u32 p0recvdchute1packets;       /* DWORD 35 */
66         u32 p0recvdchute2packets;       /* DWORD 36 */
67         u32 p0recvdchute3packets;       /* DWORD 37 */
68         u32 p0recvdipsecpackets;        /* DWORD 38 */
69         u32 p0recvdmanagementpackets;   /* DWORD 39 */
70         u32 p0xmitbyteslsd;     /* DWORD 40 */
71         u32 p0xmitbytesmsd;     /* DWORD 41 */
72         u32 p0xmitunicastframes;        /* DWORD 42 */
73         u32 p0xmitmulticastframes;      /* DWORD 43 */
74         u32 p0xmitbroadcastframes;      /* DWORD 44 */
75         u32 p0xmitpauseframes;  /* DWORD 45 */
76         u32 p0xmitcontrolframes;        /* DWORD 46 */
77         u32 p0xmit64;           /* DWORD 47 */
78         u32 p0xmit65_127;       /* DWORD 48 */
79         u32 p0xmit128_256;      /* DWORD 49 */
80         u32 p0xmit256_511;      /* DWORD 50 */
81         u32 p0xmit512_1023;     /* DWORD 51 */
82         u32 p0xmit1518_1522;    /* DWORD 52 */
83         u32 p0xmit1522_2047;    /* DWORD 53 */
84         u32 p0xmit2048_4095;    /* DWORD 54 */
85         u32 p0xmit4096_8191;    /* DWORD 55 */
86         u32 p0xmit8192_9216;    /* DWORD 56 */
87         u32 p0rxfifooverflowdropped;    /* DWORD 57 */
88         u32 p0ipseclookupfaileddropped; /* DWORD 58 */
89         u32 p1recvdtotalbytesLSD;       /* DWORD 59 */
90         u32 p1recvdtotalbytesMSD;       /* DWORD 60 */
91         u32 p1recvdtotalframes; /* DWORD 61 */
92         u32 p1recvdunicastframes;       /* DWORD 62 */
93         u32 p1recvdmulticastframes;     /* DWORD 63 */
94         u32 p1recvdbroadcastframes;     /* DWORD 64 */
95         u32 p1crcerrors;        /* DWORD 65 */
96         u32 p1alignmentsymerrs; /* DWORD 66 */
97         u32 p1pauseframesrecvd; /* DWORD 67 */
98         u32 p1controlframesrecvd;       /* DWORD 68 */
99         u32 p1inrangelenerrors; /* DWORD 69 */
100         u32 p1outrangeerrors;   /* DWORD 70 */
101         u32 p1frametoolongerrors;       /* DWORD 71 */
102         u32 p1droppedaddressmatch;      /* DWORD 72 */
103         u32 p1droppedvlanmismatch;      /* DWORD 73 */
104         u32 p1ipdroppedtoosmall;        /* DWORD 74 */
105         u32 p1ipdroppedtooshort;        /* DWORD 75 */
106         u32 p1ipdroppedhdrtoosmall;     /* DWORD 76 */
107         u32 p1tcpdroppedlen;    /* DWORD 77 */
108         u32 p1droppedrunt;      /* DWORD 78 */
109         u32 p1recvd64;          /* DWORD 79 */
110         u32 p1recvd65_127;      /* DWORD 80 */
111         u32 p1recvd128_256;     /* DWORD 81 */
112         u32 p1recvd256_511;     /* DWORD 82 */
113         u32 p1recvd512_1023;    /* DWORD 83 */
114         u32 p1recvd1518_1522;   /* DWORD 84 */
115         u32 p1recvd1522_2047;   /* DWORD 85 */
116         u32 p1recvd2048_4095;   /* DWORD 86 */
117         u32 p1recvd4096_8191;   /* DWORD 87 */
118         u32 p1recvd8192_9216;   /* DWORD 88 */
119         u32 p1rcvdipcksmerrs;   /* DWORD 89 */
120         u32 p1recvdtcpcksmerrs; /* DWORD 90 */
121         u32 p1recvdudpcksmerrs; /* DWORD 91 */
122         u32 p1recvdnonrsspackets;       /* DWORD 92 */
123         u32 p1recvdippackets;   /* DWORD 93 */
124         u32 p1recvdchute1packets;       /* DWORD 94 */
125         u32 p1recvdchute2packets;       /* DWORD 95 */
126         u32 p1recvdchute3packets;       /* DWORD 96 */
127         u32 p1recvdipsecpackets;        /* DWORD 97 */
128         u32 p1recvdmanagementpackets;   /* DWORD 98 */
129         u32 p1xmitbyteslsd;     /* DWORD 99 */
130         u32 p1xmitbytesmsd;     /* DWORD 100 */
131         u32 p1xmitunicastframes;        /* DWORD 101 */
132         u32 p1xmitmulticastframes;      /* DWORD 102 */
133         u32 p1xmitbroadcastframes;      /* DWORD 103 */
134         u32 p1xmitpauseframes;  /* DWORD 104 */
135         u32 p1xmitcontrolframes;        /* DWORD 105 */
136         u32 p1xmit64;           /* DWORD 106 */
137         u32 p1xmit65_127;       /* DWORD 107 */
138         u32 p1xmit128_256;      /* DWORD 108 */
139         u32 p1xmit256_511;      /* DWORD 109 */
140         u32 p1xmit512_1023;     /* DWORD 110 */
141         u32 p1xmit1518_1522;    /* DWORD 111 */
142         u32 p1xmit1522_2047;    /* DWORD 112 */
143         u32 p1xmit2048_4095;    /* DWORD 113 */
144         u32 p1xmit4096_8191;    /* DWORD 114 */
145         u32 p1xmit8192_9216;    /* DWORD 115 */
146         u32 p1rxfifooverflowdropped;    /* DWORD 116 */
147         u32 p1ipseclookupfaileddropped; /* DWORD 117 */
148         u32 pxdroppednopbuf;    /* DWORD 118 */
149         u32 pxdroppednotxpb;    /* DWORD 119 */
150         u32 pxdroppednoipsecbuf;        /* DWORD 120 */
151         u32 pxdroppednoerxdescr;        /* DWORD 121 */
152         u32 pxdroppednotpredescr;       /* DWORD 122 */
153         u32 pxrecvdmanagementportpackets;       /* DWORD 123 */
154         u32 pxrecvdmanagementportbytes; /* DWORD 124 */
155         u32 pxrecvdmanagementportpauseframes;   /* DWORD 125 */
156         u32 pxrecvdmanagementporterrors;        /* DWORD 126 */
157         u32 pxxmitmanagementportpackets;        /* DWORD 127 */
158         u32 pxxmitmanagementportbytes;  /* DWORD 128 */
159         u32 pxxmitmanagementportpause;  /* DWORD 129 */
160         u32 pxxmitmanagementportrxfifooverflow; /* DWORD 130 */
161         u32 pxrecvdipsecipcksmerrs;     /* DWORD 131 */
162         u32 pxrecvdtcpsecipcksmerrs;    /* DWORD 132 */
163         u32 pxrecvdudpsecipcksmerrs;    /* DWORD 133 */
164         u32 pxipsecrunt;        /* DWORD 134 */
165         u32 pxipsecaddressmismatchdropped;      /* DWORD 135 */
166         u32 pxipsecrxfifooverflowdropped;       /* DWORD 136 */
167         u32 pxipsecframestoolong;       /* DWORD 137 */
168         u32 pxipsectotalipframes;       /* DWORD 138 */
169         u32 pxipseciptoosmall;  /* DWORD 139 */
170         u32 pxipseciptooshort;  /* DWORD 140 */
171         u32 pxipseciphdrtoosmall;       /* DWORD 141 */
172         u32 pxipsectcphdrbad;   /* DWORD 142 */
173         u32 pxrecvdipsecchute1; /* DWORD 143 */
174         u32 pxrecvdipsecchute2; /* DWORD 144 */
175         u32 pxrecvdipsecchute3; /* DWORD 145 */
176         u32 pxdropped7frags;    /* DWORD 146 */
177         u32 pxdroppedfrags;     /* DWORD 147 */
178         u32 pxdroppedinvalidfragring;   /* DWORD 148 */
179         u32 pxnumforwardedpackets;      /* DWORD 149 */
180 } __packed;
181
182 union MIB_ETH_STATISTICS_PARAMS {
183         struct MIB_ETH_STATISTICS_PARAMS_IN request;
184         struct BE_RXF_STATS response;
185 } __packed;
186
187 /*
188  *  Query ethernet statistics. All domains may issue this command. The
189  *  host domain drivers  may optionally reset internal statistic counters
190  *  with a query.
191  */
192 struct FWCMD_ETH_GET_STATISTICS {
193         union FWCMD_HEADER header;
194         union MIB_ETH_STATISTICS_PARAMS params;
195 } __packed;
196
197
198 struct FWCMD_ETH_ANON_175_REQUEST {
199         u8 port0_promiscuous;
200         u8 port1_promiscuous;
201         u16 rsvd0;
202 } __packed;
203
204 struct FWCMD_ETH_ANON_176_RESPONSE {
205         u32 rsvd0;
206 } __packed;
207
208 union FWCMD_ETH_ANON_174_PARAMS {
209         struct FWCMD_ETH_ANON_175_REQUEST request;
210         struct FWCMD_ETH_ANON_176_RESPONSE response;
211 } __packed;
212
213 /* Enables/Disables promiscuous ethernet receive mode.  */
214 struct FWCMD_ETH_PROMISCUOUS {
215         union FWCMD_HEADER header;
216         union FWCMD_ETH_ANON_174_PARAMS params;
217 } __packed;
218
219 struct FWCMD_ETH_ANON_178_REQUEST {
220         u32 new_fragsize_log2;
221 } __packed;
222
223 struct FWCMD_ETH_ANON_179_RESPONSE {
224         u32 actual_fragsize_log2;
225 } __packed;
226
227 union FWCMD_ETH_ANON_177_PARAMS {
228         struct FWCMD_ETH_ANON_178_REQUEST request;
229         struct FWCMD_ETH_ANON_179_RESPONSE response;
230 } __packed;
231
232 /*
233  *  Sets the Ethernet RX fragment size. Only host (domain 0) networking
234  *  drivers may issue  this command.  This call will fail for non-host
235  *  protection domains. In this situation the  MCC CQ status will indicate
236  *  a failure due to insufficient priviledges. The response  should be
237  *  ignored, and the driver should use the FWCMD_ETH_GET_FRAG_SIZE to
238  *  query the  existing ethernet receive fragment size. It must use this
239  *  fragment size for all  fragments in the ethernet receive ring.  If
240  *  the command succeeds, the driver must use the  frag size indicated
241  *  in the command response since the requested frag size may not be  applied
242  *  until the next reboot. When the requested fragsize matches the response
243  *   fragsize, this indicates the request was applied immediately.
244  */
245 struct FWCMD_ETH_SET_RX_FRAG_SIZE {
246         union FWCMD_HEADER header;
247         union FWCMD_ETH_ANON_177_PARAMS params;
248 } __packed;
249
250 struct FWCMD_ETH_ANON_181_REQUEST {
251         u32 rsvd0;
252 } __packed;
253
254 struct FWCMD_ETH_ANON_182_RESPONSE {
255         u32 actual_fragsize_log2;
256 } __packed;
257
258 union FWCMD_ETH_ANON_180_PARAMS {
259         struct FWCMD_ETH_ANON_181_REQUEST request;
260         struct FWCMD_ETH_ANON_182_RESPONSE response;
261 } __packed;
262
263 /*
264  *  Queries the Ethernet RX fragment size. All domains may issue this
265  *  command.  The driver  should call this command to determine the minimum
266  *  required fragment size for the ethernet  RX ring buffers. Drivers
267  *  may choose to use a larger size for each fragment buffer, but  BladeEngine
268  *  will use up to the configured minimum required fragsize in each ethernet
269  *   receive fragment buffer. For example, if the ethernet receive fragment
270  *  size is  configured to 4kB, and a driver uses 8kB fragments, a 6kB
271  *  ethernet packet received by  BladeEngine will be split accross two
272  *  of the driver's receive framgents (4kB in one  fragment buffer, and
273  *  2kB in the subsequent fragment buffer).
274  */
275 struct FWCMD_ETH_GET_RX_FRAG_SIZE {
276         union FWCMD_HEADER header;
277         union FWCMD_ETH_ANON_180_PARAMS params;
278 } __packed;
279
280 #endif /* __fwcmd_eth_bmap_h__ */