/** @file\r
- The header file of IScsiConfig.c\r
+ The header file of IScsiConfig.c.\r
\r
-Copyright (c) 2004 - 2008, Intel Corporation\r
-All rights reserved. This program and the accompanying materials\r
+Copyright (c) 2004 - 2009, Intel Corporation. All rights reserved.<BR>\r
+This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
which accompanies this distribution. The full text of the license may be found at\r
http://opensource.org/licenses/bsd-license.php\r
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
\r
-Module Name:\r
-\r
- IScsiConfig.h\r
-\r
-Abstract:\r
-\r
- The header file of IScsiConfig.c\r
-\r
**/\r
\r
#ifndef _ISCSI_CONFIG_H_\r
#define _ISCSI_CONFIG_H_\r
\r
+#include <Guid/MdeModuleHii.h>\r
+#include <Protocol/HiiConfigRouting.h>\r
#include <Library/HiiLib.h>\r
-#include <Library/ExtendedHiiLib.h>\r
-#include <Library/IfrSupportLib.h>\r
-#include <Library/ExtendedIfrSupportLib.h>\r
+#include <Library/DevicePathLib.h>\r
#include <Library/DebugLib.h>\r
#include <Library/BaseLib.h>\r
#include <Library/NetLib.h>\r
-#include "IScsiConfigNVDataStruc.h"\r
\r
extern UINT8 IScsiConfigDxeBin[];\r
extern UINT8 IScsiDxeStrings[];\r
\r
#define ISCSI_CONFIG_VAR_ATTR (EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_NON_VOLATILE)\r
\r
-#define ISCSI_FORM_CALLBACK_INFO_SIGNATURE EFI_SIGNATURE_32 ('I', 'f', 'c', 'i')\r
+#define ISCSI_FORM_CALLBACK_INFO_SIGNATURE SIGNATURE_32 ('I', 'f', 'c', 'i')\r
+\r
+\r
+\r
+/**\r
+ If the DEBUG_PROPERTY_DEBUG_ASSERT_ENABLED bit of PcdDebugProperyMask is clear, \r
+ then this macro return a pointer to a data structure ISCSI_FORM_CALLBACK_INFO.\r
+\r
+ If the DEBUG_PROPERTY_DEBUG_ASSERT_ENABLED bit of PcdDebugProperyMask is set, \r
+ The Signature field of the data structure ISCSI_FORM_CALLBACK_INFO \r
+ is compared to TestSignature. If the signatures match, then a pointer \r
+ to the pointer to a data structure ISCSI_FORM_CALLBACK_INFO is returned. \r
+ If the signatures do not match, then DebugAssert() is called with a description \r
+ of "CR has a bad signature" and Callback is returned. \r
+\r
+ If the data type ISCSI_FORM_CALLBACK_INFO_SIGNATURE does not contain the field\r
+ specified by Callback, then the module will not compile.\r
+\r
+ If ISCSI_FORM_CALLBACK_INFO_SIGNATURE does not contain a field called Signature, \r
+ then the module will not compile.\r
+\r
+ @param Callback Pointer to the specified field within the data \r
+ structure ISCSI_FORM_CALLBACK_INFO.\r
+ @return A pointer to the pointer to a data structure ISCSI_FORM_CALLBACK_INFO.\r
+ @retval Others Some unexpected error happened.\r
+**/\r
\r
#define ISCSI_FORM_CALLBACK_INFO_FROM_FORM_CALLBACK(Callback) \\r
CR ( \\r
typedef struct _ISCSI_MAC_INFO {\r
EFI_MAC_ADDRESS Mac;\r
UINT8 Len;\r
+ UINT16 VlanId;\r
} ISCSI_MAC_INFO;\r
\r
typedef struct _ISCSI_DEVICE_LIST {\r
LIST_ENTRY Link;\r
EFI_HANDLE Controller;\r
CHAR16 MacString[95];\r
- STRING_REF PortTitleToken;\r
- STRING_REF PortTitleHelpToken;\r
+ EFI_STRING_ID PortTitleToken;\r
+ EFI_STRING_ID PortTitleHelpToken;\r
\r
ISCSI_SESSION_CONFIG_NVDATA SessionConfigData;\r
ISCSI_CHAP_AUTH_CONFIG_NVDATA AuthConfigData;\r
ISCSI_CONFIG_FORM_ENTRY *Current;\r
} ISCSI_FORM_CALLBACK_INFO;\r
\r
+#pragma pack(1)\r
+\r
+///\r
+/// HII specific Vendor Device Path definition.\r
+///\r
+typedef struct {\r
+ VENDOR_DEVICE_PATH VendorDevicePath;\r
+ EFI_DEVICE_PATH_PROTOCOL End;\r
+} HII_VENDOR_DEVICE_PATH;\r
+\r
+#pragma pack()\r
+\r
/**\r
Updates the iSCSI configuration form to add/delete an entry for the iSCSI\r
device specified by the Controller.\r
\r
- @param DriverBindingHandle[in] The driverbinding handle.\r
-\r
- @param Controller[in] The controller handle of the iSCSI device.\r
-\r
- @param AddForm[in] Whether to add or delete a form entry.\r
+ @param[in] DriverBindingHandle The driverbinding handle.\r
+ @param[in] Controller The controller handle of the iSCSI device.\r
+ @param[in] AddForm Whether to add or delete a form entry.\r
\r
@retval EFI_SUCCESS The iSCSI configuration form is updated.\r
-\r
@retval EFI_OUT_OF_RESOURCES Failed to allocate memory.\r
-\r
+ @retval Others Other errors as indicated.\r
**/\r
EFI_STATUS\r
IScsiConfigUpdateForm (\r
/**\r
Initialize the iSCSI configuration form.\r
\r
- @param DriverBindingHandle[in] The iSCSI driverbinding handle.\r
-\r
- @retval EFI_SUCCESS The iSCSI configuration form is initialized.\r
-\r
- @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.\r
+ @param[in] DriverBindingHandle The iSCSI driverbinding handle.\r
\r
+ @retval EFI_SUCCESS The iSCSI configuration form is initialized.\r
+ @retval EFI_OUT_OF_RESOURCES Failed to allocate memory.\r
+ @retval Others Other errors as indicated.\r
**/\r
EFI_STATUS\r
IScsiConfigFormInit (\r
- IN EFI_HANDLE DriverBindingHandle\r
+ VOID\r
);\r
\r
/**\r
device configuration entries, uninstall the form callback protocol and\r
free the resources used.\r
\r
- @param DriverBindingHandle[in] The iSCSI driverbinding handle.\r
-\r
+ @param[in] DriverBindingHandle The iSCSI driverbinding handle.\r
+ \r
@retval EFI_SUCCESS The iSCSI configuration form is unloaded.\r
-\r
@retval EFI_OUT_OF_RESOURCES Failed to allocate memory.\r
-\r
**/\r
EFI_STATUS\r
IScsiConfigFormUnload (\r