]>
Commit | Line | Data |
---|---|---|
4c5a5e0c | 1 | /** @file\r |
2 | The head file of iSCSI DHCP4 related configuration routines.\r | |
3 | \r | |
142c00c3 | 4 | Copyright (c) 2004 - 2016, Intel Corporation. All rights reserved.<BR>\r |
ecf98fbc | 5 | SPDX-License-Identifier: BSD-2-Clause-Patent\r |
4c5a5e0c | 6 | \r |
7 | **/\r | |
8 | \r | |
9 | #ifndef _ISCSI_DHCP_H_\r | |
10 | #define _ISCSI_DHCP_H_\r | |
11 | \r | |
4c5a5e0c | 12 | #define ISCSI_ROOT_PATH_ID "iscsi:"\r |
13 | #define ISCSI_ROOT_PATH_FIELD_DELIMITER ':'\r | |
14 | \r | |
15 | #define RP_FIELD_IDX_SERVERNAME 0\r | |
16 | #define RP_FIELD_IDX_PROTOCOL 1\r | |
17 | #define RP_FIELD_IDX_PORT 2\r | |
18 | #define RP_FIELD_IDX_LUN 3\r | |
19 | #define RP_FIELD_IDX_TARGETNAME 4\r | |
20 | #define RP_FIELD_IDX_MAX 5\r | |
21 | \r | |
22 | typedef struct _ISCSI_ATTEMPT_CONFIG_NVDATA ISCSI_ATTEMPT_CONFIG_NVDATA;\r | |
23 | \r | |
24 | typedef struct _ISCSI_ROOT_PATH_FIELD {\r | |
25 | CHAR8 *Str;\r | |
26 | UINT8 Len;\r | |
27 | } ISCSI_ROOT_PATH_FIELD;\r | |
28 | \r | |
29 | /**\r | |
30 | Parse the DHCP ACK to get the address configuration and DNS information.\r | |
31 | \r | |
32 | @param[in] Image The handle of the driver image.\r | |
33 | @param[in] Controller The handle of the controller.\r | |
34 | @param[in, out] ConfigData The attempt configuration data.\r | |
35 | \r | |
36 | @retval EFI_SUCCESS The DNS information is got from the DHCP ACK.\r | |
37 | @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.\r | |
38 | @retval EFI_NO_MEDIA There was a media error.\r | |
39 | @retval Others Other errors as indicated.\r | |
40 | \r | |
41 | **/\r | |
42 | EFI_STATUS\r | |
43 | IScsiDoDhcp (\r | |
44 | IN EFI_HANDLE Image,\r | |
45 | IN EFI_HANDLE Controller,\r | |
46 | IN OUT ISCSI_ATTEMPT_CONFIG_NVDATA *ConfigData\r | |
47 | );\r | |
48 | \r | |
49 | #endif\r |