3 Copyright (c) 2007 Intel Corporation. All rights reserved
4 This software and associated documentation (if any) is furnished
5 under a license and may only be used or copied in accordance
6 with the terms of the license. Except as permitted by such
7 license, no part of this software or documentation may be
8 reproduced, stored in a retrieval system, or transmitted in any
9 form or by any means without the express written consent of
14 IScsiConfigNVDataStruc.h
18 NVData structure used by the iSCSI configuration component.
22 #ifndef _ISCSI_NVDATASTRUC_H_
23 #define _ISCSI_NVDATASTRUC_H_
25 #define ISCSI_CONFIG_GUID \
27 0x6456ed61, 0x3579, 0x41c9, { 0x8a, 0x26, 0x0a, 0x0b, 0xd6, 0x2b, 0x78, 0xfc } \
30 #define VAR_EQ_TEST_NAME 0x100
32 #define FORMID_MAIN_FORM 1
33 #define FORMID_DEVICE_FORM 2
35 #define ISCSI_NAME_MAX_SIZE 224
38 // Vfr has a limit on the size, it's 255 bytes.
40 #define ISCSI_NAME_IFR_MAX_SIZE 126
43 #define IP_MAX_SIZE 15
44 #define IP4_STR_MAX_SIZE 16
46 #define LUN_MIN_SIZE 1
47 #define LUN_MAX_SIZE 20
49 #define ISCSI_CHAP_NONE 0
50 #define ISCSI_CHAP_UNI 1
51 #define ISCSI_CHAP_MUTUAL 2
53 #define TARGET_PORT_MIN_NUM 0
54 #define TARGET_PORT_MAX_NUM 65535
56 #define DEVICE_ENTRY_LABEL 0x1234
58 #define KEY_INITIATOR_NAME 0x01
59 #define KEY_DHCP_ENABLE 0x02
60 #define KEY_LOCAL_IP 0x03
61 #define KEY_SUBNET_MASK 0x04
62 #define KEY_GATE_WAY 0x05
63 #define KEY_TARGET_IP 0x06
64 #define KEY_CHAP_NAME 0x07
65 #define KEY_CHAP_SECRET 0x08
66 #define KEY_REVERSE_CHAP_NAME 0x09
67 #define KEY_REVERSE_CHAP_SECRET 0x0a
68 #define KEY_SAVE_CHANGES 0x0b
69 #define KEY_TARGET_NAME 0x0c
70 #define KEY_BOOT_LUN 0x0d
72 #define KEY_DEVICE_ENTRY_BASE 0x1000
74 #define ISCSI_LUN_STR_MAX_LEN 21
75 #define ISCSI_CHAP_SECRET_MIN_LEN 13
76 #define ISCSI_CHAP_SECRET_MAX_LEN 17
77 #define ISCSI_CHAP_NAME_MAX_LEN 126
81 CHAR16 InitiatorName
[ISCSI_NAME_IFR_MAX_SIZE
];
85 UINT8 InitiatorInfoFromDhcp
;
86 CHAR16 LocalIp
[IP4_STR_MAX_SIZE
];
87 CHAR16 SubnetMask
[IP4_STR_MAX_SIZE
];
88 CHAR16 Gateway
[IP4_STR_MAX_SIZE
];
90 CHAR16 TargetName
[ISCSI_NAME_IFR_MAX_SIZE
];
91 CHAR16 TargetIp
[IP4_STR_MAX_SIZE
];
93 CHAR16 BootLun
[ISCSI_LUN_STR_MAX_LEN
];
94 UINT8 TargetInfoFromDhcp
;
97 CHAR16 CHAPName
[ISCSI_CHAP_NAME_MAX_LEN
];
98 CHAR16 CHAPSecret
[ISCSI_CHAP_SECRET_MAX_LEN
];
99 CHAR16 ReverseCHAPName
[ISCSI_CHAP_NAME_MAX_LEN
];
100 CHAR16 ReverseCHAPSecret
[ISCSI_CHAP_SECRET_MAX_LEN
];
101 } ISCSI_CONFIG_IFR_NVDATA
;