]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Universal/iScsi/IScsiConfigNVDataStruc.h
UEFI HII: Merge UEFI HII support changes from branch.
[mirror_edk2.git] / MdeModulePkg / Universal / iScsi / IScsiConfigNVDataStruc.h
CommitLineData
6a690e23 1/*++\r
2\r
3Copyright (c) 2007 Intel Corporation. All rights reserved\r
4This software and associated documentation (if any) is furnished\r
5under a license and may only be used or copied in accordance\r
6with the terms of the license. Except as permitted by such\r
7license, no part of this software or documentation may be\r
8reproduced, stored in a retrieval system, or transmitted in any\r
9form or by any means without the express written consent of\r
10Intel Corporation.\r
11\r
12Module Name:\r
13\r
14 IScsiConfigNVDataStruc.h\r
15 \r
16Abstract:\r
17 \r
18 NVData structure used by the iSCSI configuration component.\r
19\r
20--*/\r
21\r
22#ifndef _ISCSI_NVDATASTRUC_H_\r
23#define _ISCSI_NVDATASTRUC_H_\r
24\r
25#define ISCSI_CONFIG_GUID \\r
26 { \\r
27 0x6456ed61, 0x3579, 0x41c9, { 0x8a, 0x26, 0x0a, 0x0b, 0xd6, 0x2b, 0x78, 0xfc } \\r
28 }\r
29\r
30#define VAR_EQ_TEST_NAME 0x100\r
31\r
32#define FORMID_MAIN_FORM 1\r
33#define FORMID_DEVICE_FORM 2\r
34\r
35#define ISCSI_NAME_MAX_SIZE 224\r
36\r
37//\r
38// Vfr has a limit on the size, it's 255 bytes.\r
39//\r
40#define ISCSI_NAME_IFR_MAX_SIZE 126\r
41\r
42#define IP_MIN_SIZE 7\r
43#define IP_MAX_SIZE 15\r
44#define IP4_STR_MAX_SIZE 16\r
45\r
46#define LUN_MIN_SIZE 1\r
47#define LUN_MAX_SIZE 20\r
48\r
49#define ISCSI_CHAP_NONE 0\r
50#define ISCSI_CHAP_UNI 1\r
51#define ISCSI_CHAP_MUTUAL 2\r
52\r
53#define TARGET_PORT_MIN_NUM 0\r
54#define TARGET_PORT_MAX_NUM 65535\r
55\r
56#define DEVICE_ENTRY_LABEL 0x1234\r
57\r
93e3992d 58#define KEY_INITIATOR_NAME 0x101\r
59#define KEY_DHCP_ENABLE 0x102\r
60#define KEY_LOCAL_IP 0x103\r
61#define KEY_SUBNET_MASK 0x104\r
62#define KEY_GATE_WAY 0x105\r
63#define KEY_TARGET_IP 0x106\r
64#define KEY_CHAP_NAME 0x107\r
65#define KEY_CHAP_SECRET 0x108\r
66#define KEY_REVERSE_CHAP_NAME 0x109\r
67#define KEY_REVERSE_CHAP_SECRET 0x10a\r
68#define KEY_SAVE_CHANGES 0x10b\r
69#define KEY_TARGET_NAME 0x10c\r
70#define KEY_BOOT_LUN 0x10d\r
6a690e23 71\r
72#define KEY_DEVICE_ENTRY_BASE 0x1000\r
73\r
74#define ISCSI_LUN_STR_MAX_LEN 21\r
75#define ISCSI_CHAP_SECRET_MIN_LEN 13\r
76#define ISCSI_CHAP_SECRET_MAX_LEN 17\r
77#define ISCSI_CHAP_NAME_MAX_LEN 126\r
78\r
79#pragma pack(1)\r
80typedef struct {\r
81 CHAR16 InitiatorName[ISCSI_NAME_IFR_MAX_SIZE];\r
82\r
83 UINT8 Enabled;\r
84\r
85 UINT8 InitiatorInfoFromDhcp;\r
86 CHAR16 LocalIp[IP4_STR_MAX_SIZE];\r
87 CHAR16 SubnetMask[IP4_STR_MAX_SIZE];\r
88 CHAR16 Gateway[IP4_STR_MAX_SIZE];\r
89\r
90 CHAR16 TargetName[ISCSI_NAME_IFR_MAX_SIZE];\r
91 CHAR16 TargetIp[IP4_STR_MAX_SIZE];\r
92 UINT16 TargetPort;\r
93 CHAR16 BootLun[ISCSI_LUN_STR_MAX_LEN];\r
94 UINT8 TargetInfoFromDhcp;\r
95\r
96 UINT8 CHAPType;\r
97 CHAR16 CHAPName[ISCSI_CHAP_NAME_MAX_LEN];\r
98 CHAR16 CHAPSecret[ISCSI_CHAP_SECRET_MAX_LEN];\r
99 CHAR16 ReverseCHAPName[ISCSI_CHAP_NAME_MAX_LEN];\r
100 CHAR16 ReverseCHAPSecret[ISCSI_CHAP_SECRET_MAX_LEN];\r
101} ISCSI_CONFIG_IFR_NVDATA;\r
102#pragma pack()\r
103\r
104#endif\r