1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36#ifndef MPI_LAN_H
37#define MPI_LAN_H
38
39
40
41
42
43
44
45
46
47
48typedef struct _MSG_LAN_SEND_REQUEST
49{
50 U16 Reserved;
51 U8 ChainOffset;
52 U8 Function;
53 U16 Reserved2;
54 U8 PortNumber;
55 U8 MsgFlags;
56 U32 MsgContext;
57 SGE_MPI_UNION SG_List[1];
58} MSG_LAN_SEND_REQUEST, MPI_POINTER PTR_MSG_LAN_SEND_REQUEST,
59 LANSendRequest_t, MPI_POINTER pLANSendRequest_t;
60
61
62typedef struct _MSG_LAN_SEND_REPLY
63{
64 U16 Reserved;
65 U8 MsgLength;
66 U8 Function;
67 U8 Reserved2;
68 U8 NumberOfContexts;
69 U8 PortNumber;
70 U8 MsgFlags;
71 U32 MsgContext;
72 U16 Reserved3;
73 U16 IOCStatus;
74 U32 IOCLogInfo;
75 U32 BufferContext;
76} MSG_LAN_SEND_REPLY, MPI_POINTER PTR_MSG_LAN_SEND_REPLY,
77 LANSendReply_t, MPI_POINTER pLANSendReply_t;
78
79
80
81
82typedef struct _MSG_LAN_RECEIVE_POST_REQUEST
83{
84 U16 Reserved;
85 U8 ChainOffset;
86 U8 Function;
87 U16 Reserved2;
88 U8 PortNumber;
89 U8 MsgFlags;
90 U32 MsgContext;
91 U32 BucketCount;
92 SGE_MPI_UNION SG_List[1];
93} MSG_LAN_RECEIVE_POST_REQUEST, MPI_POINTER PTR_MSG_LAN_RECEIVE_POST_REQUEST,
94 LANReceivePostRequest_t, MPI_POINTER pLANReceivePostRequest_t;
95
96
97typedef struct _MSG_LAN_RECEIVE_POST_REPLY
98{
99 U16 Reserved;
100 U8 MsgLength;
101 U8 Function;
102 U8 Reserved2;
103 U8 NumberOfContexts;
104 U8 PortNumber;
105 U8 MsgFlags;
106 U32 MsgContext;
107 U16 Reserved3;
108 U16 IOCStatus;
109 U32 IOCLogInfo;
110 U32 BucketsRemaining;
111 U32 PacketOffset;
112 U32 PacketLength;
113 U32 BucketContext[1];
114} MSG_LAN_RECEIVE_POST_REPLY, MPI_POINTER PTR_MSG_LAN_RECEIVE_POST_REPLY,
115 LANReceivePostReply_t, MPI_POINTER pLANReceivePostReply_t;
116
117
118
119
120typedef struct _MSG_LAN_RESET_REQUEST
121{
122 U16 Reserved;
123 U8 ChainOffset;
124 U8 Function;
125 U16 Reserved2;
126 U8 PortNumber;
127 U8 MsgFlags;
128 U32 MsgContext;
129} MSG_LAN_RESET_REQUEST, MPI_POINTER PTR_MSG_LAN_RESET_REQUEST,
130 LANResetRequest_t, MPI_POINTER pLANResetRequest_t;
131
132
133typedef struct _MSG_LAN_RESET_REPLY
134{
135 U16 Reserved;
136 U8 MsgLength;
137 U8 Function;
138 U16 Reserved2;
139 U8 PortNumber;
140 U8 MsgFlags;
141 U32 MsgContext;
142 U16 Reserved3;
143 U16 IOCStatus;
144 U32 IOCLogInfo;
145} MSG_LAN_RESET_REPLY, MPI_POINTER PTR_MSG_LAN_RESET_REPLY,
146 LANResetReply_t, MPI_POINTER pLANResetReply_t;
147
148
149
150
151
152
153#define LAN_REPLY_PACKET_LENGTH_MASK (0x0000FFFF)
154#define LAN_REPLY_PACKET_LENGTH_SHIFT (0)
155#define LAN_REPLY_BUCKET_CONTEXT_MASK (0x07FF0000)
156#define LAN_REPLY_BUCKET_CONTEXT_SHIFT (16)
157#define LAN_REPLY_BUFFER_CONTEXT_MASK (0x07FFFFFF)
158#define LAN_REPLY_BUFFER_CONTEXT_SHIFT (0)
159#define LAN_REPLY_FORM_MASK (0x18000000)
160#define LAN_REPLY_FORM_RECEIVE_SINGLE (0x00)
161#define LAN_REPLY_FORM_RECEIVE_MULTIPLE (0x01)
162#define LAN_REPLY_FORM_SEND_SINGLE (0x02)
163#define LAN_REPLY_FORM_MESSAGE_CONTEXT (0x03)
164#define LAN_REPLY_FORM_SHIFT (27)
165
166#define GET_LAN_PACKET_LENGTH(x) (((x) & LAN_REPLY_PACKET_LENGTH_MASK) \
167 >> LAN_REPLY_PACKET_LENGTH_SHIFT)
168
169#define SET_LAN_PACKET_LENGTH(x, lth) \
170 ((x) = ((x) & ~LAN_REPLY_PACKET_LENGTH_MASK) | \
171 (((lth) << LAN_REPLY_PACKET_LENGTH_SHIFT) & \
172 LAN_REPLY_PACKET_LENGTH_MASK))
173
174#define GET_LAN_BUCKET_CONTEXT(x) (((x) & LAN_REPLY_BUCKET_CONTEXT_MASK) \
175 >> LAN_REPLY_BUCKET_CONTEXT_SHIFT)
176
177#define SET_LAN_BUCKET_CONTEXT(x, ctx) \
178 ((x) = ((x) & ~LAN_REPLY_BUCKET_CONTEXT_MASK) | \
179 (((ctx) << LAN_REPLY_BUCKET_CONTEXT_SHIFT) & \
180 LAN_REPLY_BUCKET_CONTEXT_MASK))
181
182#define GET_LAN_BUFFER_CONTEXT(x) (((x) & LAN_REPLY_BUFFER_CONTEXT_MASK) \
183 >> LAN_REPLY_BUFFER_CONTEXT_SHIFT)
184
185#define SET_LAN_BUFFER_CONTEXT(x, ctx) \
186 ((x) = ((x) & ~LAN_REPLY_BUFFER_CONTEXT_MASK) | \
187 (((ctx) << LAN_REPLY_BUFFER_CONTEXT_SHIFT) & \
188 LAN_REPLY_BUFFER_CONTEXT_MASK))
189
190#define GET_LAN_FORM(x) (((x) & LAN_REPLY_FORM_MASK) \
191 >> LAN_REPLY_FORM_SHIFT)
192
193#define SET_LAN_FORM(x, frm) \
194 ((x) = ((x) & ~LAN_REPLY_FORM_MASK) | \
195 (((frm) << LAN_REPLY_FORM_SHIFT) & \
196 LAN_REPLY_FORM_MASK))
197
198
199
200
201
202
203#define MPI_LAN_DEVICE_STATE_RESET (0x00)
204#define MPI_LAN_DEVICE_STATE_OPERATIONAL (0x01)
205
206
207
208
209
210
211#define MPI_LAN_TX_MODES_ENABLE_LOOPBACK_SUPPRESSION (0x01)
212
213#endif
214
215