]> git.proxmox.com Git - mirror_edk2.git/blame - NetworkPkg/Dhcp6Dxe/Dhcp6Impl.h
NetworkPkg: Clean up source files
[mirror_edk2.git] / NetworkPkg / Dhcp6Dxe / Dhcp6Impl.h
CommitLineData
a3bcde70
HT
1/** @file\r
2 Dhcp6 internal data structure and definition declaration.\r
3\r
f75a7f56 4 Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>\r
a3bcde70
HT
5\r
6 This program and the accompanying materials\r
7 are licensed and made available under the terms and conditions of the BSD License\r
8 which accompanies this distribution. The full text of the license may be found at\r
9 http://opensource.org/licenses/bsd-license.php.\r
10\r
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
13\r
14**/\r
15\r
16#ifndef __EFI_DHCP6_IMPL_H__\r
17#define __EFI_DHCP6_IMPL_H__\r
18\r
19\r
20#include <Uefi.h>\r
21\r
142c00c3
ZL
22#include <IndustryStandard/Dhcp.h>\r
23\r
a3bcde70
HT
24#include <Protocol/Dhcp6.h>\r
25#include <Protocol/Udp6.h>\r
cc658224 26#include <Protocol/Ip6Config.h>\r
a3bcde70
HT
27#include <Protocol/ServiceBinding.h>\r
28#include <Protocol/DriverBinding.h>\r
29\r
30#include <Library/UdpIoLib.h>\r
31#include <Library/DebugLib.h>\r
32#include <Library/BaseMemoryLib.h>\r
33#include <Library/MemoryAllocationLib.h>\r
34#include <Library/UefiBootServicesTableLib.h>\r
35#include <Library/UefiRuntimeServicesTableLib.h>\r
36#include <Library/UefiLib.h>\r
37#include <Library/BaseLib.h>\r
38#include <Library/NetLib.h>\r
216f7970 39#include <Library/PrintLib.h>\r
03f9cc20 40#include <Guid/ZeroGuid.h>\r
a3bcde70
HT
41\r
42\r
43typedef struct _DHCP6_IA_CB DHCP6_IA_CB;\r
44typedef struct _DHCP6_INF_CB DHCP6_INF_CB;\r
45typedef struct _DHCP6_TX_CB DHCP6_TX_CB;\r
46typedef struct _DHCP6_SERVICE DHCP6_SERVICE;\r
47typedef struct _DHCP6_INSTANCE DHCP6_INSTANCE;\r
48\r
49#include "Dhcp6Utility.h"\r
50#include "Dhcp6Io.h"\r
51#include "Dhcp6Driver.h"\r
52\r
53#define DHCP6_SERVICE_SIGNATURE SIGNATURE_32 ('D', 'H', '6', 'S')\r
54#define DHCP6_INSTANCE_SIGNATURE SIGNATURE_32 ('D', 'H', '6', 'I')\r
55\r
a3bcde70
HT
56#define DHCP6_PACKET_ALL 0\r
57#define DHCP6_PACKET_STATEFUL 1\r
58#define DHCP6_PACKET_STATELESS 2\r
59\r
60#define DHCP6_BASE_PACKET_SIZE 1024\r
61\r
62#define DHCP6_PORT_CLIENT 546\r
63#define DHCP6_PORT_SERVER 547\r
64\r
152f2d5e 65#define DHCP_CHECK_MEDIA_WAITING_TIME EFI_TIMER_PERIOD_SECONDS(20)\r
66\r
a3bcde70
HT
67#define DHCP6_INSTANCE_FROM_THIS(Instance) CR ((Instance), DHCP6_INSTANCE, Dhcp6, DHCP6_INSTANCE_SIGNATURE)\r
68#define DHCP6_SERVICE_FROM_THIS(Service) CR ((Service), DHCP6_SERVICE, ServiceBinding, DHCP6_SERVICE_SIGNATURE)\r
69\r
70extern EFI_IPv6_ADDRESS mAllDhcpRelayAndServersAddress;\r
71extern EFI_IPv6_ADDRESS mAllDhcpServersAddress;\r
72extern EFI_DHCP6_PROTOCOL gDhcp6ProtocolTemplate;\r
73\r
a3bcde70
HT
74//\r
75// Control block for each IA.\r
76//\r
77struct _DHCP6_IA_CB {\r
78 EFI_DHCP6_IA *Ia;\r
79 UINT32 T1;\r
80 UINT32 T2;\r
81 UINT32 AllExpireTime;\r
82 UINT32 LeaseTime;\r
83};\r
84\r
85//\r
86// Control block for each transmitted message.\r
87//\r
88struct _DHCP6_TX_CB {\r
89 LIST_ENTRY Link;\r
90 UINT32 Xid;\r
91 EFI_DHCP6_PACKET *TxPacket;\r
92 EFI_DHCP6_RETRANSMISSION RetryCtl;\r
93 UINT32 RetryCnt;\r
94 UINT32 RetryExp;\r
95 UINT32 RetryLos;\r
96 UINT32 TickTime;\r
97 UINT16 *Elapsed;\r
129b8b09 98 BOOLEAN SolicitRetry;\r
a3bcde70
HT
99};\r
100\r
101//\r
102// Control block for each info-request message.\r
103//\r
104struct _DHCP6_INF_CB {\r
105 LIST_ENTRY Link;\r
106 UINT32 Xid;\r
107 EFI_DHCP6_INFO_CALLBACK ReplyCallback;\r
108 VOID *CallbackContext;\r
109 EFI_EVENT TimeoutEvent;\r
110};\r
111\r
112//\r
113// Control block for Dhcp6 instance, it's per configuration data.\r
114//\r
115struct _DHCP6_INSTANCE {\r
116 UINT32 Signature;\r
117 EFI_HANDLE Handle;\r
118 DHCP6_SERVICE *Service;\r
119 LIST_ENTRY Link;\r
120 EFI_DHCP6_PROTOCOL Dhcp6;\r
121 EFI_EVENT Timer;\r
122 EFI_DHCP6_CONFIG_DATA *Config;\r
123 EFI_DHCP6_IA *CacheIa;\r
124 DHCP6_IA_CB IaCb;\r
125 LIST_ENTRY TxList;\r
126 LIST_ENTRY InfList;\r
127 EFI_DHCP6_PACKET *AdSelect;\r
128 UINT8 AdPref;\r
129 EFI_IPv6_ADDRESS *Unicast;\r
216f7970 130 volatile EFI_STATUS UdpSts;\r
75dce340 131 BOOLEAN InDestroy;\r
a3bcde70 132 BOOLEAN MediaPresent;\r
685e44a5 133 //\r
134 // StartTime is used to calculate the 'elapsed-time' option. Refer to RFC3315,\r
f75a7f56 135 // the elapsed-time is amount of time since the client began its current DHCP transaction.\r
685e44a5 136 //\r
a3bcde70
HT
137 UINT64 StartTime;\r
138};\r
139\r
140//\r
141// Control block for Dhcp6 service, it's per Nic handle.\r
142//\r
143struct _DHCP6_SERVICE {\r
144 UINT32 Signature;\r
145 EFI_HANDLE Controller;\r
146 EFI_HANDLE Image;\r
147 EFI_SERVICE_BINDING_PROTOCOL ServiceBinding;\r
148 EFI_SIMPLE_NETWORK_PROTOCOL *Snp;\r
cc658224 149 EFI_IP6_CONFIG_PROTOCOL *Ip6Cfg;\r
a3bcde70
HT
150 EFI_DHCP6_DUID *ClientId;\r
151 UDP_IO *UdpIo;\r
152 UINT32 Xid;\r
153 LIST_ENTRY Child;\r
154 UINTN NumOfChild;\r
a3bcde70
HT
155};\r
156\r
157/**\r
158 Starts the DHCPv6 standard S.A.R.R. process.\r
159\r
160 The Start() function starts the DHCPv6 standard process. This function can\r
161 be called only when the state of Dhcp6 instance is in the Dhcp6Init state.\r
162 If the DHCP process completes successfully, the state of the Dhcp6 instance\r
163 will be transferred through Dhcp6Selecting and Dhcp6Requesting to the\r
164 Dhcp6Bound state.\r
165 Refer to rfc-3315 for precise state transitions during this process. At the\r
166 time when each event occurs in this process, the callback function that was set\r
167 by EFI_DHCP6_PROTOCOL.Configure() will be called and the user can take this\r
168 opportunity to control the process.\r
169\r
170 @param[in] This The pointer to Dhcp6 protocol.\r
171\r
172 @retval EFI_SUCCESS The DHCPv6 standard process has started, or it\r
173 completed when CompletionEvent was NULL.\r
174 @retval EFI_ACCESS_DENIED The EFI DHCPv6 Child instance hasn't been configured.\r
175 @retval EFI_INVALID_PARAMETER This is NULL.\r
176 @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
177 @retval EFI_TIMEOUT The DHCPv6 configuration process failed because no\r
178 response was received from the server within the\r
179 specified timeout value.\r
180 @retval EFI_ABORTED The user aborted the DHCPv6 process.\r
181 @retval EFI_ALREADY_STARTED Some other Dhcp6 instance already started the DHCPv6\r
182 standard process.\r
183 @retval EFI_DEVICE_ERROR An unexpected system or network error occurred.\r
184\r
185**/\r
186EFI_STATUS\r
187EFIAPI\r
188EfiDhcp6Start (\r
189 IN EFI_DHCP6_PROTOCOL *This\r
190 );\r
191\r
192/**\r
193 Stops the DHCPv6 standard S.A.R.R. process.\r
194\r
195 The Stop() function is used to stop the DHCPv6 standard process. After this\r
196 function is called successfully, the state of Dhcp6 instance is transferred\r
197 into the Dhcp6Init. EFI_DHCP6_PROTOCOL.Configure() needs to be called\r
198 before DHCPv6 standard process can be started again. This function can be\r
199 called when the Dhcp6 instance is in any state.\r
200\r
201 @param[in] This The pointer to the Dhcp6 protocol.\r
202\r
203 @retval EFI_SUCCESS The Dhcp6 instance is now in the Dhcp6Init state.\r
204 @retval EFI_INVALID_PARAMETER This is NULL.\r
205\r
206**/\r
207EFI_STATUS\r
208EFIAPI\r
209EfiDhcp6Stop (\r
210 IN EFI_DHCP6_PROTOCOL *This\r
211 );\r
212\r
213/**\r
214 Returns the current operating mode data for the Dhcp6 instance.\r
215\r
216 The GetModeData() function returns the current operating mode and\r
217 cached data packet for the Dhcp6 instance.\r
218\r
219 @param[in] This The pointer to the Dhcp6 protocol.\r
220 @param[out] Dhcp6ModeData The pointer to the Dhcp6 mode data.\r
221 @param[out] Dhcp6ConfigData The pointer to the Dhcp6 configure data.\r
222\r
223 @retval EFI_SUCCESS The mode data was returned.\r
224 @retval EFI_INVALID_PARAMETER This is NULL.\r
225 @retval EFI_ACCESS_DENIED The EFI DHCPv6 Protocol instance has not\r
226 been configured when Dhcp6ConfigData is\r
227 not NULL.\r
228**/\r
229EFI_STATUS\r
230EFIAPI\r
231EfiDhcp6GetModeData (\r
232 IN EFI_DHCP6_PROTOCOL *This,\r
233 OUT EFI_DHCP6_MODE_DATA *Dhcp6ModeData OPTIONAL,\r
234 OUT EFI_DHCP6_CONFIG_DATA *Dhcp6ConfigData OPTIONAL\r
235 );\r
236\r
237/**\r
238 Initializes, changes, or resets the operational settings for the Dhcp6 instance.\r
239\r
240 The Configure() function is used to initialize or clean up the configuration\r
241 data of the Dhcp6 instance:\r
242 - When Dhcp6CfgData is not NULL and Configure() is called successfully, the\r
243 configuration data will be initialized in the Dhcp6 instance and the state\r
244 of the configured IA will be transferred into Dhcp6Init.\r
245 - When Dhcp6CfgData is NULL and Configure() is called successfully, the\r
246 configuration data will be cleaned up and no IA will be associated with\r
247 the Dhcp6 instance.\r
248 To update the configuration data for an Dhcp6 instance, the original data\r
249 must be cleaned up before setting the new configuration data.\r
250\r
251 @param[in] This The pointer to the Dhcp6 protocol\r
252 @param[in] Dhcp6CfgData The pointer to the EFI_DHCP6_CONFIG_DATA.\r
253\r
254 @retval EFI_SUCCESS The Dhcp6 is configured successfully with the\r
255 Dhcp6Init state, or cleaned up the original\r
256 configuration setting.\r
257 @retval EFI_ACCESS_DENIED The Dhcp6 instance has been already configured\r
258 when Dhcp6CfgData is not NULL.\r
259 The Dhcp6 instance has already started the\r
260 DHCPv6 S.A.R.R when Dhcp6CfgData is NULL.\r
261 @retval EFI_INVALID_PARAMETER Some of the parameter is invalid.\r
262 @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
263 @retval EFI_DEVICE_ERROR An unexpected system or network error occurred.\r
264\r
265**/\r
266EFI_STATUS\r
267EFIAPI\r
268EfiDhcp6Configure (\r
269 IN EFI_DHCP6_PROTOCOL *This,\r
270 IN EFI_DHCP6_CONFIG_DATA *Dhcp6CfgData OPTIONAL\r
271 );\r
272\r
273/**\r
274 Request configuration information without the assignment of any\r
275 Ia addresses of the client.\r
276\r
277 The InfoRequest() function is used to request configuration information\r
278 without the assignment of any IPv6 address of the client. Client sends\r
279 out Information Request packet to obtain the required configuration\r
280 information, and DHCPv6 server responds with Reply packet containing\r
281 the information for the client. The received Reply packet will be passed\r
282 to the user by ReplyCallback function. If user returns EFI_NOT_READY from\r
283 ReplyCallback, the Dhcp6 instance will continue to receive other Reply\r
284 packets unless timeout according to the Retransmission parameter.\r
285 Otherwise, the Information Request exchange process will be finished\r
286 successfully if user returns EFI_SUCCESS from ReplyCallback.\r
287\r
288 @param[in] This The pointer to the Dhcp6 protocol.\r
289 @param[in] SendClientId If TRUE, the DHCPv6 protocol instance will build Client\r
290 Identifier option and include it into Information Request\r
291 packet. Otherwise, Client Identifier option will not be included.\r
292 @param[in] OptionRequest The pointer to the buffer of option request options.\r
293 @param[in] OptionCount The option number in the OptionList.\r
294 @param[in] OptionList The list of appended options.\r
295 @param[in] Retransmission The pointer to the retransmission of the message.\r
296 @param[in] TimeoutEvent The event of timeout.\r
297 @param[in] ReplyCallback The callback function when a reply was received.\r
298 @param[in] CallbackContext The pointer to the parameter passed to the callback.\r
299\r
300 @retval EFI_SUCCESS The DHCPv6 information request exchange process\r
301 completed when TimeoutEvent is NULL. Information\r
302 Request packet has been sent to DHCPv6 server when\r
303 TimeoutEvent is not NULL.\r
304 @retval EFI_NO_RESPONSE The DHCPv6 information request exchange process failed\r
305 because of no response, or not all requested-options\r
306 are responded to by DHCPv6 servers when Timeout happened.\r
307 @retval EFI_ABORTED The DHCPv6 information request exchange process was aborted\r
308 by the user.\r
309 @retval EFI_INVALID_PARAMETER Some parameter is NULL.\r
310 @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.\r
311 @retval EFI_DEVICE_ERROR An unexpected system or network error occurred.\r
312\r
313**/\r
314EFI_STATUS\r
315EFIAPI\r
316EfiDhcp6InfoRequest (\r
317 IN EFI_DHCP6_PROTOCOL *This,\r
318 IN BOOLEAN SendClientId,\r
319 IN EFI_DHCP6_PACKET_OPTION *OptionRequest,\r
320 IN UINT32 OptionCount,\r
321 IN EFI_DHCP6_PACKET_OPTION *OptionList[] OPTIONAL,\r
322 IN EFI_DHCP6_RETRANSMISSION *Retransmission,\r
323 IN EFI_EVENT TimeoutEvent OPTIONAL,\r
324 IN EFI_DHCP6_INFO_CALLBACK ReplyCallback,\r
325 IN VOID *CallbackContext OPTIONAL\r
326 );\r
327\r
328/**\r
329 Manually extend the valid and preferred lifetimes for the IPv6 addresses\r
330 of the configured IA and update other configuration parameters by sending\r
331 Renew or Rebind packet.\r
332\r
333 The RenewRebind() function is used to manually extend the valid and preferred\r
334 lifetimes for the IPv6 addresses of the configured IA and update other\r
335 configuration parameters by sending a Renew or Rebind packet.\r
336 - When RebindRequest is FALSE and the state of the configured IA is Dhcp6Bound,\r
337 it will send Renew packet to the previously DHCPv6 server and transfer the\r
338 state of the configured IA to Dhcp6Renewing. If valid Reply packet received,\r
339 the state transfers to Dhcp6Bound and the valid and preferred timer restarts.\r
340 If fails, the state transfers to Dhcp6Bound but the timer continues.\r
341 - When RebindRequest is TRUE and the state of the configured IA is Dhcp6Bound,\r
342 it will send a Rebind packet. If a valid Reply packet is received, the state transfers\r
343 to Dhcp6Bound, and the valid and preferred timer restarts. If it fails, the state\r
344 transfers to Dhcp6Init, and the IA can't be used.\r
345\r
346 @param[in] This The pointer to the Dhcp6 protocol.\r
347 @param[in] RebindRequest If TRUE, Rebind packet will be sent and enter Dhcp6Rebinding state.\r
348 Otherwise, Renew packet will be sent and enter Dhcp6Renewing state.\r
349\r
350 @retval EFI_SUCCESS The DHCPv6 renew/rebind exchange process\r
351 completed and at least one IPv6 address of the\r
352 configured IA was bound again when\r
353 EFI_DHCP6_CONFIG_DATA.IaInfoEvent was NULL.\r
354 The EFI DHCPv6 Protocol instance has sent Renew\r
355 or Rebind packet when\r
356 EFI_DHCP6_CONFIG_DATA.IaInfoEvent is not NULL.\r
357 @retval EFI_ACCESS_DENIED The Dhcp6 instance hasn't been configured, or the\r
358 state of the configured IA is not in Dhcp6Bound.\r
359 @retval EFI_ALREADY_STARTED The state of the configured IA has already entered\r
360 Dhcp6Renewing when RebindRequest is FALSE.\r
361 The state of the configured IA has already entered\r
362 Dhcp6Rebinding when RebindRequest is TRUE.\r
363 @retval EFI_ABORTED The DHCPv6 renew/rebind exchange process aborted\r
364 by user.\r
365 @retval EFI_NO_RESPONSE The DHCPv6 renew/rebind exchange process failed\r
366 because of no response.\r
367 @retval EFI_NO_MAPPING No IPv6 address has been bound to the configured\r
368 IA after the DHCPv6 renew/rebind exchange process.\r
369 @retval EFI_INVALID_PARAMETER Some parameter is NULL.\r
370 @retval EFI_DEVICE_ERROR An unexpected system or network error occurred.\r
371\r
372**/\r
373EFI_STATUS\r
374EFIAPI\r
375EfiDhcp6RenewRebind (\r
376 IN EFI_DHCP6_PROTOCOL *This,\r
377 IN BOOLEAN RebindRequest\r
378 );\r
379\r
380/**\r
381 Inform that one or more addresses assigned by a server are already\r
382 in use by another node.\r
383\r
384 The Decline() function is used to manually decline the assignment of\r
385 IPv6 addresses, which have been already used by another node. If all\r
386 IPv6 addresses of the configured IA are declined through this function,\r
387 the state of the IA will switch through Dhcp6Declining to Dhcp6Init.\r
388 Otherwise, the state of the IA will restore to Dhcp6Bound after the\r
389 declining process. The Decline() can only be called when the IA is in\r
390 Dhcp6Bound state. If the EFI_DHCP6_CONFIG_DATA.IaInfoEvent is NULL,\r
391 this function is a blocking operation. It will return after the\r
392 declining process finishes, or aborted by user.\r
393\r
394 @param[in] This The pointer to the Dhcp6 protocol.\r
395 @param[in] AddressCount The number of declining addresses.\r
396 @param[in] Addresses The pointer to the buffer stored the declining\r
397 addresses.\r
398\r
399 @retval EFI_SUCCESS The DHCPv6 decline exchange process completed\r
400 when EFI_DHCP6_CONFIG_DATA.IaInfoEvent was NULL.\r
401 The Dhcp6 instance has sent Decline packet when\r
402 EFI_DHCP6_CONFIG_DATA.IaInfoEvent is not NULL.\r
403 @retval EFI_ACCESS_DENIED The Dhcp6 instance hasn't been configured, or the\r
404 state of the configured IA is not in Dhcp6Bound.\r
405 @retval EFI_ABORTED The DHCPv6 decline exchange process was aborted by the user.\r
406 @retval EFI_NOT_FOUND Any specified IPv6 address is not correlated with\r
407 the configured IA for this instance.\r
408 @retval EFI_INVALID_PARAMETER Some parameter is NULL.\r
409 @retval EFI_DEVICE_ERROR An unexpected system or network error occurred.\r
410\r
411**/\r
412EFI_STATUS\r
413EFIAPI\r
414EfiDhcp6Decline (\r
415 IN EFI_DHCP6_PROTOCOL *This,\r
416 IN UINT32 AddressCount,\r
417 IN EFI_IPv6_ADDRESS *Addresses\r
418 );\r
419\r
420/**\r
421 Release one or more addresses associated with the configured Ia\r
422 for the current instance.\r
423\r
424 The Release() function is used to manually release the one or more\r
425 IPv6 address. If AddressCount is zero, it will release all IPv6\r
426 addresses of the configured IA. If all IPv6 addresses of the IA are\r
427 released through this function, the state of the IA will switch\r
428 through Dhcp6Releasing to Dhcp6Init, otherwise, the state of the\r
429 IA will restore to Dhcp6Bound after the releasing process.\r
430 The Release() can only be called when the IA is in a Dhcp6Bound state.\r
431 If the EFI_DHCP6_CONFIG_DATA.IaInfoEvent is NULL, the function is\r
432 a blocking operation. It will return after the releasing process\r
433 finishes, or aborted by user.\r
434\r
435 @param[in] This The pointer to the Dhcp6 protocol.\r
436 @param[in] AddressCount The number of releasing addresses.\r
437 @param[in] Addresses The pointer to the buffer stored the releasing\r
438 addresses.\r
439 @retval EFI_SUCCESS The DHCPv6 release exchange process has\r
440 completed when EFI_DHCP6_CONFIG_DATA.IaInfoEvent\r
441 is NULL. The Dhcp6 instance has sent Release\r
442 packet when EFI_DHCP6_CONFIG_DATA.IaInfoEvent\r
443 is not NULL.\r
444 @retval EFI_ACCESS_DENIED The Dhcp6 instance hasn't been configured, or the\r
445 state of the configured IA is not in Dhcp6Bound.\r
446 @retval EFI_ABORTED The DHCPv6 release exchange process was aborted by the user.\r
447 @retval EFI_NOT_FOUND Any specified IPv6 address is not correlated with\r
448 the configured IA for this instance.\r
449 @retval EFI_INVALID_PARAMETER Some parameter is NULL.\r
450 @retval EFI_DEVICE_ERROR An unexpected system or network error occurred.\r
451\r
452**/\r
453EFI_STATUS\r
454EFIAPI\r
455EfiDhcp6Release (\r
456 IN EFI_DHCP6_PROTOCOL *This,\r
457 IN UINT32 AddressCount,\r
458 IN EFI_IPv6_ADDRESS *Addresses\r
459 );\r
460\r
461/**\r
462 Parse the option data in the Dhcp6 packet.\r
463\r
464 The Parse() function is used to retrieve the option list in the DHCPv6 packet.\r
465\r
466 @param[in] This The pointer to the Dhcp6 protocol.\r
467 @param[in] Packet The pointer to the Dhcp6 packet.\r
468 @param[in, out] OptionCount The number of option in the packet.\r
469 @param[out] PacketOptionList The array of pointers to the each option in the packet.\r
470\r
471 @retval EFI_SUCCESS The packet was successfully parsed.\r
472 @retval EFI_INVALID_PARAMETER Some parameter is NULL.\r
473 @retval EFI_BUFFER_TOO_SMALL *OptionCount is smaller than the number of options\r
474 that were found in the Packet.\r
475\r
476**/\r
477EFI_STATUS\r
478EFIAPI\r
479EfiDhcp6Parse (\r
480 IN EFI_DHCP6_PROTOCOL *This,\r
481 IN EFI_DHCP6_PACKET *Packet,\r
482 IN OUT UINT32 *OptionCount,\r
483 OUT EFI_DHCP6_PACKET_OPTION *PacketOptionList[] OPTIONAL\r
484 );\r
485\r
486#endif\r